blob: e06088ac656575d6fc7c83151db505deba73e017 (
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
|
$NetBSD: patch-ab,v 1.16 2008/07/27 00:03:42 bjs Exp $
--- src/glu/sgi/Makefile.orig 2008-07-18 10:39:12.000000000 -0400
+++ src/glu/sgi/Makefile
@@ -8,7 +8,8 @@ include $(TOP)/configs/current
GLU_MAJOR = 1
GLU_MINOR = 3
-GLU_TINY = 0$(MESA_MAJOR)0$(MESA_MINOR)0$(MESA_TINY)
+GLU_TINY= 0 # What is the point of having such a strange versioning scheme?
+ # It breaks libtool, but I hate to say it: libtool is right!
INCDIRS = -I$(TOP)/include -Iinclude -Iinternals -Ilibnurbs/internals -Ilibnurbs/interface -Ilibnurbs/nurbtess
@@ -115,10 +116,12 @@ OBJECTS = $(C_OBJECTS) $(CC_OBJECTS)
##### RULES #####
.c.o:
- $(CC) -c $(INCDIRS) $(CFLAGS) -DNDEBUG -DLIBRARYBUILD $< -o $@
+ $(LIBTOOL) --mode=compile --tag=CC $(CC) -c $(INCDIRS) \
+ $(CFLAGS) $(COPTS) -DNDEBUG -DLIBRARYBUILD $< -o $(@:.o=.lo)
.cc.o:
- $(CXX) -c $(INCDIRS) $(CXXFLAGS) -DNDEBUG -DLIBRARYBUILD $< -o $@
+ $(LIBTOOL) --mode=compile --tag=CXX $(CXX) -c $(INCDIRS) \
+ $(CXXFLAGS) -DNDEBUG -DLIBRARYBUILD $< -o $(@:.o=.lo)
##### TARGETS #####
@@ -136,11 +139,12 @@ $(TOP)/$(LIB_DIR):
# Make the library:
$(TOP)/$(LIB_DIR)/$(GLU_LIB_NAME): $(OBJECTS)
- $(TOP)/bin/mklib -o $(GLU_LIB) -linker '$(CXX)' -ldflags '$(LDFLAGS)' \
- -major $(GLU_MAJOR) -minor $(GLU_MINOR) -patch $(GLU_TINY) \
- -cplusplus $(MKLIB_OPTIONS) -install $(TOP)/$(LIB_DIR) \
- -exports glu.exports \
- $(GLU_LIB_DEPS) $(OBJECTS)
+ $(LIBTOOL) --mode=link $(CXX) \
+ -o $(TOP)/$(LIB_DIR)/$(GLU_LIB_NAME:.so=.la) $(LDFLAGS) \
+ -rpath $(PREFIX)/lib $(GLU_LIB_DEPS) $(OBJECTS:.o=.lo) \
+ -version-info $(GLU_MAJOR):$(GLU_MINOR):$(GLU_TINY) \
+ -export-symbols glu.sym
+
clean:
|