summaryrefslogtreecommitdiff
path: root/community/libircclient/shared.patch
blob: ac57fe3a8e511c1a105b88789f75fa55f2175342 (plain)
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
diff -aur libircclient-1.3/src/Makefile.in libircclient-1.3.patched/src/Makefile.in
--- libircclient-1.3/src/Makefile.in	2005-03-09 22:11:53.000000000 +0100
+++ libircclient-1.3.patched/src/Makefile.in	2012-01-05 05:46:21.000000000 +0100
@@ -4,21 +4,22 @@
 AR=@AR@ cr
 RANLIB=@RANLIB@
 INCLUDES=-I../include
-
+DESTDIR+=
 
 OBJS = libircclient.o
 
 all:	lib
 
-lib:	libircclient.a
+lib:	libircclient.a libircclient.so
 
 install: lib
-	-mkdir @prefix@/include
-	-mkdir @prefix@/lib
-	cp ../include/libircclient.h @prefix@/include/libircclient.h
-	cp ../include/libirc_errors.h @prefix@/include/libirc_errors.h
-	cp ../include/libirc_events.h  @prefix@/include/libirc_events.h 
-	cp libirc.a @prefix@/include/lib/libirc.a
+	mkdir -p $(DESTDIR)/usr/{lib,include/libircclient}
+	mkdir -p $(DESTDIR)/usr/share/{man,{doc,}/libircclient}
+	cp libircclient.a libircclient.so  $(DESTDIR)/usr/lib
+	cp ../include/libirc*.h  $(DESTDIR)/usr/include/libircclient
+	cp -a ../doc/{html,rfc1459.txt} $(DESTDIR)/usr/share/doc/libircclient
+	cp -a ../examples $(DESTDIR)/usr/share/libircclient
+	cp -a ../doc/man/man3 $(DESTDIR)/usr/share/man
 
 $(OBJS): utils.c dcc.c errors.c portable.c sockets.c colors.c
 
@@ -26,6 +27,9 @@
 	$(AR) libircclient.a $(OBJS)
 	$(RANLIB) libircclient.a
 
+libircclient.so: $(OBJS)
+	$(CC) -shared -Wl $(OBJS) -o libircclient.so
+
 clean:
 	rm -f libircclient.a $(OBJS)