aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile8
-rw-r--r--initscripts.spec4
-rw-r--r--src/Makefile20
3 files changed, 18 insertions, 14 deletions
diff --git a/Makefile b/Makefile
index c46717f5..1e673e8e 100644
--- a/Makefile
+++ b/Makefile
@@ -3,11 +3,13 @@ ROOT=/
VERSION=$(shell awk '/Version:/ { print $$2 }' initscripts.spec)
CVSTAG = r$(subst .,-,$(VERSION))
+mandir=/usr/share/man
+
all:
(cd src; make)
install:
mkdir -p $(ROOT)/etc/profile.d $(ROOT)/sbin $(ROOT)/usr/sbin
- mkdir -p $(ROOT)/usr/man/man8
+ mkdir -p $(ROOT)$(mandir)/man8
install -m644 inittab $(ROOT)/etc
install -m644 adjtime $(ROOT)/etc
install -m755 setsysfont $(ROOT)/sbin
@@ -15,7 +17,7 @@ install:
install -m755 lang.csh $(ROOT)/etc/profile.d
install -m755 service $(ROOT)/sbin
install -m755 sys-unconfig $(ROOT)/usr/sbin
- install -m644 sys-unconfig.8 $(ROOT)/usr/man/man8
+ install -m644 sys-unconfig.8 $(ROOT)$(mandir)/man8
( if uname -m | grep -q sparc ; then \
install -m644 sysctl.conf.sparc $(ROOT)/etc/sysctl.conf ; \
else \
@@ -33,7 +35,7 @@ install:
(cd $(ROOT)/etc/sysconfig/network-scripts; \
ln -sf ../../../sbin/ifup . ; \
ln -sf ../../../sbin/ifdown . )
- (cd src; make install ROOT=$(ROOT))
+ (cd src; make install ROOT=$(ROOT) mandir=$(mandir))
mkdir -p /var/run/netreport
chown root.root /var/run/netreport
chmod og=rwx,o=rx /var/run/netreport
diff --git a/initscripts.spec b/initscripts.spec
index 7556bb50..a4799221 100644
--- a/initscripts.spec
+++ b/initscripts.spec
@@ -34,7 +34,7 @@ make
%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/etc
-make ROOT=$RPM_BUILD_ROOT install
+make ROOT=$RPM_BUILD_ROOT mandir=$RPM_BUILD_ROOT/%{_mandir} install
mkdir -p $RPM_BUILD_ROOT/var/run/netreport
#chown root.root $RPM_BUILD_ROOT/var/run/netreport
chmod u=rwx,g=rwx,o=rx $RPM_BUILD_ROOT/var/run/netreport
@@ -206,7 +206,7 @@ rm -rf $RPM_BUILD_ROOT
/sbin/minilogd
/sbin/service
/sbin/ppp-watch
-/usr/man/man*/*
+%{_mandir}/man*/*
%dir %attr(775,root,root) /var/run/netreport
%config /etc/ppp/ip-up
%config /etc/ppp/ip-down
diff --git a/src/Makefile b/src/Makefile
index 987609ea..654483e0 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -6,13 +6,15 @@ PPPWATCH_OBJS=ppp-watch.o shvar.o
INITLOG_OBJS=initlog.o process.o
USLEEP_OBJS=usleep.o
+mandir=/usr/share/man
+
all: $(PROGS)
clean:
rm -f $(PROGS) *.o
install:
- mkdir -p $(ROOT)/bin $(ROOT)/usr/sbin $(ROOT)/usr/man/man{1,8} $(ROOT)/etc
+ mkdir -p $(ROOT)/bin $(ROOT)/usr/sbin $(ROOT)$(mandir)/man{1,8} $(ROOT)/etc
install -s -m 755 doexec $(ROOT)/bin/doexec
install -s -m 755 usleep $(ROOT)/bin/usleep
install -s -m 4755 usernetctl $(ROOT)/usr/sbin/usernetctl
@@ -23,14 +25,14 @@ install:
install -s -m 755 getkey $(ROOT)/sbin/getkey
install -s -m 755 ppp-watch $(ROOT)/sbin/ppp-watch
install -s -m 755 consoletype $(ROOT)/sbin/consoletype
- install -m 644 initlog.1 $(ROOT)/usr/man/man1
- install -m 644 doexec.1 $(ROOT)/usr/man/man1
- install -m 644 netreport.1 $(ROOT)/usr/man/man1
- install -m 644 usleep.1 $(ROOT)/usr/man/man1
- install -m 644 usernetctl.8 $(ROOT)/usr/man/man8
- install -m 644 ppp-watch.8 $(ROOT)/usr/man/man8
- install -m 644 ipcalc.1 $(ROOT)/usr/man/man1
- install -m 644 consoletype.1 $(ROOT)/usr/man/man1
+ install -m 644 initlog.1 $(ROOT)$(mandir)/man1
+ install -m 644 doexec.1 $(ROOT)$(mandir)/man1
+ install -m 644 netreport.1 $(ROOT)$(mandir)/man1
+ install -m 644 usleep.1 $(ROOT)$(mandir)/man1
+ install -m 644 usernetctl.8 $(ROOT)$(mandir)/man8
+ install -m 644 ppp-watch.8 $(ROOT)$(mandir)/man8
+ install -m 644 ipcalc.1 $(ROOT)$(mandir)/man1
+ install -m 644 consoletype.1 $(ROOT)$(mandir)/man1
install -m 644 initlog.conf $(ROOT)/etc
# this daemon and initscript are useful for testing the up/down/status stuff