Bug 100224 - [MAINTAINER PATCH] cad/gschem: Fix installdirs, NLS, cleanup
Summary: [MAINTAINER PATCH] cad/gschem: Fix installdirs, NLS, cleanup
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Rong-En Fan
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-07-13 19:20 UTC by Stanislav Sedov
Modified: 2006-07-16 05:05 UTC (History)
0 users

See Also:


Attachments
gschem-20060123_1.patch (6.07 KB, patch)
2006-07-13 19:20 UTC, Stanislav Sedov
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Stanislav Sedov 2006-07-13 19:20:27 UTC
 - Fix installdirs to address geda directory structure unification
 - Use NLS conditional
 - FIx comment

Added file(s):
- files/patch-configure
- files/patch-src_x_menus.c

Note: this also depends on libgeda and geda-symbols PRs
Comment 1 Rong-En Fan freebsd_committer 2006-07-13 20:59:55 UTC
Responsible Changed
From-To: freebsd-ports-bugs->rafan

Eat.
Comment 2 Stanislav Sedov 2006-07-14 19:26:55 UTC
Updated diff, that takes into consideration repocopy changes.

------------------------------------------------------------
diff -ruN --exclude=CVS /tmp/ports/cad/gschem/Makefile gschem/Makefile
--- /tmp/ports/cad/gschem/Makefile	Wed Jun 28 11:53:41 2006
+++ gschem/Makefile	Fri Jul 14 22:19:43 2006
@@ -7,25 +7,38 @@
 
 PORTNAME=	gschem
 PORTVERSION=	20060123
+PORTREVISION=	1
 CATEGORIES=	cad
 MASTER_SITES=
ftp://ftp.geda.seul.org/pub/geda/devel/${PORTVERSION}/ \
 		http://geda.seul.org/devel/${PORTVERSION}/ \
 		http://www.tinkerbox.org/projects/files/gEDA/
-DISTNAME=	geda-${PORTNAME}-${PORTVERSION}
+PKGNAMEPREFIX=	geda-
+DISTNAME=	${PKGNAMEPREFIX}${PORTNAME}-${PORTVERSION}
 
 MAINTAINER=	ssedov@mbsd.msk.ru
-COMMENT=	gEDA electronic schematic capture tools
+COMMENT=	The gEDA's electronic schematic capture tool
 
-RUN_DEPENDS=
${LOCALBASE}/share/gEDA/sym:${PORTSDIR}/cad/geda-symbols
+RUN_DEPENDS=
${LOCALBASE}/share/geda/sym:${PORTSDIR}/cad/geda-symbols
 LIB_DEPENDS=	geda.25:${PORTSDIR}/cad/libgeda
 
+DOCSDIR=	${PREFIX}/share/doc/geda
+DATADIR=	${PREFIX}/share/geda
+
 GNU_CONFIGURE=	yes
 USE_GNOME=	gtk20
-CONFIGURE_ARGS=	--enable-gdgeda
+CONFIGURE_ARGS=	--enable-gdgeda --with-docdir=${DOCSDIR}
 CONFIGURE_ENV=	CPPFLAGS="-I${LOCALBASE}/include" \
 		LDFLAGS="-L${LOCALBASE}/lib"
 
 INFO=		gschemdoc
 MAN1=		gschem.1
+
+.if !defined(WITHOUT_NLS)
+USE_GETTEXT=	yes
+PLIST_SUB+=	NLS=""
+.else
+CONFIGURE_ARGS+=--disable-nls
+PLIST_SUB+=	NLS="@comment "
+.endif
 
 .include <bsd.port.mk>
