diff options
author | joerg <joerg> | 2007-04-20 15:05:22 +0000 |
---|---|---|
committer | joerg <joerg> | 2007-04-20 15:05:22 +0000 |
commit | 452f954220ce32685462afc90d5d52d5b040293a (patch) | |
tree | c0f3e26e2f5f717eb190642d4a4efc1425f48d3f /editors | |
parent | 94d77ebb7745dcf9896ea41a2f1d9d25e7477ca7 (diff) | |
download | pkgsrc-452f954220ce32685462afc90d5d52d5b040293a.tar.gz |
Fix build on DragonFly 1.8+
Diffstat (limited to 'editors')
-rw-r--r-- | editors/xemacs/Makefile.common | 6 | ||||
-rw-r--r-- | editors/xemacs/files/dragonfly.h | 13 |
2 files changed, 17 insertions, 2 deletions
diff --git a/editors/xemacs/Makefile.common b/editors/xemacs/Makefile.common index ae7077dcce0..408c0a77014 100644 --- a/editors/xemacs/Makefile.common +++ b/editors/xemacs/Makefile.common @@ -1,4 +1,4 @@ -# $NetBSD: Makefile.common,v 1.18 2007/02/15 14:27:48 joerg Exp $ +# $NetBSD: Makefile.common,v 1.19 2007/04/20 15:05:22 joerg Exp $ DISTNAME= xemacs-21.4.17 CATEGORIES= editors @@ -72,6 +72,10 @@ CONFIGURE_ARGS+= --with_sound=none . endif .endif +.if ${OPSYS} == "DragonFly" && exists(/usr/lib/crtbegin.o) +CPPFLAGS+= -DDFLY_PRE_17_CRT +.endif + .if defined(MANZ) PLIST_SUBST+= ELSUFX='.gz' .else diff --git a/editors/xemacs/files/dragonfly.h b/editors/xemacs/files/dragonfly.h index 742fce1e649..7c6a4e4df33 100644 --- a/editors/xemacs/files/dragonfly.h +++ b/editors/xemacs/files/dragonfly.h @@ -33,9 +33,20 @@ #include <stddef.h> #endif #define LD_SWITCH_SYSTEM + +#if defined(__GNUC__) && __GNUC__ == 3 && __GNUC_MINOR__ == 4 +# ifndef DFLY_PRE_17_CRT +#define START_FILES pre-crt0.o /usr/lib/gcc34/crt1.o /usr/lib/gcc34/crti.o /usr/lib/gcc34/crtbegin.o +#define LIB_STANDARD -L/usr/lib/gcc34 -lgcc -lc -lgcc /usr/lib/gcc34/crtend.o /usr/lib/gcc34/crtn.o +# else #define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o /usr/lib/crtbegin.o -#define UNEXEC "unexelf.o" #define LIB_STANDARD -L/usr/lib/gcc34 -lgcc -lc -lgcc /usr/lib/crtend.o /usr/lib/crtn.o +# endif +#else +#error "Add compiler version magic" +#endif + +#define UNEXEC "unexelf.o" #define LINKER "$(CC) -nostdlib" #undef LIB_GCC #define LIB_GCC |