toolchain modoifications
[hdw-linux/hdw-linux.git] / packages / base / 00-small-base-conf / 00-small-base-conf
1 # hdw - linux 00-small-base-conf package
2 #
3 # author: hackbard@hackdaworld.dyndns.org
4 #
5 # we don't need source
6 # [S] 1-10 2-1
7 # [V] 0.1
8
9 custmain="1"
10
11 if [ "$hdw_status" = "1" ] ; then
12         custmain()      {
13                 for i in bash pwd cat stty; do
14                         ln -sf ../$tc_name/bin/$i $root/bin/$i
15                 done
16                 ln -sf bash $root/bin/sh
17                 ln -sf ../../$tc_name/bin/perl $root/usr/bin/perl
18                         }
19 else
20         custmain()      {
21                 # changing ownership!
22                 chown -R 0:0 $root/[!p]*
23         
24                 # passwd & group file
25                 cp -v ${hdw_home_dir}/misc/sysfiles/etc/passwd $root/etc
26                 cp -v ${hdw_home_dir}/misc/sysfiles/etc/group $root/etc
27                 cp -v ${hdw_home_dir}/misc/sysfiles/etc/shadow $root/etc
28                 chmod 644 $root/etc/{passwd,group}
29                 chmod 640 $root/etc/shadow && chown 0:0 $root/etc/shadow
30         
31                 # we want mtab to be up2date
32                 ln -fs /proc/mounts $root/etc/mtab
33
34                 # arbitary timezone needed for some packages to build properly
35                 ln -sfv ../usr/share/zoneinfo/Europe/Berlin $root/etc/localtime
36                         }
37 fi