ca70938428
which are the full option names used to set rpath directives for the linker and the compiler, respectively. In places were we are invoking the linker, use "${LINKER_RPATH_FLAG} <path>", where the space is inserted in case the flag is a word, e.g. -rpath. The default values of *_RPATH_FLAG are set by the compiler/*.mk files, depending on the compiler that you use. They may be overridden on a ${OPSYS}-specific basis by setting _OPSYS_LINKER_RPATH_FLAG and _OPSYS_COMPILER_RPATH_FLAG, respectively. Garbage-collect _OPSYS_RPATH_NAME and _COMPILER_LD_FLAG.
34 lines
900 B
Text
34 lines
900 B
Text
$NetBSD: patch-aa,v 1.2 2004/08/27 06:29:10 jlam Exp $
|
|
|
|
--- makefile.orig 2004-01-29 22:54:22.000000000 +0000
|
|
+++ makefile 2004-01-29 22:58:13.000000000 +0000
|
|
@@ -1,5 +1,5 @@
|
|
# Compilation parameters
|
|
-CC = gcc
|
|
+#CC= gcc
|
|
CWARNS = -Wall -pedantic \
|
|
-Waggregate-return \
|
|
-Wcast-align \
|
|
@@ -11,8 +11,8 @@
|
|
-Wwrite-strings
|
|
|
|
|
|
-CFLAGS = $(CONFIG) $(CWARNS) -ansi -g -O2 -I/usr/local/include/lua5 \
|
|
- -L./expat/xmlparse
|
|
+CFLAGS+= $(CONFIG) -O2 -I${PREFIX}/include \
|
|
+ -L${PREFIX}/lib
|
|
|
|
VERSION= 1.0a
|
|
PKG = luaexpat-$(VERSION)
|
|
@@ -23,9 +23,10 @@
|
|
test.lua \
|
|
index.html manual.html lua.png
|
|
|
|
+all: liblxp.so
|
|
|
|
liblxp.so : lxplib.o
|
|
- ld -o liblxp.so -shared lxplib.o -lexpat
|
|
+ ld -o liblxp.so -L${PREFIX}/lib ${COMPILER_RPATH_FLAG}${PREFIX}/lib -shared lxplib.o -lexpat
|
|
|
|
liblxp.dylib : lxplib.o
|
|
gcc -o liblxp.dylib -dynamiclib lxplib.o -lexpat -llua.5.0 -llualib.5.0
|