Subversion Repository

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3 - (hide annotations)
Sun Oct 4 17:28:47 2009 UTC (3 years, 7 months ago) by cjg
File size: 16078 byte(s)
jumping to linux-2.6.26.5
1 cjg 2 #
2     # Makefile for CRUX PPC, based on Makefile for CRUX
3     # Copyright (c) 2003-2004 Per Liden <per@fukt.bth.se>
4     # Copyright (c) 2004 Giulivo Navigante <giulivo@linuxmail.org>
5     # Copyright (c) 2005-2008 The CRUX PPC Team - http://cruxppc.sunsite.dk
6     #
7     # $Id: 14/01/2008 05:02:13 acrux *0.10* $
8     # CRUX PPC 2.4
9     # release codename is: _Mafarka _le _futuriste
10     #
11    
12     COLLECTIONS = core opt xorg
13     KERNEL_MIRROR = ftp://ftp.eu.kernel.org
14 cjg 3 KERNEL_VERSION = 2.6.26.5
15 cjg 2 KERNEL_PATCHES = cruxppc-logo.diff
16     FAKE_ROOT_DIR = $(PWD)/tmp/fake_root
17     ISO_ROOT_DIR = $(PWD)/tmp/iso_root
18     ISO_FILENAME = $(PWD)/crux-ppc-2.4rc2.iso
19     ISO_PACKAGES = filesystem bash coreutils bzip2 e2fsprogs jfsutils xfsprogs \
20     reiserfsprogs patch findutils glibc grep gzip kbd module-init-tools \
21     less yaboot gawk ncurses net-tools pkgutils procps readline sed shadow \
22     mktemp sysklogd sysvinit tar util-linux-ng vim which dialog nano mdadm \
23     parted mac-fdisk hfsutils nvsetenv yaboot glib mc \
24     pciutils libusb usbutils hotplug sysfsutils udev iproute2 memtester zlib
25    
26     PORTS_core = $(shell /bin/ls -I README ports/core)
27     PORTS_opt = yaboot run-parts pbbuttonsd parted nvsetenv ncftp memtester mac-fdisk \
28     rp-pppoe elinks eject b43-fwcutter nano dialog mdadm wireless-tools \
29     libpng glib mc glitz libjpeg hicolor-icon-theme atk wpa_supplicant \
30     freetype cairo libtiff fontconfig pango gtk libidl firefox \
31     cdrtools sudo imlib2 fluxbox fetchmail procmail \
32     libxml2 libxslt libdrm mutt xterm p5-xml-parser \
33     python sqlite3 nspr dbus nss dbus-glib xulrunner parthenope
34     PORTS_xorg = $(shell /bin/ls -I README ports/xorg)
35    
36     ifeq ($(FORCE),yes)
37     PKGMK_FORCE=-f
38     else
39     PKGMK_FORCE=
40     endif
41    
42     .PHONY: help check-root check-log $(COLLECTIONS) all all-chroot bootstrap kernel kernel-clean clean iso
43    
44     help:
45     @echo "CRUX PPC Makefile"
46     @echo "Targets:"
47     @echo " <collection> build single collection"
48     @echo " all build all collections"
49     @echo " bootstrap bootstrap all collections"
50     @echo " kernel download and build kernel"
51     @echo " iso create iso image"
52     @echo "Collections:"
53     @echo " $(COLLECTIONS)"
54    
55     check-root:
56     @if [ "$$UID" != "0" ]; then \
57     echo "You need to be root to do this."; \
58     exit 1; \
59     fi
60    
61     check-log:
62     @grep "^=======> ERROR:"; \
63     if [ "$$?" = "0" ]; then \
64     echo "(see log file for details)"; \
65     exit 1; \
66     else \
67     exit 0; \
68     fi
69    
70     kernel/linux-$(KERNEL_VERSION).tar.bz2:
71     cd kernel && wget --passive-ftp $(KERNEL_MIRROR)/pub/linux/kernel/v2.6/linux-$(KERNEL_VERSION).tar.bz2
72    
73     kernel/linux-$(KERNEL_VERSION): kernel/linux-$(KERNEL_VERSION).tar.bz2
74     tar -C kernel -xjmf kernel/linux-$(KERNEL_VERSION).tar.bz2
75     for FILE in $(KERNEL_PATCHES); do \
76     cd kernel/linux-$(KERNEL_VERSION) && patch -p1 < ../$$FILE && cd ../..; \
77     done
78     cp -a kernel/linux-$(KERNEL_VERSION) kernel/linux-$(KERNEL_VERSION)-64bit
79     cp -a kernel/linux-$(KERNEL_VERSION) kernel/linux-$(KERNEL_VERSION)-Sam440ep
80     patch -p1 -d kernel/linux-$(KERNEL_VERSION)-Sam440ep < kernel/linux-$(KERNEL_VERSION)-Sam440ep.patch
81     cp -a kernel/linux-$(KERNEL_VERSION) kernel/linux-$(KERNEL_VERSION)-Efika
82     cp -a kernel/linux-$(KERNEL_VERSION) kernel/linux-$(KERNEL_VERSION)-Pegasos2
83     #cp -a kernel/linux-$(KERNEL_VERSION) kernel/linux-$(KERNEL_VERSION)-Chrp32
84     #cp -a kernel/linux-$(KERNEL_VERSION) kernel/linux-$(KERNEL_VERSION)-Apple64
85     #cp -a kernel/linux-$(KERNEL_VERSION) kernel/linux-$(KERNEL_VERSION)-pSeries
86    
87     kernel/linux-$(KERNEL_VERSION)/vmlinux: kernel/linux-$(KERNEL_VERSION)
88     make -C kernel/linux-$(KERNEL_VERSION) mrproper
89     cp -f kernel/linux-$(KERNEL_VERSION).config kernel/linux-$(KERNEL_VERSION)/.config
90     make -C kernel/linux-$(KERNEL_VERSION) oldconfig
91     make -j16 -C kernel/linux-$(KERNEL_VERSION) all
92     touch kernel/linux-$(KERNEL_VERSION)/arch/powerpc/boot/zImage.pmac
93    
94     CC="gcc -m64" make -C kernel/linux-$(KERNEL_VERSION)-64bit mrproper
95     cp -f kernel/linux-$(KERNEL_VERSION)-64bit.config kernel/linux-$(KERNEL_VERSION)-64bit/.config
96     CC="gcc -m64" make -C kernel/linux-$(KERNEL_VERSION)-64bit oldconfig
97     CC="gcc -m64" make -j16 -C kernel/linux-$(KERNEL_VERSION)-64bit all
98     touch kernel/linux-$(KERNEL_VERSION)-64bit/vmlinux
99    
100     make -C kernel/linux-$(KERNEL_VERSION)-Sam440ep mrproper
101     cp -f kernel/linux-$(KERNEL_VERSION)-Sam440ep.config kernel/linux-$(KERNEL_VERSION)-Sam440ep/.config
102     make -C kernel/linux-$(KERNEL_VERSION)-Sam440ep oldconfig
103     make -j16 -C kernel/linux-$(KERNEL_VERSION)-Sam440ep all
104     touch kernel/linux-$(KERNEL_VERSION)-Sam440ep/vmlinux
105    
106     make -C kernel/linux-$(KERNEL_VERSION)-Efika mrproper
107     cp -f kernel/linux-$(KERNEL_VERSION)-Efika.config kernel/linux-$(KERNEL_VERSION)-Efika/.config
108     make -C kernel/linux-$(KERNEL_VERSION)-Efika oldconfig
109     make -j16 -C kernel/linux-$(KERNEL_VERSION)-Efika all
110     touch kernel/linux-$(KERNEL_VERSION)-Efika/arch/powerpc/boot/zImage.chrp
111     make -C kernel/linux-$(KERNEL_VERSION)-Pegasos2 mrproper
112     cp -f kernel/linux-$(KERNEL_VERSION)-Pegasos2.config kernel/linux-$(KERNEL_VERSION)-Pegasos2/.config
113     make -C kernel/linux-$(KERNEL_VERSION)-Pegasos2 oldconfig
114     make -j16 -C kernel/linux-$(KERNEL_VERSION)-Pegasos2 all
115     touch kernel/linux-$(KERNEL_VERSION)-Pegasos2/arch/powerpc/boot/zImage.chrp
116    
117     #make -C kernel/linux-$(KERNEL_VERSION)-Chrp32 mrproper
118     #cp -f kernel/linux-$(KERNEL_VERSION)-Chrp32.config kernel/linux-$(KERNEL_VERSION)-Chrp32/.config
119     #make -C kernel/linux-$(KERNEL_VERSION)-Chrp32 oldconfig
120     #make -C kernel/linux-$(KERNEL_VERSION)-Chrp32 all
121     #touch kernel/linux-$(KERNEL_VERSION)-Chrp32/vmlinux
122    
123     #PATH=$(PATH):/usr/ppc64-unknown-linux-gnu/bin/ make -C kernel/linux-$(KERNEL_VERSION)-Apple64 mrproper ARCH=powerpc CROSS_COMPILE=ppc64-unknown-linux-gnu-
124     #cp -f kernel/linux-$(KERNEL_VERSION)-Apple64.config kernel/linux-$(KERNEL_VERSION)-Apple64/.config
125     #PATH=$(PATH):/usr/ppc64-unknown-linux-gnu/bin/ make -C kernel/linux-$(KERNEL_VERSION)-Apple64 oldconfig ARCH=powerpc CROSS_COMPILE=ppc64-unknown-linux-gnu-
126     #PATH=$(PATH):/usr/ppc64-unknown-linux-gnu/bin/ make -C kernel/linux-$(KERNEL_VERSION)-Apple64 all ARCH=powerpc CROSS_COMPILE=ppc64-unknown-linux-gnu-
127     #touch kernel/linux-$(KERNEL_VERSION)-Apple64/vmlinux
128    
129     #PATH=$(PATH):/usr/ppc64-unknown-linux-gnu/bin/ make -C kernel/linux-$(KERNEL_VERSION)-pSeries mrproper ARCH=powerpc CROSS_COMPILE=ppc64-unknown-linux-gnu-
130     #cp -f kernel/linux-$(KERNEL_VERSION)-pSeries.config kernel/linux-$(KERNEL_VERSION)-pSeries/.config
131     #PATH=$(PATH):/usr/ppc64-unknown-linux-gnu/bin/ make -C kernel/linux-$(KERNEL_VERSION)-pSeries oldconfig ARCH=powerpc CROSS_COMPILE=ppc64-unknown-linux-gnu-
132     #PATH=$(PATH):/usr/ppc64-unknown-linux-gnu/bin/ make -C kernel/linux-$(KERNEL_VERSION)-pSeries all ARCH=powerpc CROSS_COMPILE=ppc64-unknown-linux-gnu-
133     #touch kernel/linux-$(KERNEL_VERSION)-pSeries/vmlinux
134    
135     kernel: kernel/linux-$(KERNEL_VERSION)/vmlinux
136    
137     kernel-clean:
138     if [ -e kernel/linux-$(KERNEL_VERSION) ]; then rm -rf kernel/linux-$(KERNEL_VERSION); fi
139     if [ -e kernel/linux-$(KERNEL_VERSION)-64bit ]; then rm -rf kernel/linux-$(KERNEL_VERSION)-64bit; fi
140     if [ -e kernel/linux-$(KERNEL_VERSION)-Sam440ep ]; then rm -rf kernel/linux-$(KERNEL_VERSION)-Sam440ep; fi
141     if [ -e kernel/linux-$(KERNEL_VERSION)-Efika ]; then rm -rf kernel/linux-$(KERNEL_VERSION)-Efika; fi
142     if [ -e kernel/linux-$(KERNEL_VERSION)-Pegasos2 ]; then rm -rf kernel/linux-$(KERNEL_VERSION)-Pegasos2; fi
143     #if [ -e kernel/linux-$(KERNEL_VERSION)-Apple64 ]; then rm -rf kernel/linux-$(KERNEL_VERSION)-Apple64; fi
144     #if [ -e kernel/linux-$(KERNEL_VERSION)-Chrp32 ]; then rm -rf kernel/linux-$(KERNEL_VERSION)-Chrp32; fi
145     #if [ -e kernel/linux-$(KERNEL_VERSION)-pSeries ]; then rm -rf kernel/linux-$(KERNEL_VERSION)-pSeries; fi
146    
147     clean: kernel-clean
148    
149     $(COLLECTIONS): check-root
150     @for p in $(PORTS_$(@)); do \
151     echo "p: $$p"; \
152     (cd ports/$@/$$p && if [ -e pre-install ]; then sh pre-install; fi; pkgmk -d $(PKGMK_FORCE)); \
153     done
154    
155     all: $(COLLECTIONS)
156    
157     all-chroot: check-root
158     @echo "Creating chroot environment"
159     @if [ -e $(FAKE_ROOT_DIR) ]; then \
160     umount $(FAKE_ROOT_DIR)/src; \
161     umount $(FAKE_ROOT_DIR)/proc; \
162     umount $(FAKE_ROOT_DIR)/dev; \
163     rm -rf $(FAKE_ROOT_DIR); \
164     fi
165     @mkdir -p $(FAKE_ROOT_DIR)
166     @echo "Installing packages"
167     @mkdir -p $(FAKE_ROOT_DIR)/var/lib/pkg
168     @touch $(FAKE_ROOT_DIR)/var/lib/pkg/db
169     @for COLL in $(COLLECTIONS); do \
170     for PACKAGE in ports/$$COLL/*/*.pkg.tar.gz; do \
171     echo " $$PACKAGE"; \
172     pkgadd -r $(FAKE_ROOT_DIR) $$PACKAGE; \
173     done; \
174     done
175     @echo "Mounting /dev on $(FAKE_ROOT_DIR)/dev"
176     @mount --bind /dev $(FAKE_ROOT_DIR)/dev
177     @echo "Mounting /proc on $(FAKE_ROOT_DIR)/proc"
178     @mount --bind /proc $(FAKE_ROOT_DIR)/proc
179     @echo "Mouting $$PWD on $(FAKE_ROOT_DIR)/src"
180     @mkdir $(FAKE_ROOT_DIR)/src
181     @mount --bind $$PWD $(FAKE_ROOT_DIR)/src
182     @cp /etc/pkgmk.conf $(FAKE_ROOT_DIR)/etc
183     @echo "Entering chroot enrivonment"
184     @chroot $(FAKE_ROOT_DIR) /bin/bash --login -c "cd /src && $(MAKE) FORCE=yes all"
185     @echo "Exiting chroot enrivonment"
186     @echo "Unmounting $(FAKE_ROOT_DIR)/src"
187     @umount $(FAKE_ROOT_DIR)/src
188     @rmdir $(FAKE_ROOT_DIR)/src
189     @echo "Unmounting $(FAKE_ROOT_DIR)/proc"
190     @umount $(FAKE_ROOT_DIR)/proc
191     @echo "Unmounting $(FAKE_ROOT_DIR)/dev"
192     @umount $(FAKE_ROOT_DIR)/dev
193     @echo "Removing chroot environment"
194     @rm -rf $(FAKE_ROOT_DIR)
195    
196     bootstrap: check-root
197     @echo "Bootstrap started (`date +'%F %T'`)"
198     @echo "- Stage 0 (`date +'%F %T'`)"
199     @$(MAKE) all &> log.stage0
200     @$(MAKE) check-log < log.stage0
201     @echo "- Stage 1 (`date +'%F %T'`)"
202     @$(MAKE) all-chroot1 &> log.stage1
203     @$(MAKE) check-log < log.stage1
204     @echo "- Stage 2 (`date +'%F %T'`)"
205     @$(MAKE) all-chroot &> log.stage2
206     @$(MAKE) check-log < log.stage2
207     @echo "Bootstrap completed (`date +'%F %T'`)"
208    
209     iso: check-root
210     #kernel
211     @echo "Creating ISO image ($(ISO_FILENAME))"
212     @if [ -e $(ISO_ROOT_DIR) ]; then rm -rf $(ISO_ROOT_DIR); fi
213     @mkdir -p $(ISO_ROOT_DIR)
214     @echo "- Installing packages"
215     @for PACKAGE in $(ISO_PACKAGES); do \
216     tar -C $(ISO_ROOT_DIR) -xzpf ports/*/$$PACKAGE/$$PACKAGE\#*.pkg.tar.gz; \
217     done
218     @echo "- Copying ISO specific files"
219     @mkdir -p $(ISO_ROOT_DIR)/etc $(ISO_ROOT_DIR)/ppc/{chrp,efika,mac,pegasos2,ppc32,ppc64,sam440ep}
220     @cp iso/ppc/bootinfo.txt $(ISO_ROOT_DIR)/ppc
221     @cp iso/ppc/chrp/yaboot $(ISO_ROOT_DIR)/ppc/chrp
222     @cp iso/ppc/mac/{ofboot.b,yaboot} $(ISO_ROOT_DIR)/ppc/mac
223     @cp iso/ppc/ppc32/yaboot.conf $(ISO_ROOT_DIR)/ppc/ppc32
224     @cp iso/ppc/ppc64/yaboot.conf $(ISO_ROOT_DIR)/ppc/ppc64
225     @cp iso/ppc/sam440ep/{Parthenope,menu.lst} $(ISO_ROOT_DIR)/ppc/sam440ep
226     @cp iso/ppc/sam440ep/menu.lst $(ISO_ROOT_DIR)
227     @cp iso/etc/{fstab,hosts,inittab,issue,motd,ld.so.conf,protocols,rc,rc.shutdown,rc.single,services,yaboot.conf} $(ISO_ROOT_DIR)/etc
228     @echo "- Installing kernel"
229     @cp kernel/linux-$(KERNEL_VERSION)/System.map $(ISO_ROOT_DIR)/ppc/ppc32
230     @cp kernel/linux-$(KERNEL_VERSION)/vmlinux $(ISO_ROOT_DIR)/ppc/ppc32
231     @cp kernel/linux-$(KERNEL_VERSION)-64bit/System.map $(ISO_ROOT_DIR)/ppc/ppc64
232     @cp kernel/linux-$(KERNEL_VERSION)-64bit/vmlinux $(ISO_ROOT_DIR)/ppc/ppc64
233     @cp kernel/linux-$(KERNEL_VERSION)-Sam440ep/System.map $(ISO_ROOT_DIR)/ppc/sam440ep
234     @cp kernel/linux-$(KERNEL_VERSION)-Sam440ep/arch/powerpc/boot/cuImage.sam440ep $(ISO_ROOT_DIR)/ppc/sam440ep/uImage
235     @cp kernel/linux-$(KERNEL_VERSION)-Efika/System.map $(ISO_ROOT_DIR)/ppc/efika
236     @cp kernel/linux-$(KERNEL_VERSION)-Efika/vmlinux $(ISO_ROOT_DIR)/ppc/efika
237     @cp kernel/linux-$(KERNEL_VERSION)-Pegasos2/System.map $(ISO_ROOT_DIR)/ppc/pegasos2
238     @cp kernel/linux-$(KERNEL_VERSION)-Pegasos2/vmlinux $(ISO_ROOT_DIR)/ppc/pegasos2
239     #@cp kernel/linux-$(KERNEL_VERSION)-Chrp32/System.map $(ISO_ROOT_DIR)/boot/System.map-Chrp32
240     #@cp kernel/linux-$(KERNEL_VERSION)-Chrp32/vmlinux $(ISO_ROOT_DIR)/boot/vmlinux-Chrp32
241     #@cp kernel/linux-$(KERNEL_VERSION)-Apple64/System.map $(ISO_ROOT_DIR)/boot/System.map-Apple64
242     #@cp kernel/linux-$(KERNEL_VERSION)-Apple64/vmlinux $(ISO_ROOT_DIR)/boot/vmlinux-Apple64
243     #@cp kernel/linux-$(KERNEL_VERSION)-pSeries/System.map $(ISO_ROOT_DIR)/boot/System.map-pSeries
244     #@cp kernel/linux-$(KERNEL_VERSION)-pSeries/vmlinux $(ISO_ROOT_DIR)/boot/vmlinux-pSeries
245     @echo "- Installing kernel modules (see modules_install.log)"
246     @make -C kernel/linux-$(KERNEL_VERSION) INSTALL_MOD_PATH=$(ISO_ROOT_DIR) modules_install &> modules_install.log
247     @make -C kernel/linux-$(KERNEL_VERSION)-64bit INSTALL_MOD_PATH=$(ISO_ROOT_DIR) modules_install &> modules_install.log-64bit
248     @make -C kernel/linux-$(KERNEL_VERSION)-Sam440ep INSTALL_MOD_PATH=$(ISO_ROOT_DIR) modules_install &> modules_install.log-Sam440ep
249     @make -C kernel/linux-$(KERNEL_VERSION)-Efika INSTALL_MOD_PATH=$(ISO_ROOT_DIR) modules_install &> modules_install.log-Efika
250     @make -C kernel/linux-$(KERNEL_VERSION)-Pegasos2 INSTALL_MOD_PATH=$(ISO_ROOT_DIR) modules_install &> modules_install.log-Pegasos2
251     #@make -C kernel/linux-$(KERNEL_VERSION)-Chrp32 INSTALL_MOD_PATH=$(ISO_ROOT_DIR) modules_install &> modules_install.log-Chrp32
252     #@make -C kernel/linux-$(KERNEL_VERSION)-pSeries INSTALL_MOD_PATH=$(ISO_ROOT_DIR) modules_install &> modules_install.log-pSeries
253     @echo "- Deleting superfluous files"
254     @cd $(ISO_ROOT_DIR) && rm -rf var opt home
255     @cd $(ISO_ROOT_DIR)/usr && rm -rf man include lib/*.a lib/*.o lib/gconv lib/locale src
256     @cd $(ISO_ROOT_DIR)/usr/share && mkdir l v; cp terminfo/l/linux l; cp terminfo/v/vt100 v; rm -rf terminfo/*; mv l v terminfo
257     @cd $(ISO_ROOT_DIR)/usr/share && rm -rf et ss vim i18n zoneinfo
258     @cd $(ISO_ROOT_DIR)/usr/bin && rm cal locale localedef rpcgen compile_et mk_cmds
259     @cd $(ISO_ROOT_DIR)/usr/sbin && rm group{add,del,mod} user{add,del,mod} grpck pwck iconvconfig rpcinfo zic zdump
260     @cd $(ISO_ROOT_DIR)/etc && rm -rf rc.d cron {resolv,yaboot,sysctl,pkgadd,pkgmk}.conf securetty
261     @cd $(ISO_ROOT_DIR)/usr/lib && rm -rf pkgconfig/*
262     @cd $(ISO_ROOT_DIR)/lib/modules/$(KERNEL_VERSION) && rm -f build
263     @echo "- Creating symlinks"
264     @ln -sf /tmp/var $(ISO_ROOT_DIR)/var
265     @ln -sf /proc/mounts $(ISO_ROOT_DIR)/etc/mtab
266     @echo "- Updating library links and cache"
267     @ldconfig -r $(ISO_ROOT_DIR)
268     @echo "- Copying CRUX PPC packages"
269     @mkdir -p $(ISO_ROOT_DIR)/crux
270     @cp doc/handbook/handbook.txt $(ISO_ROOT_DIR)/crux
271     @cp iso/setup.dependencies $(ISO_ROOT_DIR)/crux
272     @cp doc/gpl.txt $(ISO_ROOT_DIR)/crux
273     @cp iso/bin/{setup,setup-helper,setup-chroot,serial_console} $(ISO_ROOT_DIR)/usr/bin
274     @mkdir -p $(ISO_ROOT_DIR)/crux/kernel
275     @cp kernel/linux-$(KERNEL_VERSION).tar.bz2 $(ISO_ROOT_DIR)/crux/kernel
276     @cp kernel/linux-$(KERNEL_VERSION).config $(ISO_ROOT_DIR)/crux/kernel
277     @cp kernel/linux-$(KERNEL_VERSION)-64bit.config $(ISO_ROOT_DIR)/crux/kernel
278     @cp kernel/linux-$(KERNEL_VERSION)-Sam440ep.config $(ISO_ROOT_DIR)/crux/kernel
279     @cp kernel/linux-$(KERNEL_VERSION)-Efika.config $(ISO_ROOT_DIR)/crux/kernel
280     @cp kernel/linux-$(KERNEL_VERSION)-Pegasos2.config $(ISO_ROOT_DIR)/crux/kernel
281     #@cp kernel/linux-$(KERNEL_VERSION)-Chrp32.config $(ISO_ROOT_DIR)/crux/kernel
282     #@cp kernel/linux-$(KERNEL_VERSION)-pSeries.config $(ISO_ROOT_DIR)/crux/kernel
283     @for FILE in $(KERNEL_PATCHES); do \
284     cp kernel/$$FILE $(ISO_ROOT_DIR)/crux/kernel; \
285     done
286     @for COLL in $(COLLECTIONS); do \
287     mkdir -p $(ISO_ROOT_DIR)/crux/$$COLL; \
288     cp ports/$$COLL/*/*.pkg.tar.gz $(ISO_ROOT_DIR)/crux/$$COLL; \
289     (cd ports/$$COLL; \
290     for i in `find -name "pre-install"`; do \
291     cp $$i $(ISO_ROOT_DIR)/crux/$$COLL/`echo $$i | sed -e 's|\.\/||' -e 's|\/|\.|g'`; \
292     done; \
293     for i in `find -name "post-install"`; do \
294     cp $$i $(ISO_ROOT_DIR)/crux/$$COLL/`echo $$i | sed -e 's|\.\/||' -e 's|\/|\.|g'`; \
295     done; \
296     ); \
297     done
298     @echo "- Starting mkisofs"
299     @if [ -f $(ISO_FILENAME) ]; then rm -f $(ISO_FILENAME); fi
300     @mkisofs -r -V CRUX-PPC -U -chrp-boot -hfs -part -probe -no-desktop \
301     -hfs-bless $(ISO_ROOT_DIR)/ppc/mac -map iso/boot/map.hfs \
302     -b ppc/sam440ep/Parthenope -no-emul-boot \
303     -hide-rr-moved -o $(ISO_FILENAME) $(ISO_ROOT_DIR)
304     @rm -rf $(ISO_ROOT_DIR)
305     @md5sum $(ISO_FILENAME) > $(ISO_FILENAME).md5
306     @echo "Done"
307    
308     iso/setup.dependencies:
309     @for PORT in $(foreach c,$(COLLECTIONS),$(PORTS_$(c))); do \
310     echo -n $$PORT": "; \
311     prt-get quickdep $$PORT; \
312     done > $@
313    
314     # End of file