hexagonal-sun / bic

A C interpreter and API explorer.
GNU General Public License v2.0
815 stars 36 forks source link

Unable to compile on debian sid #2

Closed lollipopman closed 5 years ago

lollipopman commented 5 years ago

Following the directions on the readme results in this error:

$ make
make  all-recursive
make[1]: Entering directory '/home/hathaway/src/bic'
Making all in src
make[2]: Entering directory '/home/hathaway/src/bic/src'
: --header-file=cfilelex.h -o /dev/null cfilelex.l
: --header-file=repllex.h -o /dev/null repllex.l
: --header-file=lang_lexer.h -o /dev/null lang_lexer.lpp
  CXX      lang.o
lang.cpp:4:10: fatal error: lang_lexer.h: No such file or directory
    4 | #include "lang_lexer.h"
      |          ^~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [Makefile:896: lang.o] Error 1
make[2]: Leaving directory '/home/hathaway/src/bic/src'
make[1]: *** [Makefile:410: all-recursive] Error 1
make[1]: Leaving directory '/home/hathaway/src/bic'
make: *** [Makefile:342: all] Error 2

looks like I need to generate the lang_lexer.h file, how do I do that?

billpcs commented 5 years ago

~I think it's been mistakenly placed in the .gitignore file. So it's not there.~

hexagonal-sun commented 5 years ago

Hi there, lang_lexer.h is generated by flex. Looking at your compilation output it doesn't appear to be installed:

: --header-file=cfilelex.h -o /dev/null cfilelex.l

should be

flex --header-file=cfilelex.h -o /dev/null cfilelex.l

Maybe try apt-get install flex?

lollipopman commented 5 years ago

awesome, that fixed it!