0

I am a total beginner in programming and for school i have to make a little SableCC project. However im not sure how to use SableCC properly.

I have downloaded it from sablecc.org and i did what was said in the readme to install it.

So after installing with the java -jar lib/sablecc.jar command the console tells me how the usage works, like for example

sablecc --license

or to use

sablecc [-d destination] 

to where i want sablecc to work (i guess).

However, when i use anything from this list it just says:

Sablecc is not recognized as an internal or external command

What have i done wrong? Thanks!

Tomasz Jakub Rup
  • 10,502
  • 7
  • 48
  • 49
ceso
  • 101
  • 1
  • 6
  • I dont know really how to set the path right. I added the sablecc/bin folder to the path but it looks like this is wrong. Could u possibly help me with that? – ceso Dec 18 '15 at 09:33

1 Answers1

0

I followed also the instruction of [README.html][1] for ANT and it worked fine for me.

edit: I put some commands here in case the link is unavailable some time.

After downloading, follow the next steps:

  • Decompress the file sablecc-3.2.tar.gz or sablecc-3.2.zip:
    tar -xzvf sablecc-3.2.tar.gz or jar -xvf sablecc-3.2.zip
  • Go to the created directory:
    cd sablecc-3.2
  • You will find an executable sablecc.jar file in the lib directory:
    java -jar lib/sablecc.jar

This is it.

If you have Ant installed on your system, you can install SableCC with the command:

ant -Dinstall.dir=destination install
Kate Drak
  • 1
  • 2
  • Can you include some of the key points of the README as part of your answer? If that link ever gets moved or goes down, it would effectively make your answer useless in its current form. – Michael Dodd Apr 03 '17 at 11:06