ports/156167: editor/emacs: better -nox11 support
Zhihao Yuan
lichray at gmail.com
Mon Apr 4 07:00:26 UTC 2011
>Number: 156167
>Category: ports
>Synopsis: editor/emacs: better -nox11 support
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Mon Apr 04 07:00:22 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator: Zhihao Yuan
>Release: FreeBSD 8.2-STABLE amd64
>Organization:
Northern Illinois University
>Environment:
System: FreeBSD compaq.yuetime 8.2-STABLE FreeBSD 8.2-STABLE #0: Mon Mar 14 02:51:28 CDT 2011 root at compaq.yuetime:/usr/obj/usr/src/sys/HOUKAGO amd64
>Description:
The emacs port does no add -nox11 suffix when WITHOUT_X11 is defined.
And, no matter how you install a -nox11 emacs, the .desktop entity does not work.
>How-To-Repeat:
>Fix:
1. Add the suffix support;
2. Rearrange the CONFLICTS;
3. Use Terminal=true when WITHOUT_X11 is defined.
--- patch-emacs-w-nox11 begins here ---
diff -ruN --exclude=CVS /usr/ports/editors/emacs.orig/Makefile /usr/ports/editors/emacs/Makefile
--- /usr/ports/editors/emacs.orig/Makefile 2010-09-29 23:38:00.000000000 -0500
+++ /usr/ports/editors/emacs/Makefile 2011-04-04 01:40:10.937168475 -0500
@@ -7,7 +7,7 @@
PORTNAME= emacs
PORTVERSION= ${EMACS_VER}
-PORTREVISION= 4
+PORTREVISION= 5
PORTEPOCH= 2
CATEGORIES= editors ipv6
MASTER_SITES= ${MASTER_SITE_GNU}
@@ -20,8 +20,7 @@
CONFLICTS= emacs-19.* emacs-21.* emacs-22.* emacs-24.* \
xemacs-[0-9]* xemacs-devel-[0-9]* \
- xemacs-mule-[0-9]* xemacs-devel-mule-[0-9]* \
- emacs-nox11-[0-9]*
+ xemacs-mule-[0-9]* xemacs-devel-mule-[0-9]*
INSTALLS_ICONS= yes
@@ -78,10 +77,13 @@
.if defined(WITHOUT_X11)
CONFIGURE_ARGS+= --without-x
+PKGNAMESUFFIX= -nox11
+CONFLICTS+= emacs-23.*
.else
USE_XORG= x11
USE_GNOME=
+CONFLICTS+= emacs-nox11-[0-9]*
.if defined(WITHOUT_SVG)
CONFIGURE_ARGS+= --without-rsvg
@@ -223,6 +225,9 @@
.endif
post-patch:
+.if defined(WITHOUT_X11)
+ ${REINPLACE_CMD} -e 's/Terminal=.*$$/Terminal=true/' ${WRKSRC}/etc/emacs.desktop
+.endif
@${RM} -f ${WRKSRC}/info/*
@${REINPLACE_CMD} -e "s/%%EMACS_VER%%/${EMACS_VER}/g" -e "s/%%DATADIR%%/${DATADIR:C/\//\\\//g}/g" ${WRKSRC}/sources.el
--- patch-emacs-w-nox11 ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list