blob: 3d383da12521b986c218179745b7462f81be2514 (
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
45
46
47
48
49
50
51
52
53
54
55
|
$NetBSD: patch-ae,v 1.11 2009/06/05 11:10:35 wiz Exp $
--- src/glw/Makefile.orig 2009-03-13 05:28:49 +0200
+++ src/glw/Makefile 2009-05-17 11:36:19 +0300
@@ -17,7 +17,8 @@ OBJECTS = $(GLW_SOURCES:.c=.o)
##### RULES #####
.c.o:
- $(CC) -c $(INCDIRS) $(CFLAGS) $<
+ $(LIBTOOL) --mode=compile --tag=CC \
+ $(CC) -c $(INCDIRS) $(CFLAGS) $(COPTS) -o $(@:.o=.lo) $<
@@ -38,12 +39,16 @@ glw.pc: glw.pc.in
$(pcedit) $< > $@
install: glw.pc
- $(INSTALL) -d $(DESTDIR)$(INSTALL_INC_DIR)/GL
- $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)
- $(INSTALL) -d $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig
- $(INSTALL) -m 644 *.h $(DESTDIR)$(INSTALL_INC_DIR)/GL
- $(INSTALL) $(TOP)/$(LIB_DIR)/$(GLW_LIB_GLOB) $(DESTDIR)$(INSTALL_LIB_DIR)
- $(INSTALL) -m 644 glw.pc $(DESTDIR)$(INSTALL_LIB_DIR)/pkgconfig
+ $(BSD_INSTALL_DATA_DIR) $(DESTDIR)$(INSTALL_DIR)/include/GL
+ $(BSD_INSTALL_LIB_DIR) $(DESTDIR)$(INSTALL_DIR)/lib
+ $(BSD_INSTALL_DATA_DIR) $(DESTDIR)$(INSTALL_DIR)/lib/pkgconfig
+ @for fn in *.h; do \
+ $(BSD_INSTALL_DATA) $$fn $(DESTDIR)$(INSTALL_DIR)/include/GL; \
+ done
+ $(LIBTOOL) --mode=install \
+ $(BSD_INSTALL_LIB) $(TOP)/$(LIB_DIR)/libGLw.la \
+ $(DESTDIR)$(INSTALL_DIR)/lib
+ $(BSD_INSTALL_DATA) glw.pc $(DESTDIR)$(INSTALL_DIR)/lib/pkgconfig
clean:
-rm -f depend depend.bak
@@ -52,12 +57,11 @@ clean:
# Make the library
$(TOP)/$(LIB_DIR)/$(GLW_LIB_NAME): $(OBJECTS)
- $(MKLIB) -o $(GLW_LIB) -linker '$(CC)' -ldflags '$(LDFLAGS)' \
- -major $(MAJOR) -minor $(MINOR) -patch $(TINY) \
- $(MKLIB_OPTIONS) -install $(TOP)/$(LIB_DIR) \
- -id $(INSTALL_LIB_DIR)/lib$(GLW_LIB).$(MAJOR).dylib \
- $(GLW_LIB_DEPS) $(OBJECTS)
-
+ $(LIBTOOL) --mode=link $(CC) \
+ -o $(TOP)/$(LIB_DIR)/$(GLW_LIB_NAME:.so=.la) \
+ -rpath $(PREFIX)/lib $(LDFLAGS) \
+ -version-info $(MAJOR):$(MINOR):$(TINY) \
+ $(GLW_LIB_DEPS) $(OBJECTS:.o=.lo)
#
# Run 'make depend' to update the dependencies if you change what's included
|