Skip to content

Commit fbc4cdd

Browse files
committed
fix P4A_xxx_DIR, it wasnt working at all, using directory from the previous module.
1 parent 7afd219 commit fbc4cdd

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

distribute.sh

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -435,9 +435,14 @@ function run_get_packages() {
435435
module_dir=$(eval "echo \$P4A_${module}_DIR")
436436
if [ "$module_dir" ]
437437
then
438-
debug "\$P4A_${module}_DIR is not empty, using $module_dir dir instead of downloading"
439-
cp -rf $module_dir $directory
440-
directory=$(get_directory $filename)
438+
debug "\$P4A_${module}_DIR is not empty, linking $module_dir dir instead of downloading"
439+
directory=$(eval "echo \$BUILD_${module}")
440+
if [ -e $directory ]; then
441+
try rm -rf "$directory"
442+
fi
443+
try mkdir -p "$directory"
444+
try rmdir "$directory"
445+
try ln -s "$module_dir" "$directory"
441446
continue
442447
fi
443448
debug "Download package for $module"

0 commit comments

Comments
 (0)