freebsd-ports/chinese/autoconvert/files/patch-ab

25 lines
867 B
Text

--- hzconvert/Makefile.orig Mon Jan 8 11:03:21 2001
+++ hzconvert/Makefile Mon Mar 22 09:39:15 2004
@@ -1,18 +1,18 @@
CC=gcc -I../include
-CFLAGS=-O2 -Wall -g
+CFLAGS+=-fPIC -Wall -g
SHARED_LIB=libhz.so
SHARED_LIB_MAJOR=$(SHARED_LIB).0
SHARED_LIB_MINOR=$(SHARED_LIB_MAJOR).0
OBJS=b2g.o b2u.o g2u.o hz2gb.o b2g_tables.o b2u_tables.o g2u_tables.o io.o unicode.o judge.o judge3.o gbpercent.o b5percent.o search.o
+all: libhzconvert
+
%.o: %.c
$(CC) -fPIC $(CFLAGS) -c $<
-all: libhzconvert
-
libhzconvert: $(OBJS)
ar rs ../lib/libhz.a $(OBJS)
- gcc -fPIC -shared -Wl,-soname,$(SHARED_LIB_MAJOR) -o ../lib/$(SHARED_LIB_MINOR) $(OBJS) -ldl
+ gcc -fPIC -shared -Wl,-soname,$(SHARED_LIB_MAJOR) -o ../lib/$(SHARED_LIB_MINOR) $(OBJS)
rm -f ../lib/$(SHARED_LIB_MAJOR)
rm -f ../lib/$(SHARED_LIB)
cd ../lib;ln -s $(SHARED_LIB_MINOR) $(SHARED_LIB_MAJOR)