summaryrefslogtreecommitdiff
path: root/test/simple-build-check.sh
blob: faa7c46432dcde340eb36ec5f3e69112ad0429b5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#/bin/sh

EXTRAS="\
	extras/scsi_id \
	extras/ata_id \
	extras/volume_id \
	extras/usb_id \
	extras/dasd_id \
	extras/cdrom_id \
	extras/edd_id \
	extras/floppy \
	extras/run_directory \
	extras/firmware"

# with debug
make clean EXTRAS="$EXTRAS" >/dev/null
make all -j4 $MAKEOPTS DEBUG=true EXTRAS="$EXTRAS" || exit
echo -e "\n\n"

# without any logging
make clean EXTRAS="$EXTRAS" >/dev/null
make all $MAKEOPTS USE_LOG=false EXTRAS="$EXTRAS" || exit
echo -e "\n\n"

# klibc build
if [ -n "$KLCC" -a -e "$KLCC" ]; then
	echo KLCC: "$KLCC"
	make clean EXTRAS="$EXTRAS" >/dev/null
	make all -j4 $MAKEOPTS USE_KLIBC=true DEBUG=true EXTRAS="$EXTRAS" KLCC="$KLCC" || exit
	echo -e "\n\n"
fi

# install in temporary dir and show it
TEMPDIR="`pwd`/.tmp"
rm -rf $TEMPDIR
mkdir $TEMPDIR
make clean EXTRAS="$EXTRAS" >/dev/null
make all $MAKEOPTS DESTDIR="$TEMPDIR" EXTRAS="$EXTRAS" || exit
make install DESTDIR="$TEMPDIR" EXTRAS="$EXTRAS" || exit
echo -e "\nInstalled tree:"
find $TEMPDIR
rm -rf $TEMPDIR

make clean EXTRAS="$EXTRAS" >/dev/null