cross

cross-compilation toolchain using musl libc
git clone git://z3bra.org/cross
Log | Files | Refs | README

pcc-1.1.0-deflibdirs.diff (1165B)


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
diff -urN a/cc/cc/cc.c b/cc/cc/cc.c
--- a/cc/cc/cc.c	2015-08-16 16:00:18.867457413 +0200
+++ b/cc/cc/cc.c	2015-08-16 16:03:28.963466133 +0200
@@ -207,9 +207,9 @@
 #endif
 #ifndef DEFLIBDIRS	/* default library search paths */
 #ifdef MULTIARCH_PATH
-#define DEFLIBDIRS	{ "/usr/lib/", 0 }
+#define DEFLIBDIRS	{ LIBDIR, 0 }
 #else
-#define DEFLIBDIRS	{ "/usr/lib/", "/usr/lib/" MULTIARCH_PATH "/", 0 }
+#define DEFLIBDIRS	{ LIBDIR, LIBDIR MULTIARCH_PATH "/", 0 }
 #endif
 #endif
 #ifndef DEFLIBS		/* default libraries included */
diff -urN a/os/linux/ccconfig.h b/os/linux/ccconfig.h
--- a/os/linux/ccconfig.h	2015-08-16 16:00:18.873457413 +0200
+++ b/os/linux/ccconfig.h	2015-08-16 16:05:23.446471384 +0200
@@ -48,9 +48,9 @@
 	"-D__amd64", "-D__LP64__", "-D_LP64", NULL, }
 #define	DYNLINKER { "-dynamic-linker", "/lib64/ld-linux-x86-64.so.2", NULL }
 #ifndef MULTIARCH_PATH
-#define	DEFLIBDIRS	{ "/usr/lib64/", 0 }
+#define	DEFLIBDIRS	{ LIBDIR, 0 }
 #else
-#define	DEFLIBDIRS	{ "/usr/lib64/", "/usr/lib/" MULTIARCH_PATH "/", 0 }
+#define	DEFLIBDIRS	{ LIBDIR, LIBDIR MULTIARCH_PATH "/", 0 }
 #endif
 #elif defined(mach_mips)
 #define CPPMDADD { "-D__mips__", NULL, }