2
« on: March 13, 2020, 07:53:01 am »
I'm new to linux and C/C++ programming. I'm using ubuntu 18.04 and netbeans 11.3.
I could manage to build and run the test program via terminal using these commands:
SFML is installed in usr/include which I think is the standard path.
c++ -c main.cpp
g++ main.o -o sfml-app -lsfml-graphics -lsfml-window -lsfml-system
./sfml-app
But if I try to run it in Netbeans I get these errors:
cd '/home/gui/NetBeansProjects/main.cpp'
/usr/bin/make -f Makefile CONF=Debug
"/usr/bin/make" -f nbproject/Makefile-Debug.mk QMAKE= SUBPROJECTS= .build-conf
make[1]: Entering directory '/home/gui/NetBeansProjects/main.cpp'
"/usr/bin/make" -f nbproject/Makefile-Debug.mk dist/Debug/GNU-Linux/main.cpp
make[2]: Entering directory '/home/gui/NetBeansProjects/main.cpp'
mkdir -p dist/Debug/GNU-Linux
g++-7 -o dist/Debug/GNU-Linux/main.cpp build/Debug/GNU-Linux/main.o -lAudio -lGraphics -lNetwork -lSystem -lWindow
/usr/bin/ld: cannot find -lAudio
/usr/bin/ld: cannot find -lGraphics
/usr/bin/ld: cannot find -lNetwork
/usr/bin/ld: cannot find -lSystem
/usr/bin/ld: cannot find -lWindow
collect2: error: ld returned 1 exit status
nbproject/Makefile-Debug.mk:62: recipe for target 'dist/Debug/GNU-Linux/main.cpp' failed
make[2]: *** [dist/Debug/GNU-Linux/main.cpp] Error 1
make[2]: Leaving directory '/home/gui/NetBeansProjects/main.cpp'
nbproject/Makefile-Debug.mk:59: recipe for target '.build-conf' failed
make[1]: *** [.build-conf] Error 2
make[1]: Leaving directory '/home/gui/NetBeansProjects/main.cpp'
nbproject/Makefile-impl.mk:39: recipe for target '.build-impl' failed
make: *** [.build-impl] Error 2
BUILD FAILED (exit value 2, total time: 115ms)
I dont really understand it...