Author Topic: Using GTK+ with Code::Blocks  (Read 7223 times)

Offline Art in Music

  • Single posting newcomer
  • *
  • Posts: 7
Using GTK+ with Code::Blocks
« on: February 07, 2014, 08:32:12 pm »
Hello,

So, I have recently downloaded the GTK+ (3.0) Package from their site, added the bin folder to the Path in Advanced System Settings, and verified that GTK is working. However, when I try to create a project in Code::Blocks with GTK+ and refer GTK's location to the folder that GTK was installed in, it gives me the following error:

I checked for where the gtk.h file is, and found it in *\include\gtk-3.0\gtk, and tried copying it into the *\include folder, but Code::Block's wizard still says it can't find the file. I'm not sure where that file is supposed to be located according to the wizard, either, so I can't simply put it there. I have the Base, Include, lib, and bin directories referenced properly in the Global Variable editor under the "gtk" variable as well, I believe, so other than creating this help post, I am unsure where to go from here.

Thank you for your assistance,
Dylan

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7591
    • My Best Post
Re: Using GTK+ with Code::Blocks
« Reply #1 on: February 07, 2014, 09:07:44 pm »
IIRC, Right click on Wizard it will allow you to edit the script.

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline Art in Music

  • Single posting newcomer
  • *
  • Posts: 7
Re: Using GTK+ with Code::Blocks
« Reply #2 on: February 07, 2014, 09:12:09 pm »
Sorry,

When I right click on the Wizard, nothing happens, except a basic drop down menu on the... Thing I can't remember. That!

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7591
    • My Best Post
Re: Using GTK+ with Code::Blocks
« Reply #3 on: February 07, 2014, 09:29:06 pm »
In the window where you pick the wizard to be ran, instead of after you have started the wizard.

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline Art in Music

  • Single posting newcomer
  • *
  • Posts: 7
Re: Using GTK+ with Code::Blocks
« Reply #4 on: February 07, 2014, 09:31:36 pm »
Okay,

I see what you mean now. Where do I edit this script to fix it?

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7591
    • My Best Post
Re: Using GTK+ with Code::Blocks
« Reply #5 on: February 07, 2014, 09:50:38 pm »
Okay,

I see what you mean now. Where do I edit this script to fix it?

IIRC, right there.
It saves it somewhere in the user app data area.

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline Art in Music

  • Single posting newcomer
  • *
  • Posts: 7
Re: Using GTK+ with Code::Blocks
« Reply #6 on: February 07, 2014, 09:55:44 pm »
Right,

Only, I don't know what I should be editing within the script.

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7591
    • My Best Post
Re: Using GTK+ with Code::Blocks
« Reply #7 on: February 07, 2014, 10:15:14 pm »
Right,

Only, I don't know what I should be editing within the script.

You can do changes or just look; it saves a local copy of the changes so, you can revert the changes.

But, I have only slight knowledge of scripting in CB.
The Wiki has info; but, not enough to help me without a lot of trial and error.

I would just try to find where the script is looking for the header file.

Tim S.
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline Art in Music

  • Single posting newcomer
  • *
  • Posts: 7
Re: Using GTK+ with Code::Blocks
« Reply #8 on: February 07, 2014, 10:42:27 pm »
Thanks!

I got it to work by editing the three places where it mentioned the folder "gtk-2.0" to instead look for "gkt-3.0". I was able to find those three places using the CTR + F function. Then, when it gave me a different error, looking for "gtk-win32-2.0", which it said was a lib file, I went and looked for it in the *\lib for GTK, and found "gtk-win32-3.0" instead, so I changed the two places it mentioned that file in the script accordingly, and now it doesn't give me errors.

Thanks for the help,
Dylan