diff options
author | Waldemar Brodkorb <wbx@openadk.org> | 2014-06-21 07:41:41 +0200 |
---|---|---|
committer | Waldemar Brodkorb <wbx@openadk.org> | 2014-06-21 07:41:41 +0200 |
commit | 90f603e2be40d996c421ae8e95464e38911eabaf (patch) | |
tree | a3a8aa942a9acf078eed1333404de22aaa106219 /scripts | |
parent | f9292cf478867567f80ad270d4351e9a48ef4d06 (diff) |
s/TOPDIR/ADK_TOPDIR/
to avoid namespace collisions in some packages, rename TOPDIR.
Sorry you need to make cleandir && make prereq && make
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/create.sh | 12 | ||||
-rwxr-xr-x | scripts/install.sh | 12 | ||||
-rw-r--r-- | scripts/make-ipkg-dir.sh | 2 | ||||
-rwxr-xr-x | scripts/reloc.sh | 2 | ||||
-rw-r--r-- | scripts/scan-tools.sh | 6 | ||||
-rw-r--r-- | scripts/update-patches2 | 2 |
6 files changed, 18 insertions, 18 deletions
diff --git a/scripts/create.sh b/scripts/create.sh index f15fdc1bc..7422cbf4f 100755 --- a/scripts/create.sh +++ b/scripts/create.sh @@ -27,13 +27,13 @@ # Create a hard disc image, bootable using GNU GRUB2, with an ext2fs # root partition and an OpenADK cfgfs partition. -TOPDIR=$(pwd) +ADK_TOPDIR=$(pwd) HOST=$(gcc -dumpmachine) me=$0 case :$PATH: in -(*:$TOPDIR/host_$HOST/usr/bin:*) ;; -(*) export PATH=$PATH:$TOPDIR/host_$HOST/usr/bin ;; +(*:$ADK_TOPDIR/host_$HOST/usr/bin:*) ;; +(*) export PATH=$PATH:$ADK_TOPDIR/host_$HOST/usr/bin ;; esac test -n "$KSH_VERSION" || exec mksh "$me" "$@" @@ -46,7 +46,7 @@ fi me=${me##*/} -TOPDIR=$(realpath .) +ADK_TOPDIR=$(realpath .) ostype=$(uname -s) function usage { @@ -182,7 +182,7 @@ else print Preparing partition table... fi dd if=/dev/zero of="$T/firsttrack" count=$partofs 2>/dev/null -echo $corestartsec $coreendsec | mksh "$TOPDIR/scripts/bootgrub.mksh" \ +echo $corestartsec $coreendsec | mksh "$ADK_TOPDIR/scripts/bootgrub.mksh" \ -A -g $((cyls - cfgfs)):$heads:$secs -M 1:0x83 -O $partofs | \ dd of="$T/firsttrack" conv=notrunc 2>/dev/null if (( usegrub )); then @@ -325,6 +325,6 @@ case $tgttype { } print Finishing up... -cd "$TOPDIR" +cd "$ADK_TOPDIR" rm -rf "$T" exit 0 diff --git a/scripts/install.sh b/scripts/install.sh index ef9aae7e9..cbaf2f318 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -31,13 +31,13 @@ # just built there # • create a cfgfs partition -TOPDIR=$(pwd) +ADK_TOPDIR=$(pwd) HOST=$(gcc -dumpmachine) me=$0 case :$PATH: in -(*:$TOPDIR/host_$HOST/usr/bin:*) ;; -(*) export PATH=$PATH:$TOPDIR/host_$HOST/usr/bin ;; +(*:$ADK_TOPDIR/host_$HOST/usr/bin:*) ;; +(*) export PATH=$PATH:$ADK_TOPDIR/host_$HOST/usr/bin ;; esac test -n "$KSH_VERSION" || exec mksh "$me" "$@" @@ -55,7 +55,7 @@ if (( USER_ID )); then exit 1 fi -TOPDIR=$(realpath .) +ADK_TOPDIR=$(realpath .) ostype=$(uname -s) cfgfs=1 @@ -229,7 +229,7 @@ fi (( quiet )) || print Preparing MBR and GRUB2... dd if=/dev/zero of="$T/firsttrack" count=$partofs 2>/dev/null -echo $corestartsec $coreendsec | mksh "$TOPDIR/scripts/bootgrub.mksh" \ +echo $corestartsec $coreendsec | mksh "$ADK_TOPDIR/scripts/bootgrub.mksh" \ -A -g $((cyls-cfgfs)):$heads:$secs -M 1:0x83 -O $partofs | \ dd of="$T/firsttrack" conv=notrunc 2>/dev/null dd if="$T/core.img" of="$T/firsttrack" conv=notrunc seek=$corestartsec \ @@ -361,7 +361,7 @@ mkdir -p boot/grub print '}' ) >boot/grub/grub.cfg (( quiet )) || print Finishing up... -cd "$TOPDIR" +cd "$ADK_TOPDIR" umount "$T" (( quiet )) || print "\nNote: the rootfs UUID is: $partuuid" diff --git a/scripts/make-ipkg-dir.sh b/scripts/make-ipkg-dir.sh index 65eeb5621..0ace8cda5 100644 --- a/scripts/make-ipkg-dir.sh +++ b/scripts/make-ipkg-dir.sh @@ -13,7 +13,7 @@ grep '^Maintainer' "$CONTROL" 2>&1 >/dev/null || \ grep '^Priority' "$CONTROL" 2>&1 >/dev/null || \ echo "Priority: optional" >> "$TARGET/CONTROL/control" grep '^Source' "$CONTROL" 2>&1 >/dev/null || { - pkgbase=$(echo "$WD" | sed -e "s|^$TOPDIR/||g") + pkgbase=$(echo "$WD" | sed -e "s|^$ADK_TOPDIR/||g") [ "$pkgbase" = "$WD" ] && src="N/A" || src="$BASE" echo "Source: $src" >> "$TARGET/CONTROL/control" } diff --git a/scripts/reloc.sh b/scripts/reloc.sh index 03034ea35..b0b2ca94c 100755 --- a/scripts/reloc.sh +++ b/scripts/reloc.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash # execute this after relocation of adk directory -olddir=$(grep "^TOPDIR" prereq.mk 2>/dev/null |cut -d '=' -f 2) +olddir=$(grep "^ADK_TOPDIR" prereq.mk 2>/dev/null |cut -d '=' -f 2) newdir=$(pwd) if [ ! -z "$olddir" ];then diff --git a/scripts/scan-tools.sh b/scripts/scan-tools.sh index 0e4dff4be..21f884e3f 100644 --- a/scripts/scan-tools.sh +++ b/scripts/scan-tools.sh @@ -78,7 +78,7 @@ else fi cat >Makefile <<'EOF' -include ${TOPDIR}/prereq.mk +include ${ADK_TOPDIR}/prereq.mk all: run-test test: test.c @@ -96,7 +96,7 @@ cat >test.c <<-'EOF' return (0); } EOF -X=$($makecmd TOPDIR=$topdir 2>&1) +X=$($makecmd ADK_TOPDIR=$topdir 2>&1) if [[ $X != *@(Native compiler works)* ]]; then echo "$X" | sed 's/^/| /' echo Cannot compile a simple test programme. @@ -144,7 +144,7 @@ cat >test.c <<-'EOF' } EOF X=$(echo 'Yay! Native compiler works.' | gzip | \ - $makecmd TOPDIR=$topdir LDADD=-lz 2>&1) + $makecmd ADK_TOPDIR=$topdir LDADD=-lz 2>&1) if [[ $X != *@(Native compiler works)* ]]; then echo "$X" | sed 's/^/| /' echo Cannot compile a libz test programm. diff --git a/scripts/update-patches2 b/scripts/update-patches2 index 5b95f33f9..03a8690b5 100644 --- a/scripts/update-patches2 +++ b/scripts/update-patches2 @@ -23,7 +23,7 @@ CURDIR=$PWD export CURDIR PATCH_LIST rm -f patches/*.new -mksh "${TOPDIR}"/scripts/update-patches |& +mksh "${ADK_TOPDIR}"/scripts/update-patches |& first=1 set -A toedit while IFS= read -p -d '' -r; do |