fix for drawmodules.py to colour modules beginning with "senf::emu" in orange instead...
[senf.git] / tools / find-sources.sh
index 3c2c283..4a1e734 100755 (executable)
@@ -1,16 +1,5 @@
 #!/bin/sh -e
 
-if [ -z "$1" ]; then
-    echo "Usage:"
-    echo "  $0 [-c] <commands>"
-    echo
-    echo "-c Only list C/C++ source files"
-    echo
-    echo "<commands> are any find commands (which should contain a -print somewhere)"
-    echo "which are matched for any file fond"
-    exit 1
-fi
-
 cond=""
 if [ "$1" = "-c" ]; then
     shift
@@ -22,11 +11,17 @@ set -f
 find . \
     -name .svn -prune -o \
     -name .git -prune -o \
+    -name .sconf_temp -prune -o \
     -name doc -prune -o \
     -name debian -prune -o \
     -name dist -prune -o \
+    -name build -prune -o \
+    -path "*/tools/scons-*" -prune -o \
     -name "*.a" -o \
     -name "*.o" -o \
+    -name "*.os" -o \
+    -name "*.so" -o \
+    \( -type f -a ! -name "*.*" -a -exec sh -c "file --brief {} | grep -q ELF" \; \) -o \
     -name "*~" -o \
     -name "#*#" -o \
     -name "*.pyc" -o \
@@ -35,4 +30,4 @@ find . \
     -name ".sconsign*" -o \
     -name "semantic.cache" -o \
     -name "all_includes.hh" -o \
-    -type f $cond \( "$@" \)
+    -type f $cond \( "$@" -print \)