I`m developing a application using gtkmm with eclipse. While I could have setup gtkmm include paths and linking options manually, i decided to let pkg-config do the work because of the huge number of referenced projects. This was quite easy as adding the appropriate pkg-config command to the compiler invocation worked just fine because one can simply use the
`...`
shell substitution since eclipse will generate a makefile which is then executed.
Setting up the indexer right isnt that easy though. Instead of executing shell script in a interpreter, eclipse executes the compiler directly and pass command line arguments directly without substituting them before.
How can one execute shell script when executing the indexer?
The solution is to execute the bash interpreter with the
-cflag directly instead of executing g++.For the scenario described in the question the configurations are as followed:
Compiler invocation command bash Compiler invocation arguements -c "g++ `pkg-config gtkmm-2.4 --cflags` -E -P -v -dD ${plugin_state_location}/specs.cpp"