aboutsummaryrefslogtreecommitdiffstats
path: root/support/scripts
diff options
context:
space:
mode:
authorPerry Hung <iperry@gmail.com>2011-01-24 23:23:29 -0500
committerPerry Hung <iperry@gmail.com>2011-01-24 23:23:29 -0500
commitc48689d34809943a5907884bd287cea9ae275352 (patch)
treed49ff06b0d4b81f6ab0eac8060d178ce7542476c /support/scripts
parent64431fd4b59cb8656365f1fad5f679cd4d756239 (diff)
parenta9b2d70bc7799ca96c1673b18fe3012b1a4dd329 (diff)
downloadlibrambutan-c48689d34809943a5907884bd287cea9ae275352.tar.gz
librambutan-c48689d34809943a5907884bd287cea9ae275352.zip
Merge remote branch 'leaf/master'
Diffstat (limited to 'support/scripts')
-rwxr-xr-xsupport/scripts/copy-to-ide42
1 files changed, 30 insertions, 12 deletions
diff --git a/support/scripts/copy-to-ide b/support/scripts/copy-to-ide
index 5bf52a4..301126d 100755
--- a/support/scripts/copy-to-ide
+++ b/support/scripts/copy-to-ide
@@ -1,16 +1,18 @@
#!/bin/sh
-# This hackish script copies the necessary library files into the Maple IDE
+# This hack copies the necessary library files into the Maple IDE
# repository.
-# Change this
-DEST=`pwd`/../maple-ide/hardware/leaflabs/cores/maple/
+DEST=$1
-ARCH=`uname -a`
+DEST_REF=$DEST/build/shared/reference
+DEST_CORES=$DEST/hardware/leaflabs/cores/maple
+DEST_LIBS=$DEST/libraries
-FILES="LICENSE
+LMAPLE_SRC="LICENSE
./libmaple/*.h
./libmaple/*.c
+ ./libmaple/*.S
./libmaple/usb/*.h
./libmaple/usb/*.c
./libmaple/usb/usb_lib/*.h
@@ -21,11 +23,13 @@ FILES="LICENSE
./wirish/*.cpp
./wirish/comm/*.cpp
./wirish/comm/*.h
- ./support/ld/maple/
- ./support/ld/maple_native/
+ ./support/ld/maple
+ ./support/ld/maple_native
./support/ld/libcs3-lanchon-stm32.a
./support/ld/names.inc"
+LMAPLE_DOCS=./docs
+LMAPLE_DOCS_BUILD=$LMAPLE_DOCS/build/html
echo "First make sure DEST exists: $DEST"
if !(test -d $DEST)
@@ -34,9 +38,23 @@ then
exit -1
fi
-echo "Then delete the old files..."
-rm -r $DEST/*.c $DEST/*.cpp $DEST/*.h $DEST/*.cxx $DEST/*.ld $DEST/*.inc $DEST/*.a $DEST/maple/ $DEST/maple_native/
+# source
+echo Copying libmaple source
+rm -rf $DEST_CORES/*.c $DEST_CORES/*.cpp $DEST_CORES/*.h $DEST_CORES/*.cxx $DEST_CORES/*.inc $DEST_CORES/*.a $DEST_CORES/*.S $DEST_CORES/maple $DEST_CORES/maple_native
+cp -R $LMAPLE_SRC $DEST_CORES
-echo "Finally copy the new source files!"
-cp -r $FILES $DEST
-echo "Done."
+echo Copying over libraries
+cp -R libraries/* $DEST_LIBS
+
+# docs
+echo Deleting old reference directory contents
+rm -rf $DEST_REF/*
+
+echo Rebuilding documentation
+( cd $LMAPLE_DOCS; doxygen && make clean 2>/dev/null 1>/dev/null && make html )
+
+echo Copying over documentation
+cp -R $LMAPLE_DOCS_BUILD/* $DEST_REF
+
+
+echo Done.