forked from JavaTX/JavaCompilerCore
update compile.sh to work on macos (hopefully)
This commit is contained in:
parent
5bee05ac43
commit
228b2b1596
@ -31,7 +31,7 @@ for file in "${JAVA_FILES[@]}"; do
|
|||||||
#substitute *.java -> *.class
|
#substitute *.java -> *.class
|
||||||
class_name="${class_name%.java}.class"
|
class_name="${class_name%.java}.class"
|
||||||
#if .class file does not exists or .class file older than .java file
|
#if .class file does not exists or .class file older than .java file
|
||||||
if [ ! -f "$class_name" ] || [ "$(stat -c "%Y" "$file")" -gt "$(stat -c "%Y" "$class_name")" ]; then
|
if [ ! -f "$class_name" ] || [ "$(find "$file" -prune -newer "$class_name")" ]; then
|
||||||
JAVA_CHANGED+=("$file")
|
JAVA_CHANGED+=("$file")
|
||||||
JAVA_CLASSES+=("$class_name")
|
JAVA_CLASSES+=("$class_name")
|
||||||
fi
|
fi
|
||||||
@ -44,7 +44,7 @@ for file in "${JAV_FILES[@]}"; do
|
|||||||
#substitute *.jav -> *.class
|
#substitute *.jav -> *.class
|
||||||
class_name="${class_name%.jav}.class"
|
class_name="${class_name%.jav}.class"
|
||||||
#if .class file does not exists or .class file older than .jav file
|
#if .class file does not exists or .class file older than .jav file
|
||||||
if [ ! -f "$class_name" ] || [ "$(stat -c "%Y" "$file")" -gt "$(stat -c "%Y" "$class_name")" ]; then
|
if [ ! -f "$class_name" ] || [ "$(find "$file" -prune -newer "$class_name")" ]; then
|
||||||
JAV_CHANGED+=("$file")
|
JAV_CHANGED+=("$file")
|
||||||
JAV_CLASSES+=("$class_name")
|
JAV_CLASSES+=("$class_name")
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user