Author Topic: Feature Request Adding A particular directory to search compilers directories  (Read 7898 times)

Offline Hadomunt

  • Multiple posting newcomer
  • *
  • Posts: 11
The detection feature of Code::Blocks for compilers is very welcome.

Unfortunatelly when I used Qt SDK it didn't detect Mingw present in that location.

Thus, could you please add the following location to the locations where Code::Blocks searches for compilers?
C:\Qt\2010.04\mingw



Code::Blocks version:
Release 10.05 rev 6283 (2010-05-27 09:09:13) gcc 4.4.1 Windows/unicode - 32 bit



[attachment deleted by admin]
« Last Edit: July 04, 2010, 07:24:28 pm by Hadomunt »

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13406
    • Travis build status
Re: Feature Request Adding directory to search compilers
« Reply #1 on: June 30, 2010, 09:36:04 pm »
Why?
This is not the standard location or the mingw installation.
The detection is made, so 99% of the people have no problem with the installation/setup of CB and mingw,
and you are in the 1% of people that install custom compilers and you're supposed to know how to setup it.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline billyonthemountain

  • Multiple posting newcomer
  • *
  • Posts: 40
Re: Feature Request Adding directory to search compilers
« Reply #2 on: July 01, 2010, 03:11:52 pm »
Correct me if I'm wrong but Codeblocks should be able to detect the compiler if C:\Qt\2010.04\mingw is in your PATH. Binaries should have the form "mingw32-*" since you are on Windows.

But maybe it might time to start considering names and paths other than standard ones like :
  • c:\mingw{32|64}
  • x86_64-w64-mingw32-*

This is notably the case for those using the mingw64 compiler or TDM's GCC-tdm64...

with regards,

Billy

note: This might be an idea for the new compiler framework...
« Last Edit: July 01, 2010, 03:13:27 pm by billyonthemountain »
(ASM, C/C++)||(VISION&AI)||(EMBEDDED SYSTEMS)

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13406
    • Travis build status
Re: Feature Request Adding directory to search compilers
« Reply #3 on: July 01, 2010, 04:00:09 pm »
billyonthemountain: You propose that when C::B is started for the first time, it will do a search on the whole filesystem for known compilers?
Depending on the computer, this can take ages...
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7252
Re: Feature Request Adding directory to search compilers
« Reply #4 on: July 01, 2010, 05:35:53 pm »
And you can have multiple versions of MinGW in parallel, which one to use in this case ?

Offline billyonthemountain

  • Multiple posting newcomer
  • *
  • Posts: 40
Re: Feature Request Adding directory to search compilers
« Reply #5 on: July 01, 2010, 05:48:37 pm »
    billyonthemountain: You propose that when C::B is started for the first time, it will do a search on the whole filesystem for known compilers?
    No that would effectively be way too long. The idea is that the current compiler search directories (c:\mingw\bin, c:\mingw\mingw32\bin) might be extended with the following ones (when starting C::B for the 1st time or using the auto-detect feature) :
    • {${PATH}|C:}\mingw{..|32}\{bin|mingw32\bin} -> Mingw targeting 32bit
    • {${PATH}|C:}\mingw{..|64}\{bin|x86-64_mingw32\bin} -> Mingw targetting 64bit/Multilib
    Where Codeblocks would look for the following executables :
    • mingw32-{gcc|g++|make}.exe
    • x86-64_mingw32-{gcc|g++|make}.exe
    • {gdb|ar}.exe
    I'm using here a regular expression-like to keep it short; hope it's clear (".." : nothing, "|": OR)...[/list]
    « Last Edit: July 01, 2010, 05:59:07 pm by billyonthemountain »
    (ASM, C/C++)||(VISION&AI)||(EMBEDDED SYSTEMS)

    Offline billyonthemountain

    • Multiple posting newcomer
    • *
    • Posts: 40
    Re: Feature Request Adding directory to search compilers
    « Reply #6 on: July 01, 2010, 05:55:59 pm »
    And you can have multiple versions of MinGW in parallel, which one to use in this case ?

    Of course this is just a general idea. To keep it simple you could just stop searching as soon as there is a hit but a more "advanced" idea would be having C::B detect those multiple and use a template to add a compiler by detecting it's target.
    This could be interesting when you use two different compilers to target 32bit and 64bit...
    (ASM, C/C++)||(VISION&AI)||(EMBEDDED SYSTEMS)

    Offline Hadomunt

    • Multiple posting newcomer
    • *
    • Posts: 11
    Re: Feature Request Adding directory to search compilers
    « Reply #7 on: July 01, 2010, 08:36:39 pm »
    Why?
    This is not the standard location or the mingw installation.
    The detection is made, so 99% of the people have no problem with the installation/setup of CB and mingw,
    and you are in the 1% of people that install custom compilers and you're supposed to know how to setup it.

    Actually the path is the standard path for the QT SDK with Mingw integrated.
    Was installed this way because NetBeans howto's said something about how to do it that way.
    Anyway, this is NOT some niche, my-own-directory-structure thing.
    Probably a lot of people have Qt SDK installed with it's own Mingw.

    I'm asking this because Code::Blocks did NOT DETECTED the mingw compiler from the Qt SDK.
    After installing QT SDK with sTANDARD DIRECTORY STRUCTURE!

    Adding a few likely directory's won't hurt.

    About the search everything.
    Let there be an option to specify a directory and let C::B search in that directory and all subdirectories.
    This way If you aren't completely sure where it is you can use an upper directory.

    Multiple versions, C::B could present a list and choose the most recent one, or alphabetically or matching architecture.
    « Last Edit: July 01, 2010, 08:40:49 pm by Hadomunt »