diff -ruN --exclude=CVS /tmp/ports/cad/gschem/files/patch-configure
gschem/files/patch-configure
--- /tmp/ports/cad/gschem/files/patch-configure	Thu Jan  1
03:00:00 1970
+++ gschem/files/patch-configure	Thu Jul 13 14:12:06 2006
@@ -0,0 +1,11 @@
+--- configure.orig	Thu Jul 13 14:11:39 2006
++++ configure	Thu Jul 13 14:11:52 2006
+@@ -7923,7 +7923,7 @@
+ # gEDA/gaf specific setup start
+ #
+ 
+-DATADIR=gEDA
++DATADIR=geda
+ GEDADATADIR=$datadir/$DATADIR
+ 
+ if eval "test x$opt_rcdir = x"; then
diff -ruN --exclude=CVS /tmp/ports/cad/gschem/files/patch-src_x_menus.c
gschem/files/patch-src_x_menus.c
--- /tmp/ports/cad/gschem/files/patch-src_x_menus.c	Thu Jan  1
03:00:00 1970
+++ gschem/files/patch-src_x_menus.c	Thu Jul 13 14:22:08 2006
@@ -0,0 +1,14 @@
+--- src/x_menus.c.orig	Thu Jul 13 14:21:07 2006
++++ src/x_menus.c	Thu Jul 13 14:21:49 2006
+@@ -284,9 +284,11 @@
+    */
+   item_factory = gtk_item_factory_new(GTK_TYPE_MENU, "<popup>",
+ 				      accel_group);
++#if defined(ENABLE_NLS)
+   gtk_item_factory_set_translate_func(item_factory,
+ 				      (GtkTranslateFunc) gettext,
+ 				      NULL, NULL);
++#endif
+   /* This function creates the pop-up menu itself & attaches it to the
+      GtkItemFactory. Pass the item factory,
+      the number of items in the array, the array itself, and any
diff -ruN --exclude=CVS /tmp/ports/cad/gschem/pkg-plist gschem/pkg-plist
--- /tmp/ports/cad/gschem/pkg-plist	Tue Jun 27 02:04:37 2006
+++ gschem/pkg-plist	Thu Jul 13 14:15:47 2006
@@ -1,51 +1,41 @@
 bin/gschem
-share/doc/geda-doc/man/gschem.html
-share/gEDA/bitmap/gschem-bus.xpm
-share/gEDA/bitmap/gschem-comp.xpm
-share/gEDA/bitmap/gschem-copy.xpm
-share/gEDA/bitmap/gschem-delete.xpm
-share/gEDA/bitmap/gschem-edit.xpm
-share/gEDA/bitmap/gschem-mirror.xpm
-share/gEDA/bitmap/gschem-move.xpm
-share/gEDA/bitmap/gschem-net.xpm
-share/gEDA/bitmap/gschem-new.xpm
-share/gEDA/bitmap/gschem-open.xpm
-share/gEDA/bitmap/gschem-redo.xpm
-share/gEDA/bitmap/gschem-rotate.xpm
-share/gEDA/bitmap/gschem-save.xpm
-share/gEDA/bitmap/gschem-select.xpm
-share/gEDA/bitmap/gschem-text.xpm
-share/gEDA/bitmap/gschem-undo.xpm
-share/gEDA/bitmap/gschem-warning.png
-share/gEDA/gschem-darkbg
-share/gEDA/gschem-gtkrc
-share/gEDA/gschem-lightbg
-share/gEDA/scheme/auto-uref.scm
-share/gEDA/scheme/generate_netlist.scm
-share/gEDA/scheme/gschem.scm
-share/gEDA/scheme/list-keys.scm
-share/gEDA/scheme/print-NB-attribs.scm
-share/gEDA/system-gschemrc
-share/locale/de_DE/LC_MESSAGES/geda-gschem.mo
-share/locale/es_ES/LC_MESSAGES/geda-gschem.mo
-share/locale/fr_FR/LC_MESSAGES/geda-gschem.mo
-share/locale/it_IT/LC_MESSAGES/geda-gschem.mo
-share/locale/ja_JP/LC_MESSAGES/geda-gschem.mo
-share/locale/nl_NL/LC_MESSAGES/geda-gschem.mo
-share/locale/pt_BR/LC_MESSAGES/geda-gschem.mo
-share/locale/ru/LC_MESSAGES/geda-gschem.mo
-@dirrmtry share/locale/nl_NL/LC_MESSAGES
-@dirrmtry share/locale/nl_NL
-@dirrmtry share/locale/ja_JP/LC_MESSAGES
-@dirrmtry share/locale/ja_JP
-@dirrmtry share/locale/it_IT/LC_MESSAGES
-@dirrmtry share/locale/it_IT
-@dirrmtry share/locale/fr_FR/LC_MESSAGES
-@dirrmtry share/locale/fr_FR
-@dirrmtry share/locale/de_DE/LC_MESSAGES
-@dirrmtry share/locale/de_DE
-@dirrmtry share/gEDA/scheme
-@dirrmtry share/gEDA/bitmap
-@dirrmtry share/gEDA
-@dirrmtry share/doc/geda-doc/man
-@dirrmtry share/doc/geda-doc
+%%DOCSDIR%%/man/gschem.html
+%%DATADIR%%/bitmap/gschem-bus.xpm
+%%DATADIR%%/bitmap/gschem-comp.xpm
+%%DATADIR%%/bitmap/gschem-copy.xpm
+%%DATADIR%%/bitmap/gschem-delete.xpm
+%%DATADIR%%/bitmap/gschem-edit.xpm
+%%DATADIR%%/bitmap/gschem-mirror.xpm
+%%DATADIR%%/bitmap/gschem-move.xpm
+%%DATADIR%%/bitmap/gschem-net.xpm
+%%DATADIR%%/bitmap/gschem-new.xpm
+%%DATADIR%%/bitmap/gschem-open.xpm
+%%DATADIR%%/bitmap/gschem-redo.xpm
+%%DATADIR%%/bitmap/gschem-rotate.xpm
+%%DATADIR%%/bitmap/gschem-save.xpm
+%%DATADIR%%/bitmap/gschem-select.xpm
+%%DATADIR%%/bitmap/gschem-text.xpm
+%%DATADIR%%/bitmap/gschem-undo.xpm
+%%DATADIR%%/bitmap/gschem-warning.png
+%%DATADIR%%/gschem-darkbg
+%%DATADIR%%/gschem-gtkrc
+%%DATADIR%%/gschem-lightbg
+%%DATADIR%%/scheme/auto-uref.scm
+%%DATADIR%%/scheme/generate_netlist.scm
+%%DATADIR%%/scheme/gschem.scm
+%%DATADIR%%/scheme/list-keys.scm
+%%DATADIR%%/scheme/print-NB-attribs.scm
+%%DATADIR%%/system-gschemrc
+%%NLS%%share/locale/de_DE/LC_MESSAGES/geda-gschem.mo
+%%NLS%%share/locale/es_ES/LC_MESSAGES/geda-gschem.mo
+%%NLS%%share/locale/fr_FR/LC_MESSAGES/geda-gschem.mo
+%%NLS%%share/locale/it_IT/LC_MESSAGES/geda-gschem.mo
+%%NLS%%share/locale/ja_JP/LC_MESSAGES/geda-gschem.mo
+%%NLS%%share/locale/nl_NL/LC_MESSAGES/geda-gschem.mo
+%%NLS%%share/locale/pt_BR/LC_MESSAGES/geda-gschem.mo
+%%NLS%%share/locale/ru/LC_MESSAGES/geda-gschem.mo
+@dirrmtry %%DATADIR%%/scheme
+@dirrmtry %%DATADIR%%/bitmap
+@dirrmtry %%DATADIR%%
+@dirrmtry %%DOCSDIR%%/man
+@dirrmtry %%DOCSDIR%%
------------------------------------------------------------
Comment 3 Rong-En Fan freebsd_committer 2006-07-16 05:05:37 UTC
State Changed
From-To: open->closed

Committed. Thanks!