Frege/frege

make complier failed on MacOS

Closed this issue ยท 4 comments

Hzqi commented

I follow the steps in https://github.com/Frege/frege/wiki/Contributing-to-Frege. I get the source code, and run make fetch-fregec.jar in my terminal, then I got :

curl -H 'Accept: application/vnd.github.v3.raw' -kL -o fregec.jar `grep curl .travis.yml | sed 's/.*https:/http:/' | sed 's/\s*$//'`
curl: (3) Illegal characters found in URL
make: *** [fetch-fregec.jar] Error 3

it seems that my curl doesn't recognize those chareacters. Than I ignore it, I just go on run the command make runtime compiler, then I got:

mkdir -p build shadow
[ "1.8" = "1.7" ] || javac -encoding UTF-8 -d build -source 1.8 -target 1.8 frege/run8/*.java
javac -encoding UTF-8 -d build -nowarn -source 1.7 -target 1.7 frege/runtime/*.java frege/run/*.java frege/run7/*.java
Runtime is complete.
Making frege/Version.fr
perl scripts/mkversion.pl > frege/Version.fr
Making compiler1
time -f "%E %Mk"        java -Dfrege.javac=internal -Xss4m -Xmx2222m -cp build -jar fregec.jar -d build -hints -ascii -nocp -prefix a -sp "shadow:."  -target 1.7  -make frege.compiler.Main
/bin/sh: -f: command not found

real	0m0.001s
user	0m0.000s
sys	0m0.001s
make: *** [compiler1] Error 127

It seems that I don't have the command -f, it's there anything I do wrong? or need I install some tools first?
My javac : javac 1.8.0_191
My computer : MacOS 10.14

  1. You can try the curl command from the travis.xml directly

  2. Your test-command does not recognize the -f flag. Rather it thinks this must be the command name. Workaround:

    make TIME=time

or just edit the Makefile.

Ohh, and by the way, you'd need at least JDK 9 to build frege, as described in the Wiki,

Hzqi commented

Ohh, and by the way, you'd need at least JDK 9 to build frege, as described in the Wiki,

I thought it can be runned on JDK8 while the link says JDK7 ... ๐Ÿ˜…๐Ÿ˜…

Yes. It is only the compiler itself that needs the JDK9 for building.
Once it is build, it can be run with JDK 8, and the compiled programs as well.

Hzqi commented

Yes. It is only the compiler itself that needs the JDK9 for building.
Once it is build, it can be run with JDK 8, and the compiled programs as well.

thx, it works, the issue can be closed now.๐Ÿ˜„๐Ÿ˜„