Open sumpfralle opened 2 years ago
The only place in build.xml that refers to the freecol script is where it simply copies it into the build staging directory. Looks like an installer/packager problem, not something in our code.
I took a look at the ant documentation for copy
:
File permissions are not retained when files are copied
Thus I proposed specific setpermissions
rules in #110.
Regarding the linebreak conversion (from unix to windows): I have no idea, what could cause this.
The fixcrlf
documentation describes, how lineendings could be converted by ant. But build.xml
contains only three of these operations:
*.java
files with spacesfixTabsWindows
: replace line endings of all *.java
files with CRLF (probably not used)fixTabsUnix
: replace line endings of all *.java
files with LF (probably not used)Thus I have no idea, how these CRLF could end up in the start script.
After running ant -noinput -buildfile build.xml nightly-release
locally, they surprisingly did not appear in the generated zip
file.
I cannot imagine, what could differ between github's build environment (ubuntu-latest
) and mine (Debian).
Maybe #110 accidentally fixes the lineending issue. But that's just a wild hope ...
File permissions are not retained when files are copied
Ugh, I should have guessed ant was being difficult. Thanks for the pointer. However, I applied your patch, but the permissions are still 644 in the freshly built zip. Did it work for you?
Similarly, I can not replicate the CRLF behaviour. The file is still in unix format in the zip for me... however my machine is not what is being used to build the nightlies.
@sumpfralle : Are you experiencing the same issue using the new development build?
I downloaded the latest nightly build (
freecol-nightly-20220420.zip
).It contained the script
freecol
in the directoryfreecol
.This script had two issues:
chmod +x freecol/freecol
.bash: freecol/freecol: /bin/sh^M: bad interpreter: No such file or directory
^M
marks thecarriage return
(\r
) which is not supposed to be there and which is interpreted as being part of the filenamefromdos freecol/freecol
The original script in the repository looks good:
packaging/common/freecol.sh
(executable flag and correct line ending).Thus I guess, that
build.xml
needs some adjustments.Thank you for your time!