Package: libjconv / 2.8-7

build-system.patch Patch series | download
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
---
 Makefile |   11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

--- a/Makefile
+++ b/Makefile
@@ -2,17 +2,18 @@
 CC = gcc
 OBJS = conv.o info.o compat.o
 SRCS = $(OBJS:.o=.c)
-CFLAGS += -Wall -O9 -fPIC -DHAVE_CODESET
-#CFLAGS = -g -Wall -O0 -fPIC
+CFLAGS ?= -Wall -g -O2
+CFLAGS += -fPIC -DHAVE_CODESET
 PKGDIR = libjconv-2.8
+MAJOR = 2
 
 all: jconv libjconv.so libjconv.a default.conf
 
-jconv: jconv.o $(OBJS)
-	$(CC) $(CFLAGS) $(LDFLAGS) -o jconv jconv.o $(OBJS)
+jconv: jconv.o libjconv.so
+	$(CC) $(CFLAGS) $(LDFLAGS) -o jconv jconv.o -L. -ljconv
 
 libjconv.so: $(OBJS)
-	$(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname,libjconv.so.0 -o libjconv.so $(OBJS)
+	$(CC) $(CFLAGS) $(LDFLAGS) -shared -Wl,-soname,libjconv.so.$(MAJOR) -o libjconv.so $(OBJS)
 
 libjconv.a: $(OBJS)
 	ar rc libjconv.a $(OBJS)