Allow autospec to handle building packages that use a
Jinja2 formatted *.spec.template file. Currently only package_name,
package_version, package_release and package_url fields are supported
but others can be added as needed (patches and archives are good next
steps).
Signed-off-by: William Douglas <william.douglas@intel.com>
Add an options.conf flag for allowing builds to use mock's
--short-circuit for reducing rebuild time.
This change moves the feature from default enabling with no way to
turn off to default disable with a configure to turn on.
Signed-off-by: William Douglas <william.douglas@intel.com>
Once we know autospec is going to exit unsuccessfully, send out a
hopefully useful error from print_fatal or scan the build.log one last
time for useful data and add that content to an output file.
This is intended to only be done in update flows and the file should
be cleaned up prior to autospec being run again. Note that without a
special environment variable active nothing will be written out to the
file.
Signed-off-by: William Douglas <william.douglas@intel.com>
print_fatal calls need to be followed up by an exit consistently and
exit's need to use print_fatal before being called.
Signed-off-by: William Douglas <william.douglas@intel.com>
Add support for cargo_vendors which should be pretty much the output
of a 'cargo vendor' run. This will be appended to any existing
.cargo/config.toml file in the sources. It is intended to mostly come
from the vendor.py in common but useful for other builds as well which
don't need to enable cargo_vendor in options.conf.
Signed-off-by: William Douglas <william.douglas@intel.com>
Things should be autoupdating by default for new content at this point
as being held back for no reason isn't helpful.
Signed-off-by: William Douglas <william.douglas@intel.com>
This patch has a few interrelated changes in it but primarily it is
supporting a new copy_prepend configuration file for autospec. This is
intended to support cases where changes should be made to the source
directory prior to the source directory being copied for different
builds (avx2, 32bit, etc).
Also with this change some tweaks to how cmake builds are handled to
be more aligned with other build systems. Primarily that the source
directoy is now fully copied rather than just creating a cmake build
directory per build in the same source directory.
Finally check support has been updated to account for the new path and
update support for meson and apx.
Signed-off-by: William Douglas <william.douglas@intel.com>
Given more packages are using ninja as the build system of choice
instead of make, add flag to enable ninja usage.
Signed-off-by: William Douglas <william.douglas@intel.com>
This caused some incorrect behavior for numpy. Generally disabling to
avoid problematic behavior.
Signed-off-by: William Douglas <william.douglas@intel.com>
gpg accepts signatures with expired keys as long as the signature was
made prior to key expiration. But it also changes the status-fd output
format that we grep for the expected key ID. Make sure we look for the
alternate EXPKEYSIG line in the output in that case to find the key ID.
Add gpg commands to the specfile so we verify the package signature
during every rpmbuild. Also ensure that the signature key ID matches
what we expect.
Implement a blocklist, keyid_blocklist. If a keyid (without leading 0x)
in this file matches the signing key for a release, terminate autospec
with an error.
This is intended as a mechanism to block building releases signed with a
known compromised key.
When a package has content in /etc, it is removed silently, this
change adds an etc_files log file in git that shows what files were in
/etc that weren't packaged.
Signed-off-by: William Douglas <william.douglas@intel.com>
Previously support for cmake's find_package parsing was only able to
handle single line entries. This change adds support for multiline
versions and allows for module namespacing (currently qt6 and kf6
support is available).
The change for cmake_modules shows this namespacing in use.
Signed-off-by: William Douglas <william.douglas@intel.com>
Partial migration of patterns to qt6 for failed_commands and
qt_modules. Still more changes needed here but this is a start.
Signed-off-by: William Douglas <william.douglas@intel.com>
Rather than using %qmake, add the definition into autospec. This is
done to allow for using make_command to specify which version of qmake
to use.
Note for now qmake6 is not in PATH and needs a build_prepend addition.
Signed-off-by: William Douglas <william.douglas@intel.com>
Some projects require additional bz2 downloads that are single
compressed files, not tar archives. Detect and extract those with
appropriate bz2 tools instead of tar.
For a given entry like this:
ARCHIVES = https://example.com/download/foo.dat.bz2 src/data
...upstream file is downloaded to:
builddir/build/SOURCES/foo.dat.bz2
...initially extracted as:
builddir/build/BUILD/foo.dat/foo.dat
...and finally copied to
builddir/build/BUILD/<pkg>/src/data/foo.dat
Add export for GOAMD64 and modify where needed in order to support
building optimized binaries using golang.
Signed-off-by: William Douglas <william.douglas@intel.com>
Support APX package builds using the configure patterns (needed to
handle cross compilation via --host option).
Also fixup some flag usage inconsistencies.
Signed-off-by: William Douglas <william.douglas@intel.com>
Add early support for APX builds in autospec. This change also makes
APX disabled by default for now but may revert back to enabled by
default in the future. The APX prefix will be /VA as the arch flag is
not yet finalized. This also may change in the future though for now
there are no plans to move it.
Currently autotools builds are unable to use this as it detects as a
cross compilation.
Currently only C using GCC is supported.
This change also reworks how R language optimized binaries are built
and distributed. They will now work as all the other tooling does with
the /VX prefix.
Signed-off-by: William Douglas <william.douglas@intel.com>
Instead of hard coding flags in each use, add global constants that
are substituted on use (removes a little copypasta and fixes up some
flags that were unintentionally different between build systems).
Signed-off-by: William Douglas <william.douglas@intel.com>
Some packages, especially PIP wheels, install Windows executables.
Introduce an option, allow_exe, with which to permit installing those
executables. Otherwise, explicitly delete them so they're not
inadvertently installed via wildcards later.