holtrop / rscons Goto Github PK
View Code? Open in Web Editor NEWOpen source redistributable build system inspired by SCons and waf
License: MIT License
Open source redistributable build system inspired by SCons and waf
License: MIT License
This could be useful for builders that take directories as target paths.
Currently dependencies are generated for C and C++ but not for D.
Currently, env.build_after("${my_path}/target", "source") will not work because ${my_path} does not get expanded.
And possibly multi-process-safe also, depending on the performance hit.
The problem arises if the user does:
env.Program("program", "${sources}")
and "${sources}" expands to an Array.
Allow the user to instantiate an instance of the Command builder and override the builder name and short echo string.
To aid in compatibility with some toolsets which hard-code a dependency file name, add a construction variable (perhaps CCDEPGENSUFFIX) to allow overriding the dependency file suffix.
waf can be distributed with a project by versioning a single python script with the project without needing the user to install anything other than python. Update rscons to support distribution similarly, as a single ruby script.
It can be useful to conditionally execute a command which does not produce an output file based on the Cache information.
The Preprocess builder needs to be reworked to get deep dependencies from the compiler similar to how the Object builder does.
Right now if Cache#mkdir_p is given a path that begins with a "/", a not so useful error "No such file or directory" is given
It should return the stdout of the executed command.
An explicit user dependency should also imply an explicit build ordering.
It should operate similarly to Hash#values_at
RubyGems.org doesn't report a license for your gem. This is because it is not specified in the gemspec of your last release.
via e.g.
spec.license = 'MIT'
# or
spec.licenses = ['MIT', 'GPL-2']
Including a license in your gemspec is an easy way for rubygems.org and other tools to check how your gem is licensed. As you can image, scanning your repository for a LICENSE file or parsing the README, and then attempting to identify the license or licenses is much more difficult and more error prone. So, even for projects that already specify a license, including a license in your gemspec is a good practice. See, for example, how rubygems.org uses the gemspec to display the rails gem license.
There is even a License Finder gem to help companies/individuals ensure all gems they use meet their licensing needs. This tool depends on license information being available in the gemspec. This is an important enough issue that even Bundler now generates gems with a default 'MIT' license.
I hope you'll consider specifying a license in your gemspec. If not, please just close the issue with a nice message. In either case, I'll follow up. Thanks for your time!
Appendix:
If you need help choosing a license (sorry, I haven't checked your readme or looked for a license file), GitHub has created a license picker tool. Code without a license specified defaults to 'All rights reserved'-- denying others all rights to use of the code.
Here's a list of the license names I've found and their frequencies
p.s. In case you're wondering how I found you and why I made this issue, it's because I'm collecting stats on gems (I was originally looking for download data) and decided to collect license metadata,too, and make issues for gemspecs not specifying a license as a public service :). See the previous link or my blog post aobut this project for more information.
Colorize build messages and error messages. Perhaps include a job count to indicate some level of progress through the build.
If a command could otherwise be used with the Command builder except that it sends the desired output to standard output instead of taking an output filename, this functionality should be supported by the Command builder.
Investigate ways to speed it up.
When cloning an Environment, the original Environment's n_threads attribute should be cloned as well.
scons has a configure facility and while rake has some, it fails completely on C++ building for example the gem rwx attempts to configure stuff with C++ and has issues with rake.
When authoring a builder it can sometimes be helpful to see why cache.up_to_date? is returning false. Add support to debug a builder to see why cache.up_to_date? is returning false.
a command like 'rscons VAR=val' could be used to set a variable VAR in a global VarSet that could be used from within the Rsconsfile
A couple projects I've seen have registered a build target that must be built before all remaining build targets. Rather than requiring the user to add the first target as a user dependency for every remaining build target, the concept of a "barrier" could be added that separates build targets defined before the barrier from those defined afterwards. Rscons would then build everything before the barrier before building everything after the barrier. This would prevent rscons from parallelizing build tasks across the barrier.
The Program builder does not currently allow overriding the PROGSUFFIX in the varset or using a different suffix variable in the target name.
Below are two examples of the issue for illustration. The target was intended to use the SOSUFFIX in order to produce a .so file on linux and a .dll on windows automatically. The following two examples should have worked but did not:
env["SOSUFFIX"] = ".dll"
env.Program("${artifacts_path}/coverage_dll${SOSUFFIX}", env["sources"])
# produces =>
LD Build/artifacts/coverage_dll_base/coverage_dll.dll.exe
env["SOSUFFIX"] = ".dll"
env.Program("${artifacts_path}/coverage_dll", env["sources"], {'PROGSUFFIX' => '${SOSUFFIX}'})
# produces =>
LD Build/artifacts/coverage_dll_base/coverage_dll.exe
We were able to work around the issue with the following two examples:
env["SOSUFFIX"] = ".dll"
env["PROGSUFFIX"] = '${SOSUFFIX}'
env.Program("${artifacts_path}/coverage_dll", env["sources"])
# produces =>
LD Build/artifacts/coverage_dll_base/coverage_dll.dll
env["SOSUFFIX"] = "dll"
env.Program("${artifacts_path}/coverage_dll.${SOSUFFIX}", env["sources"])
# produces =>
LD Build/artifacts/coverage_dll_base/coverage_dll.dll
A pure Ruby builder will not have an actual "command" but may have a longer string to print for its run message. Allow the command parameter to be a String.
Similar to SCons' ParseFlags(), be able to parse the output of programs like pkg-config and freetype-config into the appropriate construction variables.
Dir[pattern] can return results in a different order based on platform or filesystem ordering. Add Rscons.glob to return a consistent listing and clean any paths.
The binary would be an optional way to invoke rscons if one was not using rake. Perhaps simply executing a "Rsconsfile" with the "rscons" library already required.
For "new" style builders, modifications made to the build operation within the hook will retain changes when the modification results in replacement of a key's values.
"Old" style builders will not respect such a change when the value is replaced, only if the value is modified in place. The old-style builders should act similarly to the new-style.
Currently on a builder failure, rscons will immediately exit and will not wait for other already-started builders to complete. Change to print an error immediately on builder failure, but wait to terminate the Ruby process until other parallelized background subprocesses have returned.
Using env.build_after can enforce multi-threaded build ordering, but multiple env.build_after calls might be needed if they use the same side-effect file produced by another builder. Instead, provide functionality to record that a build operation produces the side-effect file without needing to call env.build_after for other build operations that use that file as a source.
If a build root is defined for an Environment and an absolute source path is provided, instead of placing the object file next to the source, place it under the build root.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.