diff options
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/update_pch | 7 | ||||
-rwxr-xr-x | bin/update_pch.sh | 8 |
2 files changed, 12 insertions, 3 deletions
diff --git a/bin/update_pch b/bin/update_pch index 10f5e2e9df65..6112fc654555 100755 --- a/bin/update_pch +++ b/bin/update_pch @@ -33,6 +33,7 @@ EXCLUDE_MODULE = False EXCLUDE_LOCAL = False EXCLUDE_SYSTEM = True SILENT = False +WORKDIR = 'workdir' # System includes: oox, sal, sd, svl, vcl @@ -607,7 +608,7 @@ def parse_makefile(groups, lines, lineno, lastif, ifstack): if osname not in groups: groups[osname] = [] if ingeneratedobjects: - file = 'workdir/' + file + file = WORKDIR + '/' + file groups[osname].append(file) return groups @@ -909,6 +910,10 @@ def main(): global EXCLUDE_LOCAL global EXCLUDE_SYSTEM global SILENT + global WORKDIR + + if os.getenv('WORKDIR'): + WORKDIR = os.getenv('WORKDIR') root = '.' module = sys.argv[1] diff --git a/bin/update_pch.sh b/bin/update_pch.sh index 5299242b9d7c..78b4a47e6044 100755 --- a/bin/update_pch.sh +++ b/bin/update_pch.sh @@ -11,8 +11,12 @@ # Usage: update_pch.sh [<module>] # Invoke: make cmd cmd="./bin/update_pch.sh [..]" -root=`dirname $0` -root=`cd $root/.. >/dev/null && pwd` +if test -n "$SRC_DIR"; then + root="$SRC_DIR" +else + root=`dirname $0` + root=`cd $root/.. >/dev/null && pwd` +fi root=`readlink -f $root` cd $root |