I am a big fan of Geany IDE and Ubuntu. I am learning Objective-C programming language. I have Objective-C Environment in Ubuntu 16.04 and I compile Objective-C programs using terminal. But I want to make a build command in Geany for that purpose. But Geany recognises Objective-C programs which have .m file extension as Matlab/Octave commands. So suggest me a method to compile & execute Objective-C programs directly from Geany by making a build command in Geany.
Geany should already have a build configuration for Objective-C, provided by the
filetypes.objectivec file (part of the
[build_settings] # %f will be replaced by the complete filename # %e will be replaced by the filename without extension # (use only one of it at one time) compiler=gcc -Wall -c "%f" linker=gcc -Wall -o "%e" "%f" -lobjc run_cmd="./%e"
The tricky part is making geany actually choose that, instead of the one for Matlab (since both filetypes are associated with the
.m extension in the
filetype_extensions.conf file). Currently, the only way I know to do that is to manually select the filetype from the Document menu
Document --> Set Filetype --> Programming Languages --> Objective-C
After that, you should be able to build your file from the Build menu as normal.