summaryrefslogtreecommitdiff
path: root/libraries/lrmi/Makefile.diff
blob: d11257faec521ae32d2e6a172c91de7476fc857d (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
--- Makefile.orig	2005-12-05 00:33:57.000000000 +0100
+++ lrmi-0.10/Makefile	2008-07-14 15:16:41.206752922 +0200
@@ -1,7 +1,7 @@
-LIBDIR ?= /usr/local/lib
-INCDIR ?= /usr/local/include
+LIBDIR ?= /usr/lib
+INCDIR ?= /usr/include
 
-CFLAGS = -g -Wall
+CFLAGS += -g -Wall
 
 sources = lrmi.c
 objects = lrmi.o
@@ -30,17 +30,16 @@
 	ln -sf $(LIBNAME).so.$(VERSION) $(LIBNAME).so.$(MAJOR)
 	ln -sf $(LIBNAME).so.$(MAJOR) $(LIBNAME).so
 
-vbetest: vbetest.c liblrmi.a
+vbetest: vbetest.c liblrmi.so
 	$(CC) $(CPPFLAGS) $(CFLAGS) -o $@ $^
 
 install:
-	mkdir -p $(LIBDIR)
-	install -m 755 -s -p $(LIBNAME).so.$(VERSION) $(LIBDIR)/$(LIBNAME).so.$(VERSION)
-	rm -f $(LIBDIR)/$(LIBNAME).so
-	ln -sf $(LIBNAME).so.$(VERSION) $(LIBDIR)/$(LIBNAME).so.$(MAJOR)
-	ln -sf $(LIBNAME).so.$(MAJOR) $(LIBDIR)/$(LIBNAME).so
-	install -m 644 -s -p lrmi.h $(INCDIR)/lrmi.h
-	ldconfig
+	mkdir -p $(DESTDIR)$(LIBDIR) $(DESTDIR)$(INCDIR)
+	install -m 755 -s -p $(LIBNAME).so.$(VERSION) $(DESTDIR)$(LIBDIR)/$(LIBNAME).so.$(VERSION)
+	rm -f $(DESTDIR)$(LIBDIR)/$(LIBNAME).so
+	ln -sf $(LIBNAME).so.$(VERSION) $(DESTDIR)$(LIBDIR)/$(LIBNAME).so.$(MAJOR)
+	ln -sf $(LIBNAME).so.$(MAJOR) $(DESTDIR)$(LIBDIR)/$(LIBNAME).so
+	install -m 644 -p lrmi.h $(DESTDIR)$(INCDIR)/lrmi.h
 
 .PHONY: clean
 clean: