| Commit message (Collapse) | Author | Age |
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch alters semantics of check_auto_buildable() a bit. Now it can
also indicate if the source has already been partitially built with the
build system and if so, such build system may be auto-selected over a less
specific its parent (in the inheritance tree) even if the latter is earlier
in the @BUILDSYSTEMS array.
However, this still leaves a requirement that a derivative build system
must not do anything that may break packages of the parent build system.
Otherwise, introduction of a new derivative build system might break
packages which already had that build system implemented via overrides...
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
|
|
|
| |
dpkg-buildpackage -j sets DEB_BUILD_OPTIONS=parallel=-1. Policy does not
cover this but the intent is to allow unlimited parallel jobs.
Also, there is no longer any way for parallel to be set to undef, so remove
code to handle that.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1) Add routine to Dh_Lib (used by dh and makefile.pm) which is capable of
detecting make jobserver and job control options from the MAKEFLAGS environment
variable. It also generates and returns a clean up MAKEFLAGS from these
options.
2) Add --parallel option to build system framework which allows source packages
to specify that they support parallel building. Optional value for this option is
the number of maximum parallel process to allow. However, the actual number of
parallel process (if any) for the specific build is determined from
DEB_BUILD_OPTIONS env variable as specified by Debian Policy.
By default (no --parallel option) parallel is neither enabled nor disabled
(depends on the external environment). However, dh may pass --parallel to
dh_auto_* implicitly in case 4) described below.
3) Add parallel support for makefile buildsystem. This implementation
forcefully starts a new make job server (or disables parallel) for the number
of process requested. If --parallel was not passed to the build system at all,
the build system will only clean up MAKEFLAGS from stale jobserver options to
avoid pointless make warnings.
4) If dh detects that it is being run by dpkg-buildpackage -jX and it is NOT
run with "+" prefix from debian/rules (i.e. jobserver is not reachable), it
enables --parallel implicitly. This closes: #532805.
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
|
|
|
| |
Pass --ignore-fail-on-non-empty option to shell rmddir and later
check with -d if the exists to get the same effect. Also drop
no act check from rmdir_builddir(), doit() does it for us now.
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
| |
It was only used by the test suite, and while symetrical I don't
feel that justifies keeping dead code.
|
| |
|
|
|
|
| |
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
|
|
|
| |
If build directory is absolute or ../ path, _rel2rel falls back to
absolute paths. Try even harder to convert supplied builddir to
relative in _set_builddir().
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
| |
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
|
|
|
| |
Also add enforce_out_of_source_building() for clarity which does not
take any parameters. Now both have a clear name and no confusing
parameter combinations.
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
| |
|
|
|
|
| |
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
|
|
|
| |
* buildsystem -> build system
* dh_auto build system -> debhelper build system
* plugin -> class
* a few rewording changes in the comments.
* Enhance python_distutils::DESCRIPTION().
|
| |
|
|
|
|
| |
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
| |
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
|
|
| |
Previous one caused test "_rel2rel no4" to fail. Also add a new test
for _canonpath and two new tests for _rel2rel (related to "." handling).
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
|
|
|
|
| |
Now build directory is always relative to the top directory
(including default build directory) regardless what source
directory is. However, if the build directory is not specified,
it defaults to the source directory (aka in source building).
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Auto-setting is_buildable flag in base constructor was pointless
and broken by design because:
- is_buildable = check_auto_buildable() used to be called *before*
constructor of the derivative class could call enforce_* methods. The
result of check_auto_buildable() might change after calling enforce_*
methods (in case check_auto_buildable() use get_buildpath() tests).
- it isn't used widely. Refactor those a few places.
* Due to above, 'build_step' does not need to be passed to the Buildsystem
anymore. Remove it from code.
* As a result of is_buidable removal, move warning of
enforce_in_source_building() to pre_building_step(). It caused unnecessary
noise when the object was constructed during test. It belongs to
pre_building_step stage anyway.
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Move setting of new build directory from constructor to _set_builddir()
method including detection if directory (current or source) it should be
relative to.
* Even if a new build directory was specified, detect if it matches the source
directory and unset it in such a case.
* Use _set_builddir() in enforce_out_of_source_tree() methods. Previous
implementation didn't handle default build directory properly (i.e.
relativeness to current or source directory).
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
|
|
| |
When rmdir_building(), if build directory has 2 or more levels,
empty parent dirs should also be deleted until source directory level.
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
| |
Signed-off-by: Modestas Vainius <modestas@vainius.eu>
|
|
|
|
|
|
|
|
| |
* New optional option --sourcedirectory/-d.
* New Buildsystem API methods for getting source directory/path
(since sourcedir may no longer be topdir), source 2 build
directory convertions, doit_in_sourcedir() etc.
* clean_builddir() -> rmdir_builddir() rename.
|
|
|
|
|
|
| |
* "out of source" or "out of source tree" seems to be more popular
term to describe building in the builddir.
* Avoid using hyphens in both "out of source" and "in source" terms.
|
|
|
|
|
| |
I'm going to use this new term in documentation. I have never liked "action"
in this context, just couldn't think of anything better.
|
| |
|
|
This way the root of the class hierarchy has the same name as the directory
holding the classes.
|