[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[tyndur-devel] [PATCH 2/4] build: das root-Makefile nicht mehr auto-generieren



Signed-off-by: Andreas Freimuth <m.nemo@xxxxxxx>
---
 buildmk.sh |   98 ++++++------------------------------------------------------
 1 file changed, 9 insertions(+), 89 deletions(-)

diff --git a/buildmk.sh b/buildmk.sh
index 7382712..7da50d9 100644
--- a/buildmk.sh
+++ b/buildmk.sh
@@ -98,17 +98,18 @@ EOF
   else
     echo GRUB_VERSION=grub2 >> Makefile.local
   fi
-fi
 
-# Nur die Unterverzeichnisse nutzen den absoluten Pfad zu Makefile.local, um
-# Änderungen am Makefile im Wurzelverzeichnis zu verhindern
-if [ "$LOST_BUILDMK_ROOT" == "`pwd`" ]; then
-  echo "-include Makefile.local" > Makefile
-else
-  echo "-include $LOST_BUILDMK_ROOT/Makefile.local" > Makefile
+  for dir in doc src; do
+    cd $dir
+    bash $LOST_BUILDMK_ROOT/buildmk.sh "$INCLUDES" "$LIBDIRS"
+    cd ..
+  done
+
+  exit 0
 fi
 
-cat <<EOF >> Makefile
+cat <<EOF > Makefile
+-include $LOST_BUILDMK_ROOT/Makefile.local
 
 CC=\$(CC_BINARY) $CC_FLAGS $INCLUDES $CC_FLAGS_APPEND
 CPP=\$(CPP_BINARY) $INCLUDES
@@ -270,84 +271,3 @@ clean: clean_objs
 
 .SILENT: all makefiles subdirs obj lbuilds-env enable-pascal disable-pascal clean softclean clean_objs clean_root updateroot image-floppy image-hd test-qemu test-qemu-hd
 EOF
-
-if [ "$LOST_BUILDMK_ROOT" == "`pwd`" ]; then
-cat <<EOF >> Makefile
-.PHONY: lbuilds-env
-
-# Code für lbuilds
-lbuilds-env:
-	if [ -d lbuilds ]; then cd lbuilds && git pull; else git clone git://git.tyndur.org/lbuilds.git lbuilds; fi
-	touch lbuilds/.nobuild
-	cd lbuilds && scripts/build_crosstools && scripts/update_env \`dirname \\\`pwd\\\`\` && ln -sf \`pwd\`/tmp/cross-fpc/fpc-2.4.0/rtl/ \`dirname \\\`pwd\\\`\`/src/modules/pas/lib/rtl/include
-	make enable-pascal
-	\$(MAKE)
-	cd lbuilds && scripts/update_env ..
-
-enable-pascal:
-	touch src/modules/pas/.ignorenobuild
-
-disable-pascal:
-	rm -f src/modules/pas/.ignorenobuild
-
-clean: clean_root
-
-clean_root:
-	rm -rf build/images/* build/root/*
-	rm -f build/output/apps/* build/output/modules/* build/output/kernel/* build/output/gz/*/*
-	rm -f qemu-serial.log
-
-updateroot: subdirs
-	build/scripts/updateroot
-
-image-floppy: updateroot
-	build/scripts/image_floppy_\$(GRUB_VERSION)
-
-image-hd: updateroot
-	build/scripts/image_hd_\$(GRUB_VERSION)
-
-image-cdrom: updateroot
-	build/scripts/image_cdrom_\$(GRUB_VERSION)
-
-test-qemu-floppy: image-floppy
-	$LOST_TOOLS_QEMU -serial stdio -fda build/images/floppy.img -boot a -net user -net nic,model=rtl8139 | tee qemu-serial.log
-
-test-qemu-hd: image-hd
-	$LOST_TOOLS_QEMU -serial stdio -hda build/images/hd.img -net user -net nic,model=rtl8139 | tee qemu-serial.log
-
-test-qemu-cdrom: image-cdrom
-	$LOST_TOOLS_QEMU -serial stdio -cdrom build/images/cdrom.img -boot d -net user -net nic,model=rtl8139 | tee qemu-serial.log
-
-test-bochs: image-floppy
-	bochs -f bochs.config
-
-cscope:
-	rm -f cscope.*
-	find \`pwd\`/src -name '*.[ch]' > cscope.files
-	cscope -bk
-
-menuconfig:
-	python config.py
-
-documentation:
-	test -d doc/doxygen || mkdir doc/doxygen
-	test -d doc/doxygen/modules || mkdir doc/doxygen/modules
-	test -d doc/doxygen/kernel || mkdir doc/doxygen/kernel
-	rm -R doc/doxygen/modules/*
-	rm -R doc/doxygen/kernel/*
-	doxygen doxyfile_modules
-	doxygen doxyfile_kernel
-
-bugreport:
-	mkdir bugreport
-	gcc -v 2> bugreport/gcc.version
-	nasm -v > bugreport/nasm.version
-	ld -v > bugreport/ld.version
-	
-	cp build/*.mod bugreport/
-	cp build/*.krn bugreport/
-	
-	tar cjf bugreport.tar.bz2 bugreport
-	rm -rf bugreport
-EOF
-fi
-- 
1.7.9.3