New "Clean Project" behaviour in v7 causes problems
-
- CodeLite Enthusiast
- Posts: 45
- Joined: Tue Jan 28, 2014 3:03 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
New "Clean Project" behaviour in v7 causes problems
Hi there-
current 'clean project' behaviour in v7 means that anything in the debug/release folder gets wiped, including any .dll files that've been put in there to let the code run, such as SDL2.dll, or others.
This is crazily-annoying, as the debug .dll for most libraries is different to the release .dll, so they need to stay in their respective folders - without being wiped.
In other words, after every 'clean' I have to copy all the .dll files back again.
current 'clean project' behaviour in v7 means that anything in the debug/release folder gets wiped, including any .dll files that've been put in there to let the code run, such as SDL2.dll, or others.
This is crazily-annoying, as the debug .dll for most libraries is different to the release .dll, so they need to stay in their respective folders - without being wiped.
In other words, after every 'clean' I have to copy all the .dll files back again.
- eranif
- CodeLite Plugin
- Posts: 6375
- Joined: Wed Feb 06, 2008 9:29 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: New "Clean Project" behaviour in v7 causes problems
You should not place anything in the intermediate folder (hence the name).
A simple solution will be to:
* set the output file to a different location project settings->common settings->general->output file and place your DLLs there
* Add a post build command to copy the output file from the default location to another location
Eran
A simple solution will be to:
* set the output file to a different location project settings->common settings->general->output file and place your DLLs there
* Add a post build command to copy the output file from the default location to another location
Eran
Make sure you have read the HOW TO POST thread
-
- CodeLite Enthusiast
- Posts: 45
- Joined: Tue Jan 28, 2014 3:03 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: New "Clean Project" behaviour in v7 causes problems
Why go to all that effort? This is a really common scenario. It's not something that should be hacked around, as it's the more common case, not the less common one.eranif wrote:You should not place anything in the intermediate folder (hence the name).
A simple solution will be to:
* set the output file to a different location project settings->common settings->general->output file and place your DLLs there
* Add a post build command to copy the output file from the default location to another location
Eran
Previous versions of codelite only deleted actual generated files, not files which weren't generated by codelite.
-
- CodeLite Expert
- Posts: 167
- Joined: Fri Jul 22, 2011 5:32 am
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: New "Clean Project" behaviour in v7 causes problems
Looked,
did notice that my make file has
Notable since this project doesn't even create an exe file, creates a .elf instead. I can sort of see why one might just go for the rm *. instead of a list of objects.
Suggest opening a feature request.
Anyway not sure if moving the executable will be golden I seem to remember that last time I tried that gdb couldn't find it. (Might have been fixed).
If me was you, I'd create a small bat/sh file to copy the necessary libs into t the Debug Directory if not present. You can then add that to the pre or post build step under settings.
Other option is locate the outside libs elsewhere in the tree and configure the things so that your program can find them. I have no idea how to do that since I seldom use libraries.
did notice that my make file has
Code: Select all
-include $(IntermediateDirectory)/*$(DependSuffix)
##
## Clean
##
clean:
$(RM) ./Debug/*$(ObjectSuffix)
$(RM) ./Debug/*$(DependSuffix)
$(RM) $(OutputFile)
$(RM) $(OutputFile).exe
$(RM) "../.build-debug/repeater_v3"
Suggest opening a feature request.
Anyway not sure if moving the executable will be golden I seem to remember that last time I tried that gdb couldn't find it. (Might have been fixed).
If me was you, I'd create a small bat/sh file to copy the necessary libs into t the Debug Directory if not present. You can then add that to the pre or post build step under settings.
Other option is locate the outside libs elsewhere in the tree and configure the things so that your program can find them. I have no idea how to do that since I seldom use libraries.
- eranif
- CodeLite Plugin
- Posts: 6375
- Joined: Wed Feb 06, 2008 9:29 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: New "Clean Project" behaviour in v7 causes problems
There is no need to write batch scripts...Gibbon1 wrote:If me was you, I'd create a small bat/sh file to copy the necessary libs into t the Debug Directory if not present. You can then add that to the pre or post build step under settings.
Other option is locate the outside libs elsewhere in the tree and configure the things so that your program can find them. I have no idea how to do that since I seldom use libraries.
Here is an example post build command (taken from CodeLite's project):
Code: Select all
copy "$(IntermediateDirectory)\codelite-dbg.exe" ..\Runtime
The working directory is _always_ set to project being built
And to make Gdb locate it, update your project settings->common settings->general->Executable to Debug/Run
Eran
Make sure you have read the HOW TO POST thread
-
- CodeLite Enthusiast
- Posts: 45
- Joined: Tue Jan 28, 2014 3:03 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: New "Clean Project" behaviour in v7 causes problems
If you want to create a "temporary file" folder, where everything gets wiped, do it outside of the Debug and Release folders.
Wiping everything in those folders is unintuitive, unnecessary and a regression from previous versions.
Wiping everything in those folders is unintuitive, unnecessary and a regression from previous versions.
- eranif
- CodeLite Plugin
- Posts: 6375
- Joined: Wed Feb 06, 2008 9:29 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: New "Clean Project" behaviour in v7 causes problems
You are missing the point here. These are the temporary folders...metamorphosis wrote:If you want to create a "temporary file" folder, where everything gets wiped, do it outside of the Debug and Release folders.
Eran
Make sure you have read the HOW TO POST thread
-
- CodeLite Enthusiast
- Posts: 45
- Joined: Tue Jan 28, 2014 3:03 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: New "Clean Project" behaviour in v7 causes problems
Respectfully, I'm not... if you read above you'll understand why this is behaviour regression, and a waste of user's time. There is no need for it.
- eranif
- CodeLite Plugin
- Posts: 6375
- Joined: Wed Feb 06, 2008 9:29 pm
- Genuine User: Yes
- IDE Question: C++
- Contact:
Re: New "Clean Project" behaviour in v7 causes problems
Lets agree to disagree here.
The solution for this is simple: you can make this configurable
A pull request is most welcome here
Eran
The solution for this is simple: you can make this configurable
A pull request is most welcome here
Eran
Make sure you have read the HOW TO POST thread