blob: 2b348b75f60de19c89192b6baaed6f79eb9ae777 (
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
|
--- logrotate-3.7.8.orig/Makefile 2008-05-19 12:25:54.000000000 +0200
+++ logrotate-3.7.8/Makefile 2010-02-06 00:00:58.853084930 +0100
@@ -1,7 +1,7 @@
VERSION = $(shell awk '/Version:/ { print $$2 }' logrotate.spec)
-OS_NAME = $(shell uname -s)
+OS_NAME = Linux
LFS = $(shell echo `getconf LFS_CFLAGS 2>/dev/null`)
-CFLAGS = -Wall -D_GNU_SOURCE -D$(OS_NAME) -DVERSION=\"$(VERSION)\" $(RPM_OPT_FLAGS) $(LFS)
+CFLAGS ?= -Wall -D_GNU_SOURCE -D$(OS_NAME) -DVERSION=\"$(VERSION)\" $(RPM_OPT_FLAGS) $(LFS)
PROG = logrotate
MAN = logrotate.8
LOADLIBES = -lpopt
@@ -96,16 +96,16 @@ test: $(TARGET)
(cd test; ./test)
install:
- [ -d $(PREFIX)/$(BINDIR) ] || mkdir -p $(PREFIX)/$(BINDIR)
- [ -d $(PREFIX)/$(MANDIR) ] || mkdir -p $(PREFIX)/$(MANDIR)
- [ -d $(PREFIX)/$(MANDIR)/man8 ] || mkdir -p $(PREFIX)/$(MANDIR)/man8
+ [ -d $(DESTDIR)/$(BINDIR) ] || mkdir -p $(DESTDIR)/$(BINDIR)
+ [ -d $(DESTDIR)/$(MANDIR) ] || mkdir -p $(DESTDIR)/$(MANDIR)
+ [ -d $(DESTDIR)/$(MANDIR)/man8 ] || mkdir -p $(DESTDIR)/$(MANDIR)/man8
if [ "$(OS_NAME)" = HP-UX ]; then \
- $(INSTALL) $(PROG) $(PREFIX)/$(BINDIR) 0755 bin bin; \
- $(INSTALL) $(MAN) $(PREFIX)/$(MANDIR)/man`echo $(MAN) | sed "s/.*\.//"` 0644 bin bin; \
+ $(INSTALL) $(PROG) $(DESTDIR)/$(BINDIR) 0755 bin bin; \
+ $(INSTALL) $(MAN) $(DESTDIR)/$(MANDIR)/man`echo $(MAN) | sed "s/.*\.//"` 0644 bin bin; \
else \
- $(INSTALL) -m 755 $(PROG) $(PREFIX)/$(BINDIR); \
- $(INSTALL) -m 644 $(MAN) $(PREFIX)/$(MANDIR)/man`echo $(MAN) | sed "s/.*\.//"`/$(MAN); \
+ $(INSTALL) -m 755 $(PROG) $(DESTDIR)/$(BINDIR); \
+ $(INSTALL) -m 644 $(MAN) $(DESTDIR)/$(MANDIR)/man`echo $(MAN) | sed "s/.*\.//"`/$(MAN); \
fi
co:
|