about summary refs log tree commit diff
path: root/linuxthreads/sysdeps
diff options
context:
space:
mode:
Diffstat (limited to 'linuxthreads/sysdeps')
-rw-r--r--linuxthreads/sysdeps/unix/sysv/linux/x86_64/Makefile9
1 files changed, 9 insertions, 0 deletions
diff --git a/linuxthreads/sysdeps/unix/sysv/linux/x86_64/Makefile b/linuxthreads/sysdeps/unix/sysv/linux/x86_64/Makefile
new file mode 100644
index 0000000000..50b4ee38fb
--- /dev/null
+++ b/linuxthreads/sysdeps/unix/sysv/linux/x86_64/Makefile
@@ -0,0 +1,9 @@
+ifeq ($(subdir),linuxthreads)
+# gcc -m64 has /usr/lib64/crti.o hardcoded in the specs file, because otherwise
+# it would normally find 32bit crti.o.
+LDFLAGS-pthread.so += -specs=$(objpfx)specs
+before-compile += $(objpfx)specs
+generated += specs
+$(objpfx)specs:
+	$(CC) $(CFLAGS) $(CPPFLAGS) -dumpspecs | sed 's_/usr/lib64/crti.o_crti.o_g' > $@
+endif