News:

As usual while waiting for the next release - don't forget to check the nightly builds in the forum.

Main Menu

g++: fatal error: no input files

Started by niconol, September 25, 2017, 02:49:29 PM

Previous topic - Next topic

niconol

Hi,

I've got this error when compiling

g++ -std=c++11 -g 'pkg-config gtkmm-3.0 --cflags' 'pkg-config opencv --cflags' pkg-config --libs opencv' -std=c++11  -c /home/pi/reretest/ihm.cpp -o obj/Debug/ihm.o
g++: fatal error: no input files
compilation terminated.
Process terminated with status 4 (0 minute(s), 0 second(s))
0 error(s), 0 warning(s) (0 minute(s), 0 second(s))


but ihm.cpp and ihm.h are in the same directory than the .cbp.

An idea to help me please ???

Best


(reretest)

BlueHazzard

have you tried to run this from the command line with the base path of your project:
g++ -std=c++11 -g 'pkg-config gtkmm-3.0 --cflags' 'pkg-config opencv --cflags' pkg-config --libs opencv' -std=c++11  -c /home/pi/reretest/ihm.cpp -o obj/Debug/ihm.o
?

[EDIT:] You are missing a back-tick in the
pkg-config --libs opencv'
at the beginning...

BlueHazzard

You probably also want to use back ticks (`command`) and not apostrophes ('command')

niconol

Hi,
I added the back-tick, thanks

I change priority to compile first main.cpp
g++ -std=c++11 -g 'pkg-config gtkmm-3.0 --cflags' 'pkg-config opencv --cflags' pkg-config --libs opencv' -std=c++11

problem is the same.

I tried
g++ -std=c++11 -g 'pkg-config gtkmm-3.0 --cflags' 'pkg-config opencv --cflags' pkg-config --libs opencv' -std=c++11
form the command line

end immediately
no cimpilation I think,
I check the presences of files by a "ls"
g++ -std=c++11 -g 'pkg-config gtkmm-3.0 --cflags' 'pkg-config opencv --cflags' pkg-config --libs opencv' -std=c++11

they are here
pi@raspberrypi:~/reretest $ ls
bin      ihm.h        ihm_sig.h  obj       pict.h        reretest.layout
ihm.cpp  ihm_sig.cpp  main.cpp   pict.cpp  reretest.cbp


and meanwhile, BlueHazzard find a big beginner's mistake,
of course, about backticks

Thanks a lot, I can continue now, and be more careful