Removed
Link Here
|
1 |
--- lib/Makefile.orig 2021-11-22 01:09:04 UTC |
2 |
+++ lib/Makefile |
3 |
@@ -6,6 +6,7 @@ |
4 |
VERSION = 0.1 |
5 |
LIBRARY = bsddialog |
6 |
LIBRARY_SO = lib${LIBRARY:=.so} |
7 |
+LIBRARY_A = lib${LIBRARY:=.a} |
8 |
HEADERS = bsddialog.h bsddialog_theme.h |
9 |
SOURCES = barbox.c editorbox.c formbox.c lib_util.c menubox.c textbox.c \ |
10 |
timebox.c commandbox.c filebox.c infobox.c libbsddialog.c messagebox.c \ |
11 |
@@ -13,8 +14,8 @@ SOURCES = barbox.c editorbox.c formbox.c lib_util.c me |
12 |
OBJECTS= ${SOURCES:.c=.o} |
13 |
FBSDFLAGS= -O2 -pipe -std=gnu99 -Wno-format-zero-length \ |
14 |
-fstack-protector-strong -Qunused-arguments |
15 |
-CFLAGS = -I/usr/local/include -fPIC -Wall -Wextra ${FBSDFLAGS} |
16 |
-LDFLAGS = -fstack-protector-strong -shared -Wl,-x -Wl,--fatal-warnings \ |
17 |
+CFLAGS += -fPIC -Wall -Wextra ${FBSDFLAGS} |
18 |
+LDFLAGS += -fstack-protector-strong -shared -Wl,-x -Wl,--fatal-warnings \ |
19 |
-Wl,--warn-shared-textrel -Wl,-soname,${LIBRARY_SO}.${VERSION} |
20 |
|
21 |
INSTALL_PREFIX=/usr/local |
22 |
@@ -43,11 +44,18 @@ RM= rm -f |
23 |
#all : man ${LIBRARY} |
24 |
all : ${LIBRARY} |
25 |
|
26 |
-${LIBRARY}: ${OBJECTS} |
27 |
+${LIBRARY}: ${LIBRARY_SO} ${LIBRARY_A} |
28 |
+ |
29 |
+${LIBRARY_SO}.${VERSION}: ${OBJECTS} |
30 |
${CC} ${LDFLAGS} ${.ALLSRC} -o ${LIBRARY_SO}.${VERSION} |
31 |
- # LN for devel |
32 |
+ |
33 |
+${LIBRARY_SO}: ${LIBRARY_SO}.${VERSION} |
34 |
${LN} ${LIBRARY_SO}.${VERSION} ${LIBRARY_SO} |
35 |
|
36 |
+${LIBRARY_A}: ${OBJECTS} |
37 |
+ ${AR} cr ${.TARGET} ${OBJECTS} |
38 |
+ ${RANLIB} ${.TARGET} |
39 |
+ |
40 |
.c.o: |
41 |
${CC} ${CFLAGS} -c ${.IMPSRC} -o ${.TARGET} |
42 |
|
43 |
@@ -59,11 +67,12 @@ clean: |
44 |
|
45 |
|
46 |
install: |
47 |
- ${CP} ${LIBRARY}.h ${INSTALL_PREFIX}/include |
48 |
- ${CP} ${LIBRARY_SO}.${VERSION} ${INSTALL_PREFIX}/lib/ |
49 |
- ${LN} ${INSTALL_PREFIX}/lib/${LIBRARY_SO}.${VERSION} ${INSTALL_PREFIX}/lib/${LIBRARY_SO} |
50 |
- ${LDCONFIG} ${INSTALL_PREFIX}/lib |
51 |
- ${CP} ${LIBRARY}.3.gz ${INSTALL_PREFIX}/man/man3/ |
52 |
+ ${INSTALL} -m 644 ${HEADERS} ${DESTDIR}${INSTALL_PREFIX}/include |
53 |
+ ${INSTALL} -m 644 -s ${LIBRARY_SO}.${VERSION} ${DESTDIR}${INSTALL_PREFIX}/lib/ |
54 |
+ ${INSTALL} -l rs ${DESTDIR}${INSTALL_PREFIX}/lib/${LIBRARY_SO}.${VERSION} ${DESTDIR}${INSTALL_PREFIX}/lib/${LIBRARY_SO} |
55 |
+ ${INSTALL} -m 644 ${LIBRARY_A} ${DESTDIR}/${INSTALL_PREFIX}/lib |
56 |
+ #${LDCONFIG} ${INSTALL_PREFIX}/lib |
57 |
+ #${CP} ${LIBRARY}.3.gz ${INSTALL_PREFIX}/man/man3/ |
58 |
|
59 |
unistall: |
60 |
${RM} ${INSTALL_PREFIX}/include/${LIBRARY}.h |