summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/install.sh68
-rwxr-xr-xscripts/prereq.sh57
2 files changed, 10 insertions, 115 deletions
diff --git a/scripts/install.sh b/scripts/install.sh
index 335607391..1efbaad02 100755
--- a/scripts/install.sh
+++ b/scripts/install.sh
@@ -1,6 +1,6 @@
#!/usr/bin/env bash
#-
-# Copyright © 2010-2023
+# Copyright © 2010-2025
# Waldemar Brodkorb <wbx@openadk.org>
# Thorsten Glaser <tg@mirbsd.org>
#
@@ -127,13 +127,6 @@ case $ostype {
(Linux)
tools="bc mkfs.ext4 mkfs.vfat tune2fs partprobe"
;;
-(Darwin)
- tools="bc diskutil"
- if [[ $paragon_ext == 0 ]]; then
- export PATH=/usr/local/opt/e2fsprogs/sbin:/usr/local/opt/e2fsprogs/bin:$PATH
- tools="$tools fuse-ext2 umount mkfs.ext4 tune2fs"
- fi
- ;;
(*)
print -u2 Sorry, not ported to the OS "'$ostype'" yet.
exit 1
@@ -171,54 +164,6 @@ fi
(( quiet )) || print "Installing $src on $tgt."
case $ostype {
-(Darwin)
- R=/Volumes/ADKROOT; diskutil unmount $R || umount $R
- B=/Volumes/ADKBOOT; diskutil unmount $B || umount $B
- D=/Volumes/ADKDATA; diskutil unmount $D || umount $D
- basedev=$tgt
- rootpart=${basedev}s1
- datapart=${basedev}s2
- if [[ $target = raspberry-pi || $target = raspberry-pi0 || $target = raspberry-pi2 || $target = raspberry-pi3 || $target = raspberry-pi3-64 || $target = raspberry-pi4 || $target = raspberry-pi4-64 || $target = raspberry-pi5 || $target = phytec-wega ]]; then
- bootpart=${basedev}s1
- rootpart=${basedev}s2
- datapart=${basedev}s3
- fi
- match=\'${basedev}\''?(s+([0-9]))'
- function mount_fs {
- if [[ $paragon_ext == 0 && $3 = ext4 ]]; then
- mkdir -p $2
- fuse-ext2 "$1" "$2" -o rw+
- fi
- }
- function umount_fs {
- (( quiet )) || print "Unmounting filesystem on ${1}..."
- if [[ $paragon_ext == 0 ]]; then
- umount "$1" || diskutil unmount "$1" || true
- rmdir $2 || true
- else
- diskutil unmount "$1"
- fi
- }
- function create_fs {
- (( quiet )) || printf "Creating filesystem on ${1}"
- if [[ $paragon_ext == 0 && $3 = ext4 ]]; then
- mkfs.ext4 -L "$2" "$1"
- else
- if [[ $3 = ext4 ]]; then
- fstype=UFSD_EXTFS4
- fi
- if [[ $3 = vfat ]]; then
- fstype=fat32
- fi
- diskutil eraseVolume $fstype "$2" "$1"
- fi
- }
- function tune_fs {
- if [[ $paragon_ext == 0 && $3 = ext4 ]]; then
- tune2fs -c 0 -i 0 "$1"
- fi
- }
- ;;
(Linux)
basedev=$tgt
@@ -277,12 +222,11 @@ if ! T=$(mktemp -d /tmp/openadk.XXXXXXXXXX); then
print -u2 Error creating temporary directory.
exit 1
fi
-if [[ $ostype != Darwin ]]; then
- R=$T/rootmnt
- B=$T/bootmnt
- D=$T/datamnt
- mkdir -p "$R" "$B" "$D"
-fi
+
+R=$T/rootmnt
+B=$T/bootmnt
+D=$T/datamnt
+mkdir -p "$R" "$B" "$D"
# get disk size
dksz=$(dkgetsz "$tgt")
diff --git a/scripts/prereq.sh b/scripts/prereq.sh
index 8caa5d5f5..aed832da4 100755
--- a/scripts/prereq.sh
+++ b/scripts/prereq.sh
@@ -25,19 +25,6 @@ rm -f foo
echo >FOO
if [ -e foo ]; then
printf "ERROR: OpenADK cannot be built in a case-insensitive file system.\n"
- case $os in
- CYG*)
- printf "Building OpenADK on $os needs a small registry change.\n"
- printf "http://cygwin.com/cygwin-ug-net/using-specialnames.html\n"
- ;;
- Darwin*)
- printf "Building OpenADK on $os needs a case-sensitive disk partition.\n"
- printf "For Snow Leopard and above you can use diskutil to resize your existing disk.\n"
- printf "Example: sudo diskutil resizeVolume disk0s2 90G 1 jhfsx adk 30G\n"
- printf "For older versions you might consider to use a disk image:\n"
- printf "hdiutil create -type SPARSE -fs 'Case-sensitive Journaled HFS+' -size 30g ~/openadk.dmg\n"
- ;;
- esac
rm -f FOO
exit 1
fi
@@ -110,11 +97,8 @@ if [ ! -d $topdir/dl ]; then
fi
# check for c compiler
-if [ $os = "Darwin" ]; then
- compilerbins="clang cc gcc"
-else
- compilerbins="cc gcc clang"
-fi
+compilerbins="cc gcc clang"
+
for compilerbin in $compilerbins; do
printf " ---> checking if $compilerbin is installed.. "
if which $compilerbin >/dev/null; then
@@ -133,11 +117,8 @@ if [ -z "$CCFOUND" ]; then
fi
# check for c++ compiler
-if [ $os = "Darwin" ]; then
- compilerbins="clang++ c++ g++"
-else
- compilerbins="c++ g++ clang++"
-fi
+compilerbins="c++ g++ clang++"
+
for compilerbin in $compilerbins; do
printf " ---> checking if $compilerbin is installed.. "
if which $compilerbin >/dev/null; then
@@ -755,36 +736,6 @@ case $os in
printf "\tbool\n" >> $topdir/target/config/Config.in.prereq
printf "\tdefault y\n" >> $topdir/target/config/Config.in.prereq
;;
- Darwin)
- printf "\nconfig ADK_HOST_DARWIN\n" >> $topdir/target/config/Config.in.prereq
- printf "\tbool\n" >> $topdir/target/config/Config.in.prereq
- printf "\tdefault y\n" >> $topdir/target/config/Config.in.prereq
- ;;
- OpenBSD)
- printf "\nconfig ADK_HOST_OPENBSD\n" >> $topdir/target/config/Config.in.prereq
- printf "\tbool\n" >> $topdir/target/config/Config.in.prereq
- printf "\tdefault y\n" >> $topdir/target/config/Config.in.prereq
- ;;
- FreeBSD)
- printf "\nconfig ADK_HOST_FREEBSD\n" >> $topdir/target/config/Config.in.prereq
- printf "\tbool\n" >> $topdir/target/config/Config.in.prereq
- printf "\tdefault y\n" >> $topdir/target/config/Config.in.prereq
- ;;
- NetBSD)
- printf "\nconfig ADK_HOST_NETBSD\n" >> $topdir/target/config/Config.in.prereq
- printf "\tbool\n" >> $topdir/target/config/Config.in.prereq
- printf "\tdefault y\n" >> $topdir/target/config/Config.in.prereq
- ;;
- MirBSD)
- printf "\nconfig ADK_HOST_MIRBSD\n" >> $topdir/target/config/Config.in.prereq
- printf "\tbool\n" >> $topdir/target/config/Config.in.prereq
- printf "\tdefault y\n" >> $topdir/target/config/Config.in.prereq
- ;;
- Cygwin*)
- printf "\nconfig ADK_HOST_CYGWIN\n" >> $topdir/target/config/Config.in.prereq
- printf "\tbool\n" >> $topdir/target/config/Config.in.prereq
- printf "\tdefault y\n" >> $topdir/target/config/Config.in.prereq
- ;;
esac
if [ "$target" = "defconfig" ]; then