Code::Blocks Forums

Developer forums (C::B DEVELOPMENT STRICTLY!) => Development => Topic started by: Hadomunt on June 30, 2010, 04:10:27 pm

Title: Feature Request Adding A particular directory to search compilers directories
Post by: Hadomunt on June 30, 2010, 04:10:27 pm
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]
Title: Re: Feature Request Adding directory to search compilers
Post by: oBFusCATed 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.
Title: Re: Feature Request Adding directory to search compilers
Post by: billyonthemountain 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 :

This is notably the case for those using the mingw64 (http://mingw-w64.sourceforge.net/) compiler or TDM's GCC-tdm64 (http://tdm-gcc.tdragon.net)...

with regards,

Billy

note: This might be an idea for the new compiler framework...
Title: Re: Feature Request Adding directory to search compilers
Post by: oBFusCATed 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...
Title: Re: Feature Request Adding directory to search compilers
Post by: Jenna 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 ?
Title: Re: Feature Request Adding directory to search compilers
Post by: billyonthemountain 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) :
Where Codeblocks would look for the following executables :
I'm using here a regular expression-like to keep it short; hope it's clear (".." : nothing, "|": OR)...[/list]
Title: Re: Feature Request Adding directory to search compilers
Post by: billyonthemountain 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...
Title: Re: Feature Request Adding directory to search compilers
Post by: Hadomunt 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.