]> git.pld-linux.org Git - packages/libebml.git/blame - libebml-makefile.patch
- updated to 0.7.5, updated makefile patch
[packages/libebml.git] / libebml-makefile.patch
CommitLineData
36bcfddd
JB
1--- libebml-0.7.5/make/linux/Makefile.orig 2005-04-19 08:56:06.000000000 +0200
2+++ libebml-0.7.5/make/linux/Makefile 2005-06-12 20:47:04.374324344 +0200
5eef6fa9 3@@ -28,6 +28,7 @@
0928b7ec 4 INSTALL_OPTS = -m 644
5 INSTALL_OPTS_LIB = -m 644
6 INSTALL_DIR_OPTS = -m 755
7+LIBTOOL = libtool
8
9 # Options
10 EXTENSION=.cpp
5eef6fa9 11@@ -50,9 +51,7 @@
0928b7ec 12 LIBS=
13
14 # Names
15-LIBRARY=libebml.a
5eef6fa9
JB
16-LIBRARY_SO=libebml.so
17-LIBRARY_SO_VER=libebml.so.0
0928b7ec 18+LIBRARY=libebml.la
19
20 # source-files
21 sources:=$(wildcard ${SRC_DIR}*$(EXTENSION))
5eef6fa9
JB
22@@ -60,9 +59,8 @@
23 # header files; replace .cxx extension with .h
24 headers:=$(patsubst %$(EXTENSION),%.h,$(sources))
0928b7ec 25
26-# object files; replace .cxx extension with .o
27-objects:=$(patsubst %$(EXTENSION),%.o,$(sources))
5eef6fa9 28-objects_so:=$(patsubst %$(EXTENSION),%.lo,$(sources))
0928b7ec 29+# object files; replace .cxx extension with .lo
30+objects:=$(patsubst %$(EXTENSION),%.lo,$(sources))
31
17ee12f0
MC
32 WARNINGFLAGS=-Wall -Wno-unknown-pragmas -ansi -fno-gnu-keywords -Wshadow
33 COMPILEFLAGS=$(WARNINGFLAGS) $(CXXFLAGS) $(CPPFLAGS) $(DEBUGFLAGS) $(INCLUDE)
36bcfddd 34@@ -83,19 +81,11 @@
5eef6fa9 35 @false
0928b7ec 36
37 # Build rules
38-%.o: %$(EXTENSION)
17ee12f0 39- $(CXX) -c $(COMPILEFLAGS) -o $@ $<
5eef6fa9
JB
40-
41 %.lo: %$(EXTENSION)
42- $(CXX) -c $(COMPILEFLAGS) -fPIC -o $@ $<
43+ $(LIBTOOL) --mode=compile $(CXX) -c $(COMPILEFLAGS) -o $@ $<
0928b7ec 44
45 $(LIBRARY): $(objects)
46- $(AR) $@ $(objects)
47- $(RANLIB) $@
5eef6fa9
JB
48-
49-$(LIBRARY_SO): $(objects_so)
50- $(CXX) -shared -Wl,-soname,$(LIBRARY_SO_VER) -o $(LIBRARY_SO_VER) $(objects_so)
51- ln -s $(LIBRARY_SO_VER) $(LIBRARY_SO)
0928b7ec 52+ $(LIBTOOL) --mode=link $(LD) $(LDFLAGS) -o $@ $^ $(LIBS) -rpath $(libdir)
0928b7ec 53
54 clean:
5eef6fa9 55 rm -f $(objects) $(objects_so)
36bcfddd
JB
56@@ -120,26 +110,22 @@
57 ifeq (Darwin,$(shell uname -s))
58 install: install_staticlib install_headers
59 else
5eef6fa9
JB
60-install: install_staticlib install_sharedlib install_headers
61+install: install_lib install_headers
36bcfddd 62 endif
5eef6fa9
JB
63
64 install_headers:
0928b7ec 65- $(INSTALL) $(INSTALL_DIR_OPTS) -d $(includedir)
0928b7ec 66+ $(INSTALL) $(INSTALL_DIR_OPTS) -d $(DESTDIR)$(includedir)
67 for i in $(INCLUDE_DIR)/*.h; do \
68- $(INSTALL) $(INSTALL_OPTS) $$i $(includedir) ; \
69+ $(INSTALL) $(INSTALL_OPTS) $$i $(DESTDIR)$(includedir) ; \
70 done
71- $(INSTALL) $(INSTALL_DIR_OPTS) -d $(includedir)/c
72+ $(INSTALL) $(INSTALL_DIR_OPTS) -d $(DESTDIR)$(includedir)/c
73 for i in $(INCLUDE_DIR)/c/*.h; do \
74- $(INSTALL) $(INSTALL_OPTS) $$i $(includedir)/c ; \
75+ $(INSTALL) $(INSTALL_OPTS) $$i $(DESTDIR)$(includedir)/c ; \
76 done
77
5eef6fa9
JB
78-install_staticlib: $(LIBRARY)
79- $(INSTALL) $(INSTALL_DIR_OPTS) -d $(libdir)
80- $(INSTALL) $(INSTALL_OPTS_LIB) $(LIBRARY) $(libdir)
81-
82-install_sharedlib: $(LIBRARY_SO)
83- $(INSTALL) $(INSTALL_OPTS_LIB) $(LIBRARY_SO_VER) $(libdir)
84- ln -s $(LIBRARY_SO_VER) $(libdir)/$(LIBRARY_SO)
5eef6fa9
JB
85+install_lib: $(LIBRARY)
86+ $(INSTALL) $(INSTALL_DIR_OPTS) -d $(DESTDIR)$(libdir)
36bcfddd
JB
87+ $(LIBTOOL) --mode=install $(INSTALL) $(INSTALL_OPTS_LIB) $(LIBRARY) $(DESTDIR)$(libdir)
88
5eef6fa9
JB
89
90 ifneq ($(wildcard .depend),)
This page took 0.040718 seconds and 4 git commands to generate.