emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Can't compile


From: Germán Arias
Subject: Re: Can't compile
Date: Fri, 12 Aug 2011 17:02:45 -0600

On mié, 2011-08-10 at 17:59 -0600, Germán Arias wrote: 
> On mié, 2011-08-10 at 16:44 -0600, Davis Herring wrote:
> > 
> > By keeping the "-x objective-c" you're telling the compiler that all
> > subsequent files are Objective C files, including ../lib/libgnu.a.
> > 
> > You'll have to find some way to restrict those flags to only the actual
> > source files, perhaps by countermanding them with "-x none" later.
> 
> This solve the problem. Thanks.
> 
> > 
> > Davis
> > 

Now I have other problem. These are my changes:

=== modified file 'configure.in'
--- configure.in/s /    2011-08-04 17:04:39 +0000
+++ configure.in        2011-08-12 05:07:55 +0000
@@ -219,6 +219,14 @@
 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
      GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf

+GS_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo
$GNUSTEP_LOCAL_HEADERS)"
+
+if grep "BASE_NATIVE_OBJC_EXCEPTIONS     1"
${GS_LOCAL_HEADERS}/GNUstepBase/GSConfig.h; then
+  AC_DEFINE(_NATIVE_OBJC_EXCEPTIONS, 1, [Synchronize native exceptions
with gnustep-base.])
+else
+  AC_DEFINE(_NATIVE_OBJC_EXCEPTIONS, 0, [Synchronize native exceptions
with gnustep-base.])
+fi
+
 AC_ARG_ENABLE(ns-self-contained,
 [AS_HELP_STRING([--disable-ns-self-contained],
                 [disable self contained build under NeXTstep])],
@@ -1488,6 +1496,9 @@
 CPPFLAGS="$CPPFLAGS -x objective-c"
 CFLAGS="$CFLAGS -x objective-c"
 TEMACS_LDFLAGS2="\${LDFLAGS}"
+if _NATIVE_OBJC_EXCEPTIONS=1; then
+   CFLAGS="$CFLAGS -fobjc-exceptions"
+fi
 dnl I don't think it's especially important, but src/Makefile.in
 dnl (now the only user of ns_appdir) used to go to the trouble of
adding a
 dnl trailing "/" to it, so now we do it here.
@@ -2560,7 +2571,10 @@
     AC_DEFINE(NS_IMPL_GNUSTEP, 1, [Define to 1 if you are using NS
windowing under GNUstep.])
     # See also .m.o rule in Makefile.in */
     # FIXME: are all these flags really needed?  Document here why.  */
-    C_SWITCH_X_SYSTEM="-D_REENTRANT -fPIC -fno-strict-aliasing"
+    C_SWITCH_X_SYSTEM="-D_REENTRANT -fPIC -fno-strict-aliasing -I
${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
+    if _NATIVE_OBJC_EXCEPTIONS=1; then
+       C_SWITCH_X_SYSTEM="$C_SWITCH_X_SYSTEM -fobjc-exceptions"
+    fi
     GNU_OBJC_CFLAGS="-fgnu-runtime -Wno-import
-fconstant-string-class=NSConstantString -DGNUSTEP_BASE_LIBRARY=1
-DGNU_GUI_LIBRARY=1 -DGNU_RUNTIME=1 -DGSWARN -DGSDIAGNOSE"
   fi
   if test "${NS_HAVE_NSINTEGER}" = "yes"; then


And I get the error:

Compiling hilit-chg.el
Wrote /home/german/Instalados/emacs/lisp/hilit-chg.elc
Compiling hippie-exp.el
Wrote /home/german/Instalados/emacs/lisp/hippie-exp.elc
Compiling hl-line.el
Wrote /home/german/Instalados/emacs/lisp/hl-line.elc
Compiling htmlfontify.el
Aborted
make[3]: *** [htmlfontify.elc] Error 134
make[3]: Leaving directory `/home/german/Instalados/emacs/lisp'
make[2]: *** [compile-main] Error 2
make[2]: Leaving directory `/home/german/Instalados/emacs/lisp'
make[1]: *** [lisp] Error 2
make[1]: Leaving directory `/home/german/Instalados/emacs'
make: *** [bootstrap] Error 2
address@hidden:~/Instalados/emacs$ fmake distclean
bash: fmake: command not found

As you can see, I added flags in C_SWITCH_X_SYSTEM. Instead add these in
a global way. Well, I get a lot of warning about that -fobjc-exceptions
is only for ObjC/ObjC++ files. But all files: nsterm.c, emacs.c .....
where gnustep is used, now compile fine (If I don't add this flag, the
compilation stops and show a message requiring this flag.). But the
compilation suddenly stop in htmlfontify.el without more info. Any
advice? Thanks.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]