Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 229109 Details for
Bug 306831
app-editors/emacs directly refers to /usr/lib/crt0.o , etc.
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
emacs-22.3-crt-dir.patch
emacs-22.3-crt-dir.patch (text/plain), 4.96 KB, created by
Ulrich Müller
on 2010-04-25 17:40:30 UTC
(
hide
)
Description:
emacs-22.3-crt-dir.patch
Filename:
MIME Type:
Creator:
Ulrich Müller
Created:
2010-04-25 17:40:30 UTC
Size:
4.96 KB
patch
obsolete
>--- emacs-22.3-orig/configure.in >+++ emacs-22.3/configure.in >@@ -129,6 +129,12 @@ > specify install directory for Emacs.app on Mac OS X]], > [ carbon_appdir_x=${enableval}]) > >+CRT_DIR= >+AC_ARG_WITH([crt-dir],dnl >+[AS_HELP_STRING([--with-crt-dir=DIR],[directory containing crtn.o etc. >+This option is only used on x86-64 and s390x GNU/Linux architectures.])]) >+CRT_DIR="${with_crt_dir}" >+ > AC_ARG_ENABLE(asserts, > [ --enable-asserts compile code with asserts enabled], > USE_XASSERTS=$enableval, >@@ -1564,15 +1570,31 @@ > AC_SYS_LARGEFILE > > >-### The standard library on x86-64 GNU/Linux distributions can >-### be located in either /usr/lib64 or /usr/lib. >+## Note: at present CRT_DIR is only used for amdx86-64 and ibms390x. >+## Other machine types hard-code the location in src/[ms]/*.h. > case "${canonical}" in > x86_64-*-linux-gnu* | s390x-*-linux-gnu* ) >- if test -d /usr/lib64; then >- AC_DEFINE(HAVE_X86_64_LIB64_DIR, 1, >- [Define to 1 if the file /usr/lib64 exists.]) >-fi >+ >+ ## On x86-64 and s390x GNU/Linux distributions, the standard library >+ ## can be in a variety of places. We only try /usr/lib64 and /usr/lib. >+ ## For anything else (eg /usr/lib32), it is up the user to specify >+ ## the location (bug#5655). >+ ## Test for crtn.o, not just the directory, because sometimes the >+ ## directory exists but does not have the relevant files (bug#1287). >+ ## If user specified a crt-dir, use that unconditionally. >+ if test "X$CRT_DIR" = "X"; then >+ CRT_DIR=/usr/lib >+ test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64 >+ fi >+ >+ test -e $CRT_DIR/crtn.o || test -e $CRT_DIR/crt0.o || \ >+ AC_MSG_ERROR([crt*.o not found. Use --with-crt-dir to specify the location.]) >+ ;; >+ > esac >+test "X$CRT_DIR" = "X" && CRT_DIR=/usr/lib >+AC_SUBST(CRT_DIR) >+ > > dnl This function defintion taken from Gnome 2.0 > dnl PKG_CHECK_MODULES(GSTUFF, gtk+-2.0 >= 1.3 glib = 1.3.4, action-if, action-not) >--- emacs-22.3-orig/src/m/amdx86-64.h >+++ emacs-22.3/src/m/amdx86-64.h >@@ -109,7 +109,7 @@ > a native binary of Emacs on FreeBSD/amd64 we can just point to /usr/lib. */ > > #undef START_FILES >-#define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o >+#define START_FILES pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o > > /* The duplicate -lgcc is intentional in the definition of LIB_STANDARD. > The reason is that some functions in libgcc.a call functions from libc.a, >@@ -117,14 +117,14 @@ > versions of ld are one-pass linkers, we need to mention -lgcc twice, > or else we risk getting unresolved externals. */ > #undef LIB_STANDARD >-#define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtn.o >+#define LIB_STANDARD -lgcc -lc -lgcc $(CRT_DIR)/crtn.o > > #elif defined(__OpenBSD__) > > #undef START_FILES >-#define START_FILES pre-crt0.o /usr/lib/crt0.o /usr/lib/crtbegin.o >+#define START_FILES pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o > #undef LIB_STANDARD >-#define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtend.o >+#define LIB_STANDARD -lgcc -lc -lgcc $(CRT_DIR)/crtend.o > > #elif defined(__NetBSD__) > >@@ -138,11 +138,7 @@ > #else /* !__OpenBSD__ && !__FreeBSD__ && !__NetBSD__ && !sun */ > > #undef START_FILES >-#ifdef HAVE_X86_64_LIB64_DIR >-#define START_FILES pre-crt0.o /usr/lib64/crt1.o /usr/lib64/crti.o >-#else >-#define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o >-#endif >+#define START_FILES pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o > > /* The duplicate -lgcc is intentional in the definition of LIB_STANDARD. > The reason is that some functions in libgcc.a call functions from libc.a, >@@ -150,11 +146,7 @@ > versions of ld are one-pass linkers, we need to mention -lgcc twice, > or else we risk getting unresolved externals. */ > #undef LIB_STANDARD >-#ifdef HAVE_X86_64_LIB64_DIR >-#define LIB_STANDARD -lgcc -lc -lgcc /usr/lib64/crtn.o >-#else >-#define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtn.o >-#endif >+#define LIB_STANDARD -lgcc -lc -lgcc $(CRT_DIR)/crtn.o > > #endif /* __FreeBSD__ */ > >--- emacs-22.3-orig/src/m/ibms390x.h >+++ emacs-22.3/src/m/ibms390x.h >@@ -161,18 +161,10 @@ > #define XPNTR(a) XUINT (a) > > #undef START_FILES >-#ifdef HAVE_X86_64_LIB64_DIR >-#define START_FILES pre-crt0.o /usr/lib64/crt1.o /usr/lib64/crti.o >-#else >-#define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o >-#endif >+#define START_FILES pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o > > #undef LIB_STANDARD >-#ifdef HAVE_X86_64_LIB64_DIR >-#define LIB_STANDARD -lgcc -lc -lgcc /usr/lib64/crtn.o >-#else >-#define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtn.o >-#endif >+#define LIB_STANDARD -lgcc -lc -lgcc $(CRT_DIR)/crtn.o > > /* arch-tag: 4b87653c-6add-4663-8691-7d9dc17b5519 > (do not change this comment) */ >--- emacs-22.3-orig/src/Makefile.in >+++ emacs-22.3/src/Makefile.in >@@ -63,6 +63,9 @@ > S_FILE = ${srcdir}/@opsysfile@ > config_h = config.h $(M_FILE) $(S_FILE) > >+## Only used by amdx86-64 and ibms390x GNU/Linux. >+CRT_DIR=@CRT_DIR@ >+ > # ========================== start of cpp stuff ======================= > /* From here on, comments must be done in C syntax. */ >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 306831
:
221151
| 229109 |
229111