.cache-projects.mk is not installed / packaged, which makes builds against an installed jw-pkg considerably slower. Change that, at the risk of making the installed jw-pkg-devel less versatile. This commit installs a cache file cache-projects.mk, renamed from .cache-projects.mk, because there's no justification for hiding an installed makefile. At least I can't think of one.
This commit aims at improving speed by using better caching.
- Makefile, cache.mk: Split .cache.mk up
To allow caching of runtime path variables which are
project-specific, split .cache.mk up in .cache-project.mk and
.cache-projects.mk
- ldlibpath.mk: Cache ldlibpath, exepath and pythonpath
Place the output of $(call proj_query ldlibpath), $(call
proj_query, exepath) and $(call proj_query pythonpath) in
JW_PKG_LD_LIBRARY_PATH, JW_PKG_EXE_PATH, and JW_PKG_PYTHON_PATH
respectively, and cache the variables in make/.project-cache.mk.
- cache.mk: Use = instead of :=
Recursively expanded variables are nearly as fast as := variables
if the assigned value is a fixed string. And sometimes it's not,
rightly so, because variables get assigned below, as with
JW_PKG_XXX for instance.
- cache.mk: Use $(TOPDIR) as variable values
Replace absolute references to project's topdir by $(TOPDIR) with
sed. As soon as the project queries produce absolute paths, they
will be transformed into relative paths which allow the code base
to be moved to a different location and still remain functional
without a rebuild.
Change $(check_scm_sync) from "make git pull" to "make git-pull-maintainer", which most notably should delegate devops builds to the maintainer defined in project.conf.
PACKAGE_VCS_FILES defaults to false. Defining it to true before including rpmdist.mk includes the version-control metadata files in the source packages.
make rpm-build sometimes fails because RPM_VERSION is taken from .cache.mk. Not sure if this commit always resolves that entirely, but it mitigates the problem.
wd-upload doesn\'t work at all, because it clashed with rpmdist.mk defining stuff used by the upload-*.mk files. The RPM-side of things is left untested.
Generating the $(TOPDIR)/HASH file produced a warning for every package file containing a whitespace character. Hopefully, this build fixes the problem, by working on zero-delimited lists of file names
This target runs ssh -l root $(TARGET_HOST), with TARGET_HOST typically defined in $(MODDIR)/make/local.mk. Seems a bit out-of-place, everything, but anyway.
Since the packaging machinery is pretty complicated, the information about conflicting packages had to be passed through many APIs. The last commit contained a patch which is left in the tree to have it in one file, it actually is identical to this commit's diff, though. Git would save me that quirk.
Add --dont-strip-revision option to projects.py pkg-requires
Sadly, Debian dpkg doesn't install a package with dependency somepkg = 1.2.3, if somepkg-1.2.3-10 is installed. To work around this, VERSION in project.conf files is now always interpreted as VERSION-REVISION