diff options
| author | Paul Eggert | 2015-01-24 18:05:33 -0800 |
|---|---|---|
| committer | Paul Eggert | 2015-01-24 18:20:29 -0800 |
| commit | f6ef836521dfd07a0a33d5f1f384427f0c4023ce (patch) | |
| tree | 8e589f353774ac95d8fb9f1dfa4179c702e78759 | |
| parent | bce27d884521832a62837b113f4e681974cdaccb (diff) | |
| download | emacs-f6ef836521dfd07a0a33d5f1f384427f0c4023ce.tar.gz emacs-f6ef836521dfd07a0a33d5f1f384427f0c4023ce.zip | |
Use gnustep-config if available
* configure.ac (--with-gnustep): Document this.
(NS_GNUSTEP_CONFIG): New variable, set if gnustep-config works.
If gnustep-config works, use 'gnustep-config --objc-flags' and
'gnustep-config --gui-libs' to compute GNUstep configuration
variables, instead of attempting to infer them individually.
* etc/NEWS: Document this.
* src/emacs.c [NS_IMPL_GNUSTEP]: Don't include <GNUstepBase/GSConfig.h>.
It doesn't appear to be needed, and the inclusion breaks on
Ubuntu 14.10 when 'configure' uses 'gnustep-config'.
Fixes: bug#19507
| -rw-r--r-- | ChangeLog | 10 | ||||
| -rw-r--r-- | configure.ac | 35 | ||||
| -rw-r--r-- | etc/ChangeLog | 5 | ||||
| -rw-r--r-- | etc/NEWS | 3 | ||||
| -rw-r--r-- | src/ChangeLog | 7 | ||||
| -rw-r--r-- | src/emacs.c | 5 |
6 files changed, 49 insertions, 16 deletions
| @@ -1,3 +1,13 @@ | |||
| 1 | 2015-01-25 Paul Eggert <eggert@cs.ucla.edu> | ||
| 2 | |||
| 3 | Use gnustep-config if available | ||
| 4 | * configure.ac (--with-gnustep): Document this. | ||
| 5 | (NS_GNUSTEP_CONFIG): New variable, set if gnustep-config works. | ||
| 6 | If gnustep-config works, use 'gnustep-config --objc-flags' and | ||
| 7 | 'gnustep-config --gui-libs' to compute GNUstep configuration | ||
| 8 | variables, instead of attempting to infer them individually. | ||
| 9 | Fixes: bug#19507 | ||
| 10 | |||
| 1 | 2015-01-21 Ulrich Müller <ulm@gentoo.org> | 11 | 2015-01-21 Ulrich Müller <ulm@gentoo.org> |
| 2 | 12 | ||
| 3 | * configure.ac (gamegroup): New AC_SUBST. | 13 | * configure.ac (gamegroup): New AC_SUBST. |
diff --git a/configure.ac b/configure.ac index 47b36fe1839..cd011b9720b 100644 --- a/configure.ac +++ b/configure.ac | |||
| @@ -414,7 +414,9 @@ esac | |||
| 414 | 414 | ||
| 415 | AC_ARG_WITH([gnustep-conf],dnl | 415 | AC_ARG_WITH([gnustep-conf],dnl |
| 416 | [AS_HELP_STRING([--with-gnustep-conf=FILENAME], | 416 | [AS_HELP_STRING([--with-gnustep-conf=FILENAME], |
| 417 | [name of GNUstep.conf; default $GNUSTEP_CONFIG_FILE, or /etc/GNUstep/GNUstep.conf])]) | 417 | [name of GNUstep configuration file to use on systems where the command |
| 418 | 'gnustep-config' does not work; default $GNUSTEP_CONFIG_FILE, or | ||
| 419 | /etc/GNUstep/GNUstep.conf])]) | ||
| 418 | test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \ | 420 | test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \ |
| 419 | GNUSTEP_CONFIG_FILE="${with_gnustep_conf}" | 421 | GNUSTEP_CONFIG_FILE="${with_gnustep_conf}" |
| 420 | test "X$GNUSTEP_CONFIG_FILE" = "X" && \ | 422 | test "X$GNUSTEP_CONFIG_FILE" = "X" && \ |
| @@ -1752,6 +1754,7 @@ else | |||
| 1752 | fi | 1754 | fi |
| 1753 | 1755 | ||
| 1754 | HAVE_NS=no | 1756 | HAVE_NS=no |
| 1757 | NS_GNUSTEP_CONFIG=no | ||
| 1755 | NS_IMPL_COCOA=no | 1758 | NS_IMPL_COCOA=no |
| 1756 | NS_IMPL_GNUSTEP=no | 1759 | NS_IMPL_GNUSTEP=no |
| 1757 | tmp_CPPFLAGS="$CPPFLAGS" | 1760 | tmp_CPPFLAGS="$CPPFLAGS" |
| @@ -1768,13 +1771,13 @@ if test "${with_ns}" != no; then | |||
| 1768 | ns_appresdir=${ns_appdir}/Contents/Resources | 1771 | ns_appresdir=${ns_appdir}/Contents/Resources |
| 1769 | ns_appsrc=Cocoa/Emacs.base | 1772 | ns_appsrc=Cocoa/Emacs.base |
| 1770 | ns_fontfile=macfont.o | 1773 | ns_fontfile=macfont.o |
| 1774 | elif flags=$( (gnustep-config --objc-flags) 2>/dev/null); then | ||
| 1775 | NS_IMPL_GNUSTEP=yes | ||
| 1776 | NS_GNUSTEP_CONFIG=yes | ||
| 1777 | GNU_OBJC_CFLAGS=$flags | ||
| 1778 | LIBS_GNUSTEP=$(gnustep-config --gui-libs) || exit | ||
| 1771 | elif test -f $GNUSTEP_CONFIG_FILE; then | 1779 | elif test -f $GNUSTEP_CONFIG_FILE; then |
| 1772 | NS_IMPL_GNUSTEP=yes | 1780 | NS_IMPL_GNUSTEP=yes |
| 1773 | ns_appdir=`pwd`/nextstep/Emacs.app | ||
| 1774 | ns_appbindir=${ns_appdir} | ||
| 1775 | ns_appresdir=${ns_appdir}/Resources | ||
| 1776 | ns_appsrc=GNUstep/Emacs.base | ||
| 1777 | ns_fontfile=nsfont.o | ||
| 1778 | dnl FIXME sourcing this several times in subshells seems inefficient. | 1781 | dnl FIXME sourcing this several times in subshells seems inefficient. |
| 1779 | GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)" | 1782 | GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)" |
| 1780 | GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)" | 1783 | GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)" |
| @@ -1807,8 +1810,16 @@ fail; | |||
| 1807 | GNU_OBJC_CFLAGS="-fobjc-exceptions" | 1810 | GNU_OBJC_CFLAGS="-fobjc-exceptions" |
| 1808 | fi | 1811 | fi |
| 1809 | fi | 1812 | fi |
| 1813 | if test $NS_IMPL_GNUSTEP = yes; then | ||
| 1814 | ns_appdir=`pwd`/nextstep/Emacs.app | ||
| 1815 | ns_appbindir=${ns_appdir} | ||
| 1816 | ns_appresdir=${ns_appdir}/Resources | ||
| 1817 | ns_appsrc=GNUstep/Emacs.base | ||
| 1818 | ns_fontfile=nsfont.o | ||
| 1819 | fi | ||
| 1810 | 1820 | ||
| 1811 | dnl This is only used while we test the NS headers, it gets reset below. | 1821 | dnl This is only used while we test the NS headers, it gets reset below. |
| 1822 | CPPFLAGS="$CPPFLAGS $GNU_OBJC_CFLAGS" | ||
| 1812 | CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS" | 1823 | CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS" |
| 1813 | 1824 | ||
| 1814 | AC_CHECK_HEADER([AppKit/AppKit.h], [HAVE_NS=yes], | 1825 | AC_CHECK_HEADER([AppKit/AppKit.h], [HAVE_NS=yes], |
| @@ -3375,11 +3386,13 @@ if test "${HAVE_NS}" = "yes"; then | |||
| 3375 | fi | 3386 | fi |
| 3376 | if test "${NS_IMPL_GNUSTEP}" = "yes"; then | 3387 | if test "${NS_IMPL_GNUSTEP}" = "yes"; then |
| 3377 | AC_DEFINE(NS_IMPL_GNUSTEP, 1, [Define to 1 if you are using NS windowing under GNUstep.]) | 3388 | AC_DEFINE(NS_IMPL_GNUSTEP, 1, [Define to 1 if you are using NS windowing under GNUstep.]) |
| 3378 | # See also .m.o rule in Makefile.in */ | 3389 | if test $NS_GNUSTEP_CONFIG != yes; then |
| 3379 | # FIXME: are all these flags really needed? Document here why. */ | 3390 | # See also .m.o rule in src/Makefile.in. */ |
| 3380 | GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}" | 3391 | # FIXME: are all these flags really needed? Document here why. */ |
| 3381 | ## Extra CFLAGS applied to src/*.m files. | 3392 | GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}" |
| 3382 | GNU_OBJC_CFLAGS="$GNU_OBJC_CFLAGS -fgnu-runtime -Wno-import -fconstant-string-class=NSConstantString -DGNUSTEP_BASE_LIBRARY=1 -DGNU_GUI_LIBRARY=1 -DGNU_RUNTIME=1 -DGSWARN -DGSDIAGNOSE" | 3393 | ## Extra CFLAGS applied to src/*.m files. |
| 3394 | GNU_OBJC_CFLAGS="$GNU_OBJC_CFLAGS -fgnu-runtime -Wno-import -fconstant-string-class=NSConstantString -DGNUSTEP_BASE_LIBRARY=1 -DGNU_GUI_LIBRARY=1 -DGNU_RUNTIME=1 -DGSWARN -DGSDIAGNOSE" | ||
| 3395 | fi | ||
| 3383 | fi | 3396 | fi |
| 3384 | OTHER_FILES=ns-app | 3397 | OTHER_FILES=ns-app |
| 3385 | fi | 3398 | fi |
diff --git a/etc/ChangeLog b/etc/ChangeLog index 47f61f4d7fd..55b835c0cf9 100644 --- a/etc/ChangeLog +++ b/etc/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2015-01-25 Paul Eggert <eggert@cs.ucla.edu> | ||
| 2 | |||
| 3 | Use gnustep-config if available | ||
| 4 | * NEWS: Document this. | ||
| 5 | |||
| 1 | 2015-01-22 Paul Eggert <eggert@cs.ucla.edu> | 6 | 2015-01-22 Paul Eggert <eggert@cs.ucla.edu> |
| 2 | 7 | ||
| 3 | Don't downcase system diagnostics' first letters | 8 | Don't downcase system diagnostics' first letters |
| @@ -36,6 +36,9 @@ should be able to work around the problem either by porting the Emacs | |||
| 36 | undumping code to GCC under IRIX, or by configuring --with-wide-int, | 36 | undumping code to GCC under IRIX, or by configuring --with-wide-int, |
| 37 | or by sticking with Emacs 24.4. | 37 | or by sticking with Emacs 24.4. |
| 38 | 38 | ||
| 39 | ** 'configure' now prefers gnustep-config when configuring GNUstep. | ||
| 40 | If gnustep-config is not available, the old heuristics are used. | ||
| 41 | |||
| 39 | --- | 42 | --- |
| 40 | ** The configure option `--with-pkg-config-prog' has been removed. | 43 | ** The configure option `--with-pkg-config-prog' has been removed. |
| 41 | Use './configure PKG_CONFIG=/full/name/of/pkg-config' if you need to. | 44 | Use './configure PKG_CONFIG=/full/name/of/pkg-config' if you need to. |
diff --git a/src/ChangeLog b/src/ChangeLog index a8b9c3bf1c6..96e31468a3d 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,3 +1,10 @@ | |||
| 1 | 2015-01-25 Paul Eggert <eggert@cs.ucla.edu> | ||
| 2 | |||
| 3 | Use gnustep-config if available | ||
| 4 | * emacs.c [NS_IMPL_GNUSTEP]: Don't include <GNUstepBase/GSConfig.h>. | ||
| 5 | It doesn't appear to be needed, and the inclusion breaks on | ||
| 6 | Ubuntu 14.10 when 'configure' uses 'gnustep-config'. | ||
| 7 | |||
| 1 | 2015-01-22 Eli Zaretskii <eliz@gnu.org> | 8 | 2015-01-22 Eli Zaretskii <eliz@gnu.org> |
| 2 | 9 | ||
| 3 | * xdisp.c (init_iterator): Restore a comment lost in transition. | 10 | * xdisp.c (init_iterator): Restore a comment lost in transition. |
diff --git a/src/emacs.c b/src/emacs.c index ca1a8b26d81..345fe3e75b8 100644 --- a/src/emacs.c +++ b/src/emacs.c | |||
| @@ -59,11 +59,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 59 | #include TERM_HEADER | 59 | #include TERM_HEADER |
| 60 | #endif /* HAVE_WINDOW_SYSTEM */ | 60 | #endif /* HAVE_WINDOW_SYSTEM */ |
| 61 | 61 | ||
| 62 | #ifdef NS_IMPL_GNUSTEP | ||
| 63 | /* At least under Debian, GSConfig is in a subdirectory. --Stef */ | ||
| 64 | #include <GNUstepBase/GSConfig.h> | ||
| 65 | #endif | ||
| 66 | |||
| 67 | #include "commands.h" | 62 | #include "commands.h" |
| 68 | #include "intervals.h" | 63 | #include "intervals.h" |
| 69 | #include "character.h" | 64 | #include "character.h" |