Code::Blocks Forums

User forums => Using Code::Blocks => Topic started by: BDick on December 18, 2018, 09:22:23 am

Title: make a DLL from FORTRAN code with PGI compilers
Post by: BDick on December 18, 2018, 09:22:23 am
I am migrating my FORTRAN projects from OpenWatcom to the PGI compiler. Since this comes without a IDE, I have chosen CODE::BLOCKS. So far its working fine for the project type "FORTRAN application". However, when building a project type "FORTRAN DLL", I get an error message. It seems that the compiler receives the option -shared, which the PGI compiler apparently does not know. However, nowhere in the project options dialog can I select (or de-select) this option. Where can I find this setting and change it to what the PGI-compiler expects (e.g. -Bdynamic).
many thanks,
Bernhard
Title: Re: make a DLL from FORTRAN code with PGI compilers
Post by: stahta01 on December 18, 2018, 04:37:52 pm
Settings -> Compiler
Full to the right tab "Other Settings"
Tab "Advanced Options"
Tab "Commands"
Command: "Link object files to dynamic library"
Command line macro value likely needs edited; but, I would suggest using a separate profile for FORTRAN.

Edit link to profile/personality option http://wiki.codeblocks.org/index.php/Code::Blocks_command_line_arguments (http://wiki.codeblocks.org/index.php/Code::Blocks_command_line_arguments)

Tim S.