Author Topic: Compiling GTK 2  (Read 2883 times)

Offline ordak

  • Multiple posting newcomer
  • *
  • Posts: 105
    • My Site
Compiling GTK 2
« on: January 16, 2020, 03:37:31 pm »
Hi,

I am following this link for GTK 2 compiling. In Code::Blocks where can I input these :

-L/usr/lib -L/usr/X11R6/lib
Code::Blocks SVN
OS : Ubuntu LTS

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: Compiling GTK 2
« Reply #1 on: January 16, 2020, 03:51:08 pm »
Project->Build options->Select your project name at the left->Search directories->Linker

Add your paths without the -L

Or you can put your options in
Project->Build options->Select your project name at the left->Linker settings->Other linker options

Offline ordak

  • Multiple posting newcomer
  • *
  • Posts: 105
    • My Site
Re: Compiling GTK 2
« Reply #2 on: January 17, 2020, 01:51:02 pm »
Project->Build options->Select your project name at the left->Search directories->Linker

Add your paths without the -L

Or you can put your options in
Project->Build options->Select your project name at the left->Linker settings->Other linker options

Is the global way ( for all projects) like this :

Setting menu / compiler... / select desired compiler /

Rest is as your post or not ?
Code::Blocks SVN
OS : Ubuntu LTS

Offline BlueHazzard

  • Developer
  • Lives here!
  • *****
  • Posts: 3353
Re: Compiling GTK 2
« Reply #3 on: January 18, 2020, 05:24:14 pm »
Quote
Is the global way ( for all projects) like this :

Setting menu / compiler... / select desired compiler /
yes but:
It is generally not a good idea to modify the global flags. A better way is to create a template project and use this, or modify the wizard script for the default project (a bit advanced)

For creating a project template:
1) Create a new project and set all settings as you like
2) Save the project as template with File->Save project as template

now if you want to use this template
File->New-> project->User templates

Offline ordak

  • Multiple posting newcomer
  • *
  • Posts: 105
    • My Site
Re: Compiling GTK 2
« Reply #4 on: January 19, 2020, 12:51:35 pm »
Quote
Is the global way ( for all projects) like this :

Setting menu / compiler... / select desired compiler /
yes but:
It is generally not a good idea to modify the global flags. A better way is to create a template project and use this, or modify the wizard script for the default project (a bit advanced)


[...]

Actually in Global compiler setting I have different compiler setting in select compiler mode. GTK , warnings and more are configured there ,  I choose it for my temp projects.
Code::Blocks SVN
OS : Ubuntu LTS