grobian / carbon-c-relay

Enhanced C implementation of Carbon relay, aggregator and rewriter
Apache License 2.0
380 stars 107 forks source link

Dockerfile: add bison flex dependency for latest build #449

Closed flucrezia closed 1 year ago

flucrezia commented 2 years ago

Updating the apk add line in the Dockerfile as follows:

RUN \ apk add --no-cache flex bison git bc build-base curl automake autoconf libtool && \ ./configure && make

the build is again successful.

Thanks, Francesco

grobian commented 1 year ago

I'm not against something like this but I wonder if this should be necessary, the idea is to have pre-created copies in the git repo to avoid having the need for certain (versions of) buildtools.

flucrezia commented 1 year ago

Running the command: docker build -t grobian/carbon-c-relay . I'm getting the following on my Dell laptop with Ubuntu 20.04. Instead on a virtual machine with also Ubuntu 20.04 it builds smoothly...Strange.


...
bison -d conffile.y
make[1]: bison: No such file or directory
make[1]: *** [Makefile:1138: conffile.tab.h] Error 127
make[1]: Leaving directory '/opt/carbon-c-relay-build'
make: *** [Makefile:469: all] Error 2
The command '/bin/sh -c apk add --no-cache git bc build-base curl automake autoconf libtool &&   ./configure && make 
returned a non-zero code: 2```
grobian commented 1 year ago

I managed to do the docker build thing successfully with the changes I just pushed, please let me know if this is also fixing the problem for you

flucrezia commented 1 year ago

Yes it fixed the build on my laptop, thanks!