Code::Blocks Forums
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email
?
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News:
As usual while waiting for the next release - don't forget to check the
nightly builds
in the forum.
Home
Help
Search
Login
Register
Code::Blocks Forums
»
User forums
»
Using Code::Blocks
»
Build must copy a complete directory tree stucture from "src" to "bin"
« previous
next »
Send this topic
Print
Pages: [
1
]
Go Down
Author
Topic: Build must copy a complete directory tree stucture from "src" to "bin" (Read 4359 times)
chameleon
Multiple posting newcomer
Posts: 40
Build must copy a complete directory tree stucture from "src" to "bin"
«
on:
April 06, 2012, 08:51:08 pm »
Hi guys.
I check the structure of CBP file and I realize that can be cross-platform.
I work with OpenCL which has many compile-at-runtime text files.
I want these files in my source "src/opencl/" directory.
I add these files as "Others" in my CBP project.
But there is no copy operation to target "bin" directory.
So I want "Other" files in my project:
- Copy from source "src" to target "bin" directory with the same structure "src/opencl/matrix.cl" -> "bin/opencl/matrix.cl"
- Copy only if newer.
- Copy with a cross-platform method. "copy %source_file %target_file" is not working on linux and "cp %source_file %target_file" is not working on windows.
How can I do this?
Regards
Pavlos Gessos.
Logged
oBFusCATed
Developer
Lives here!
Posts: 13406
Re: Build must copy a complete directory tree stucture from "src" to "bin"
«
Reply #1 on:
April 06, 2012, 08:57:12 pm »
1. Do as C::B does and shell script for linux and bat file for windows
2. Try a squirrel script in the post build steps, I think it is possible, but I've not tried it, ever
3. Use rsync
Logged
(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!]
chameleon
Multiple posting newcomer
Posts: 40
Re: Build must copy a complete directory tree stucture from "src" to "bin"
«
Reply #2 on:
April 07, 2012, 08:58:30 pm »
hm....
This is not so cross-platform approach.
My poor opinion:
Add an extra "compiler" in the list of supported compilers with name "Copy if newer".
Of course any other similar approach is ok.
Is ok to add a feature request? "Copy source to target if newer".
Logged
Send this topic
Print
Pages: [
1
]
Go Up
« previous
next »
Code::Blocks Forums
»
User forums
»
Using Code::Blocks
»
Build must copy a complete directory tree stucture from "src" to "bin"