mirror of
https://github.com/thiagoralves/OpenPLC_v3.git
synced 2025-12-10 21:18:58 +08:00
Merge pull request #299 from kristiandueholm/docker-build-bug
Add -lrt flag to main compile.
This commit is contained in:
@@ -104,9 +104,9 @@ elif [ "$OPENPLC_PLATFORM" = "linux" ]; then
|
|||||||
./glue_generator
|
./glue_generator
|
||||||
echo "Compiling main program..."
|
echo "Compiling main program..."
|
||||||
if [ "$OPENPLC_DRIVER" = "sl_rp4" ]; then
|
if [ "$OPENPLC_DRIVER" = "sl_rp4" ]; then
|
||||||
g++ -std=gnu++11 *.cpp *.o -o openplc -I ./lib -pthread -fpermissive `pkg-config --cflags --libs libmodbus` -lsnap7 -lasiodnp3 -lasiopal -lopendnp3 -lopenpal -w $ETHERCAT_INC -DSL_RP4
|
g++ -std=gnu++11 *.cpp *.o -o openplc -I ./lib -pthread -fpermissive `pkg-config --cflags --libs libmodbus` -lsnap7 -lasiodnp3 -lasiopal -lopendnp3 -lopenpal -lrt -w $ETHERCAT_INC -DSL_RP4
|
||||||
else
|
else
|
||||||
g++ -std=gnu++11 *.cpp *.o -o openplc -I ./lib -pthread -fpermissive `pkg-config --cflags --libs libmodbus` -lsnap7 -lasiodnp3 -lasiopal -lopendnp3 -lopenpal -w $ETHERCAT_INC
|
g++ -std=gnu++11 *.cpp *.o -o openplc -I ./lib -pthread -fpermissive `pkg-config --cflags --libs libmodbus` -lsnap7 -lasiodnp3 -lasiopal -lopendnp3 -lopenpal -lrt -w $ETHERCAT_INC
|
||||||
fi
|
fi
|
||||||
if [ $? -ne 0 ]; then
|
if [ $? -ne 0 ]; then
|
||||||
echo "Error compiling C files"
|
echo "Error compiling C files"
|
||||||
|
|||||||
Reference in New Issue
Block a user