Closed rpelisse closed 3 years ago
Project cannot be compiled on macos as maven during the execution of mvn install
command reports the following sed
error:
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ jcliff ---
[INFO]
[INFO] --- exec-maven-plugin:1.4.0:exec (default) @ jcliff ---
sed: 1: "s/(String VERSION=)".*" ...": \1 not defined in the RE
[INFO] ------------------------------------------------------------------------
@rpelisse @bserdar
@cmoulliard I think you may be able to get away with simply running $ maven package (instead of install) if you want this to work on MacOSX. Otherwise, simply run this build inside a Docker container based on any Linux.
$ maven package (instead of install)
That fails too and generates sed: 1: "s/(String VERSION=)".*" ...": \1 not defined in the RE
Trick is to build the jar using mvn jar:jar dependency:copy-dependencies
;-)
We cannot run jcliff
bash script as it is on a macos machine
./src/main/scripts/jcliff
./src/main/scripts/jcliff: line 69: @: unbound variable
@cmoulliard you need to pass arguments to the jcliff
command. if you run jcliff -v
it will show a successful result
@cmoulliard that has NOTHING to do with MacOS ;) ! Look at the error message, it's actually Bash complaining that there is an unbound variables !
Which probably means that something the script expect to be defined (like it JCLIFF_HOME which is defined if you install the RPM) is not defined. Given that the content of line 69, it seems the variable JAVA has not been defined, which probably means that JAVA_HOME is not being properly defined.
I'll add a note in the README to say that one need to look into the script and set env vars. I don't want to enumerate the env vars that need to be set because, then you need to update the documentation every time the scripts changes. I would rather keep the script as the "unique source of thruth".
@cmoulliard Here the manual steps to install JCliff, feel free to review and coments!