summaryrefslogtreecommitdiffstats
path: root/perl-install/Makefile
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>1999-07-15 14:58:15 +0000
committerPascal Rigaux <pixel@mandriva.com>1999-07-15 14:58:15 +0000
commite4fb0c6d7fbe0fc8f8659f0d39510aad4dc95999 (patch)
tree4b2d6c4b02fdfb534e1eaa2ffb44426cb0fc148b /perl-install/Makefile
parent39b51c96e54f880be2d2fb909f44118a6c209d7c (diff)
downloaddrakx-e4fb0c6d7fbe0fc8f8659f0d39510aad4dc95999.tar
drakx-e4fb0c6d7fbe0fc8f8659f0d39510aad4dc95999.tar.gz
drakx-e4fb0c6d7fbe0fc8f8659f0d39510aad4dc95999.tar.bz2
drakx-e4fb0c6d7fbe0fc8f8659f0d39510aad4dc95999.tar.xz
drakx-e4fb0c6d7fbe0fc8f8659f0d39510aad4dc95999.zip
*** empty log message ***
Diffstat (limited to 'perl-install/Makefile')
-rw-r--r--perl-install/Makefile40
1 files changed, 23 insertions, 17 deletions
diff --git a/perl-install/Makefile b/perl-install/Makefile
index d05997e96..220488b25 100644
--- a/perl-install/Makefile
+++ b/perl-install/Makefile
@@ -1,13 +1,13 @@
SO_FILES = c/blib/arch/auto/c/c.so
PMS = *.pm c/*.pm resize_fat/*.pm commands diskdrake
-DEST = /tmp/t
+DEST = /tmp/t/Mandrake/instimage
DESTREP4PMS = $(DEST)/usr/bin/perl-install
PERL = perl
LOCALFILES = $(PERL) mouseconfig fr.map
.PHONY: all tags install clean verify_c
-all: $(SO_FILES)
+all: $(SO_FILES) install1_hd
tags:
etags -o - $(PMS) | perl2etags > TAGS
@@ -21,10 +21,10 @@ tar: clean
cd .. ; tar cfy perl-install.tar.bz2 $(LOCALFILES:%=--exclude %) perl-install
tar-diskdrake: clean
- cd .. ; cp -af perl-install diskdrake
+ cd .. ; rm -rf diskdrake ; cp -af perl-install diskdrake
l=`perl2fcalls -uses -excludec diskdrake | sort | uniq | sed -e 's/::/\//' -e 's/^/diskdrake\//' -e 's/$$/.pm/'` ; \
- cd .. ; tar cfvy diskdrake.tar.bz2 diskdrake/diskdrake $$l
+ cd .. ; tar cfz diskdrake.tgz --exclude CVS diskdrake/c diskdrake/diskdrake* $$l
c/c.xs: c/c.xs.pm
rm -f $@
@@ -35,6 +35,9 @@ $(SO_FILES): c/c.xs
test -e c/Makefile || (cd c; perl Makefile.PL)
$(MAKE) -C c
+install1_hd: install1_hd.c
+ $(CC) -static -Wall -o $@ $<
+
test_pms: verify_c
perl2fcalls -excludec install2.pm
(for i in $(PMS); do perl -cw -I. -Ic -Ic/blib/arch $$i || exit 1 ; done)
@@ -64,20 +67,21 @@ install_pms: $(SO_FILES)
get_needed_files: $(SO_FILES)
# export PERL_INSTALL_TEST=1 ; strace -f -e trace=file -o '| grep -v "(No such file or directory)" | sed -e "s/[^\"]*\"//" -e "s/\".*//" | grep "^/" | grep -v -e "^/tmp" -e "^/home" -e "^/proc" -e "^/var" -e "^/dev" -e "^/etc" -e "^/usr/lib/rpm" > /tmp/list ' $(PERL) -d install2.pm < /dev/null
cp -f list /tmp/list
- for i in $(LOCALFILES) `cat /tmp/list` ; do \
+ for i in c/blib/arch/auto/c/c.so $(LOCALFILES) `cat /tmp/list` ; do \
ldd $$i 2>/dev/null | sed -e 's/.*=> //' -e 's/ .*//' | uniq | sort >> /tmp/list; \
done
install -d $(DEST)/lib
install -d $(DEST)/bin
install -d $(DEST)/usr/bin
+ install -d $(DEST)/usr/lib
install -s $(LOCALFILES) $(DEST)/usr/bin
for i in `cat /tmp/list`; do \
if (echo $$i | grep "lib/[^/]*\.so"); then \
install -s $$i $(DEST)/lib; \
else \
- d=`echo $(DEST)/$$i | sed -e 's/\/usr\/local\//\/usr\//' -e 's/\/sbin\//\/bin\//'`; \
+ d=`echo $(DEST)/$$i | sed 's/\/usr\/local\//\/usr\//'`; \
install -d `dirname $$d` && \
if (echo $$i | grep "\.pm"); then \
perl -pe '$$_ eq "__END__" and exit(0);' $$i > $$d; \
@@ -88,14 +92,13 @@ get_needed_files: $(SO_FILES)
fi; \
done
- ln -sf ../usr/bin/tr $(DEST)/bin/tr
- ln -sf sh $(DEST)/bin/bash
- ln -sf ash $(DEST)/bin/sh
- ln -sf ../../bin/sh $(DEST)/usr/bin/sh
- ln -sf ../../bin/mke2fs $(DEST)/usr/bin/mke2fs
+ mv -f $(DEST)/bin/* $(DEST)/sbin/* $(DEST)/usr/bin
+ rmdir $(DEST)/bin $(DEST)/sbin
+
+ ln -s ash $(DEST)/usr/bin/sh
- install -d $(DEST)/lib/fonts
- cp -a /usr/lib/X11/fonts/misc $(DEST)/lib/fonts
+ install -d $(DEST)/usr/X11R6/lib/X11/fonts/
+ cp -a /usr/X11R6/lib/X11/fonts/misc $(DEST)/usr/X11R6/lib/X11/fonts/
echo -e "#!/usr/bin/perl\n\nsymlink '/tmp/rhimage/usr/lib/perl5', '/usr/lib/perl5';\nexec '/usr/bin/sh'" > $(DEST)/usr/bin/runinstall2
chmod a+x $(DEST)/usr/bin/runinstall2
@@ -108,15 +111,14 @@ as_root:
chmod a+w /mnt/initrd
full_stage2:
- rm -rf $(DEST)/[^M]*
- rm -f $(DEST)/Mandrake/instimage ; ln -s .. $(DEST)/Mandrake/instimage
- @#mkdir -p $(DEST)/Mandrake/base
- @#ln -s .. $(DEST)/Mandrake/instimage
+ rm -rf $(DEST)
+ mkdir $(DEST)
$(MAKE) get_needed_files
$(MAKE) stage2
stage2:
$(MAKE) install_pms
+ cd $(DEST) ; tar cfz $(DEST).tgz [^M]* ; mv $(DEST).tgz /tmp/t.tgz
@#rm -rf /mnt/initrd/*
@#cp -a $(DEST)/* /mnt/initrd
@@ -125,3 +127,7 @@ stage2:
# function f() { grep "$*" /usr/include/*.h /usr/include/*/*.h; }
+
+# dd if=/dev/zero of=/tmp/initrd bs=1k count=2000 ; echo y | mke2fs /tmp/initrd ; mount /tmp/initrd /mnt/disk/ -o loop ; cp -a /tmp/disk/* /mnt/disk/ ; umount /mnt/disk ; gzip -c /tmp/initrd > /tmp/initrd.img ; mcopy -o /tmp/initrd.img a:
+# mount /tmp/initrd /mnt/disk/ -o loop ; ; umount /mnt/disk ; gzip -c /tmp/initrd > /tmp/initrd.img ; mcopy -o /tmp/initrd.img a:
+