Lucio Correia wrote:
There is a problem when compiling extensions on PPC64 and Cell
platforms. This occurs because TARGET_CFLAGS is not used by extension
compilation command, what causes the extensions to be compiled as
32-bit. This patch corrects this issue.
Signed-off-by: Lucio Correia <luciojhc(a)br.ibm.com>
diff -Nurp crash-4.0-4.1.orig/extensions/Makefile crash-4.0-4.1/extensions/Makefile
--- crash-4.0-4.1.orig/extensions/Makefile 2007-04-26 17:45:59.000000000 -0300
+++ crash-4.0-4.1/extensions/Makefile 2007-05-25 15:09:02.000000000 -0300
@@ -34,8 +34,9 @@ link_defs:
ln -s ../defs.h; fi
echo.so: ../defs.h echo.c
- gcc -nostartfiles -shared -rdynamic -o echo.so echo.c -fPIC -D$(TARGET)
+ gcc -nostartfiles -shared -rdynamic -o echo.so echo.c -fPIC \
+ -D$(TARGET) $(TARGET_CFLAGS)
dminfo.so: ../defs.h dminfo.c
- gcc -nostartfiles -shared -rdynamic -o dminfo.so dminfo.c -fPIC -D$(TARGET)
-
+ gcc -nostartfiles -shared -rdynamic -o dminfo.so dminfo.c -fPIC \
+ -D$(TARGET) $(TARGET_CFLAGS)
diff -Nurp crash-4.0-4.1.orig/Makefile crash-4.0-4.1/Makefile
--- crash-4.0-4.1.orig/Makefile 2007-04-26 17:45:59.000000000 -0300
+++ crash-4.0-4.1/Makefile 2007-05-25 14:53:22.000000000 -0300
@@ -543,4 +543,5 @@ extensions: make_configure
@make --no-print-directory do_extensions
do_extensions:
- @(cd extensions; make -i OBJECTS="$(EXTENSION_OBJECT_FILES)"
TARGET=$(TARGET))
+ @(cd extensions; make -i OBJECTS="$(EXTENSION_OBJECT_FILES)" \
+ TARGET=$(TARGET) TARGET_CFLAGS=$(TARGET_CFLAGS))
Looks fine to me -- queued for next release.
Thanks,
Dave