Annotation of /tags/init-0_6_0/Makefile
Parent Directory
|
Revision Log
Revision 1260 -
(hide annotations)
(download)
Fri Mar 11 17:38:17 2011 UTC (13 years, 3 months ago) by niro
Original Path: trunk/magellan-initscripts/Makefile
File size: 3139 byte(s)
Fri Mar 11 17:38:17 2011 UTC (13 years, 3 months ago) by niro
Original Path: trunk/magellan-initscripts/Makefile
File size: 3139 byte(s)
-split rc.config into several conf.d config files
1 | niro | 362 | # Magellan Initscripts |
2 | niro | 933 | # $Id$ |
3 | niro | 362 | |
4 | CC=gcc | ||
5 | CFLAGS=-Os -Wall | ||
6 | LDFLAGS=-s | ||
7 | |||
8 | DESTDIR= | ||
9 | |||
10 | sysconfdir=/etc | ||
11 | libdir=/lib | ||
12 | sbindir=/sbin | ||
13 | rcdir=$(sysconfdir)/rc.d | ||
14 | initdir=$(rcdir)/init.d | ||
15 | |||
16 | all: start-stop-daemon | ||
17 | |||
18 | start-stop-daemon: src/start-stop-daemon.o | ||
19 | $(CC) $(CFLAGS) -o start-stop-daemon src/start-stop-daemon.o $(LDFLAGS) | ||
20 | |||
21 | src/start-stop-daemon.o: src/start-stop-daemon.c src/headers.h | ||
22 | |||
23 | clean: | ||
24 | rm -f src/*.o | ||
25 | if [ -f start-stop-daemon ]; then rm start-stop-daemon; fi | ||
26 | |||
27 | create-dirs: | ||
28 | install -d -m 0755 $(DESTDIR)$(sysconfdir) | ||
29 | install -d -m 0755 $(DESTDIR)$(sysconfdir)/conf.d | ||
30 | install -d -m 0755 $(DESTDIR)$(sysconfdir)/modules.d | ||
31 | install -d -m 0755 $(DESTDIR)$(rcdir)/rc0.d | ||
32 | install -d -m 0755 $(DESTDIR)$(rcdir)/rc1.d | ||
33 | install -d -m 0755 $(DESTDIR)$(rcdir)/rc2.d | ||
34 | install -d -m 0755 $(DESTDIR)$(rcdir)/rc3.d | ||
35 | install -d -m 0755 $(DESTDIR)$(rcdir)/rc4.d | ||
36 | install -d -m 0755 $(DESTDIR)$(rcdir)/rc5.d | ||
37 | install -d -m 0755 $(DESTDIR)$(rcdir)/rc6.d | ||
38 | install -d -m 0755 $(DESTDIR)$(rcdir)/rcsysinit.d | ||
39 | install -d -m 0755 $(DESTDIR)$(initdir) | ||
40 | niro | 694 | install -d -m 0755 $(DESTDIR)$(libdir)/udev/state |
41 | niro | 362 | install -d -m 0755 $(DESTDIR)$(sbindir) |
42 | |||
43 | install-etc: | ||
44 | for file in DIR_COLORS \ | ||
45 | fstab \ | ||
46 | group \ | ||
47 | hostname \ | ||
48 | hosts \ | ||
49 | inittab \ | ||
50 | inputrc \ | ||
51 | issue \ | ||
52 | passwd \ | ||
53 | profile \ | ||
54 | protocols \ | ||
55 | services \ | ||
56 | niro | 454 | shells \ |
57 | sysctl.conf; \ | ||
58 | niro | 362 | do \ |
59 | install -m 0644 etc/$${file} $(DESTDIR)$(sysconfdir); \ | ||
60 | done | ||
61 | echo "$$(date +%Y%m%d)-cvs" > $(DESTDIR)$(sysconfdir)/mageversion | ||
62 | |||
63 | install-confd: | ||
64 | niro | 1260 | install -m 0644 etc/conf.d/clock $(DESTDIR)$(sysconfdir)/conf.d |
65 | install -m 0644 etc/conf.d/consolefont $(DESTDIR)$(sysconfdir)/conf.d | ||
66 | install -m 0644 etc/conf.d/editor $(DESTDIR)$(sysconfdir)/conf.d | ||
67 | niro | 362 | install -m 0644 etc/conf.d/kernel $(DESTDIR)$(sysconfdir)/conf.d |
68 | niro | 1260 | install -m 0644 etc/conf.d/keymap $(DESTDIR)$(sysconfdir)/conf.d |
69 | niro | 509 | install -m 0644 etc/conf.d/net.routes $(DESTDIR)$(sysconfdir)/conf.d |
70 | niro | 579 | install -m 0644 etc/conf.d/net.sample $(DESTDIR)$(sysconfdir)/conf.d |
71 | niro | 786 | install -m 0644 etc/conf.d/rc $(DESTDIR)$(sysconfdir)/conf.d |
72 | niro | 1260 | install -m 0644 etc/conf.d/xdm $(DESTDIR)$(sysconfdir)/conf.d |
73 | niro | 362 | |
74 | install-modulesd: | ||
75 | niro | 693 | install -m 0644 etc/modules.autoload $(DESTDIR)$(sysconfdir) |
76 | niro | 958 | install -m 0644 etc/modules.d/aliases.conf $(DESTDIR)$(sysconfdir)/modules.d |
77 | install -m 0644 etc/modules.d/i386.conf $(DESTDIR)$(sysconfdir)/modules.d | ||
78 | niro | 362 | |
79 | install-initd: | ||
80 | for script in checkfs \ | ||
81 | cleanfs \ | ||
82 | consolefont \ | ||
83 | functions \ | ||
84 | halt \ | ||
85 | loadkeys \ | ||
86 | localnet \ | ||
87 | modules \ | ||
88 | mountfs \ | ||
89 | network \ | ||
90 | rc \ | ||
91 | reboot \ | ||
92 | sendsignals \ | ||
93 | setclock \ | ||
94 | swap \ | ||
95 | niro | 367 | sysctl \ |
96 | niro | 1102 | template; \ |
97 | niro | 362 | do \ |
98 | install -m 0755 etc/rc.d/init.d/$${script} $(DESTDIR)$(initdir)/${script}; \ | ||
99 | done | ||
100 | |||
101 | |||
102 | install-udevd: | ||
103 | niro | 694 | install -m 0644 lib/udev-state/devices.tar.bz2 $(DESTDIR)$(libdir)/udev/state |
104 | niro | 362 | |
105 | install-bins: | ||
106 | install -m 0755 start-stop-daemon $(DESTDIR)$(sbindir) | ||
107 | install -m 0755 sbin/modules-update $(DESTDIR)$(sbindir) | ||
108 | install -m 0755 sbin/rc-config $(DESTDIR)$(sbindir) | ||
109 | |||
110 | niro | 365 | install-symlinks: |
111 | ln -snf rc.d/init.d $(DESTDIR)$(sysconfdir)/init.d | ||
112 | |||
113 | niro | 362 | install: create-dirs \ |
114 | install-etc \ | ||
115 | install-confd \ | ||
116 | install-modulesd \ | ||
117 | install-initd \ | ||
118 | install-udevd \ | ||
119 | niro | 365 | install-bins \ |
120 | install-symlinks | ||
121 | niro | 362 | |
122 | .PHONY: all install |