Age | Commit message (Collapse) | Author |
|
|
|
|
|
Stub away this function for now, until we need to support multilib translations.
RPM-land does ML differently anyway.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Don't forget to pass EXTRA_OEMAKE to make in base_do_compile.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Instead of cleaning the data in two different ways at two different times which
leads to bugs (e.g. PATH no longer contains the native sysroot), have an
original data (od) and a cleaned data (d).
Also improve variable cleaning, correctly setting S, B, and WORKDIR.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Not all patches uses striplevel=1. We must remember the parameter and
later use it when generating the patch command.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
This shows the parameters of a license hook and also implements the
transformation needed for Tizen. The advantage of defining it here,
besides serving as example, is that no separate class is needed for it
(a distro conf cannot contain a Python function).
Example usage in a distro conf:
RPM_LICENSE_HOOK = "license_to_tizen"
Optionally also map PD, which is not valid in Tizen at the moment:
SPDXLICENSEMAP[PD] = "ISC"
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
The exact format of the License field depends on the target
distro. Allow transforming the string from .bb via a custom
hook function.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Now only "1" enables the feature, everything else disables it.
Previously, setting values like "false" enabled the feature.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Tizen requires all packages to be in the same group, the one
configured for the PN package. SRPM_SAME_GROUP must be set to 1
to enable this; any other value disables it.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Some rewrites are done automatically and unconditionally when a
package is not listed explicitly in SRPM_REWRITE_DEPENDS: the suffix
-native is stripped (because such a dependency is for a tool to be
run, not something to be linked against), otherwise the -dev suffix is
appended (otherwise, in contrast to bitbake, the development files
would not get installed because they are packaged separately).
Appending -dev may lead to installing too many files when the real
dependency is on the base package, but because that typically gets
installed, too, the build will still succeed.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
The translator cannot know whether a certain package will contain
shared libraries because it does not actually build the packages.
This information must be provided by setting the new SRPM_IS_LIB to
a space separated list of packages.
Example for usage in a distro config:
SRPM_IS_LIB_pn-popt = "${PN}"
SRPM_IS_LIB_pn-xz = "liblzma"
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Avoid duplicate "Requires: python" when python already is a
dependency by de-duplicating the dependencies. May also help
when mapping dependencies (not sure, not seen in practice yet).
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
When adding "python" as build dependency, also insert space to
avoid appending it to the last existing dependency.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
This is merely a cosmetic change which makes the .spec files shorter.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
SRPM_RENAME is a space-separated list of <regex>=<replacement string>
pairs. Each replacement is applied to package names with
re.sub(). The entire name must match the regex (simplifies setting
SRPM_RENAME because there's no need to embed a $, and prevents
accidental matching of sub-strings).
Example usage in a distro conf:
SRPM_RENAME = "(.*)-dev=\1-devel"
SRPM_RENAME += "\
readline=libreadline \
gmp=libgmp \
"
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
The usage of %make_build was questionable (redundant smp flags?!) and
did not work in Tizen (no such macro?). Instead use the invocation
recommended for Tizen .spec files.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
When SRPM_DYNAMIC_FILE_LISTS is set, the .bb FILES and CONFIGFILES
semantic for packages is replicated in the .src.rpm, i.e. it is not
necessary to override FILES to match the installed files exactly.
To achieve this, the generated src.rpm contains a
file-list-generator.py that is called after the normal install with
information about the .bb FILES and CONFFILES values. The script then
generates file lists for the %files section, following the .bb
semantic.
|
|
|
|
|
|
Iterating over a dict made the output a bit random. Fixed by sorting
the lines before appending to the final array.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
This is a bit of a hacky fix but for now remove the revision from the archived
tarball. In the future, we need to expose this filename so the translator can
use it.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Accidently forgot to pass the arguments to make.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
These should expand to nothing as RPM builds don't run in a sysroot.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Do the variable fixups for RPM-land first thing, so that the revised values are
available everywhere.
This means that the file lists don't need to be munged to remove absolute paths,
so delete rpm_macrofy_files().
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Set all paths variables where there is a corresponding RPM macro (ie ${bindir}
and %{_bindir}) so macros get used instead of absolute paths.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Using %{buildroot} for D so that hand-coded do_install() functions work
correctly.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
By attempting to set a variable to ${EXTRA_OECONF} it ended up being expanded
when the function was evaluated, resulting in literal tabs appearing in the
source for recipes which use tabs in that variable. Split the variable name
into two strings so it doesn't get expanded.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
It's useful to be able to manipulate the spec file before it gets written, for
example to add tags that BitBake doesn't support directly.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
For example assuming that the configure step is as simple as %configure is wrong
as there may have been critial commands added using _append or _prepend.
Instead redefine the functions during output.
The output is sub-optimal but it will be cleaned up later.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
|
|
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
The attempt to clean up license names to use SPDX names was buggy (didn't handle
nested groups and logical or), and should be implemented by fixing the metadata
itself.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Some variables are interesting if they have a value, otherwise they're not (for
example, CPPFLAGS). Add a variable SRPM_MAYBE_EXPORT to list these variables.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
If a package requires it's own tools to be built when cross-compiling we end up
with the situation where PN depends on PN-native. When translating to spec
everything is native, so this isn't required, so remove these self-dependencies.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
The distro can disable -dbg package, so the translator doesn't need to.
This reverts commit d4c6477b8164ecb08a3c2c10c7087064b474d405.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
As the distro now removes PN-staticdev, and the file listings are part of the
distro too, there's no need to specially merge them.
This reverts commit dc60fb85828e6158300cdb02f993972c3b82ab0c.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
|
|
Remove BBFILES as meta-translator doesn't have any recipes.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
RPM is happy with either, but existing spec files tend to prefer capitalised
over upper-case.
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
If a subpackage doesn't have a summary or description, use the source
summary/description instead of ".".
Signed-off-by: Ross Burton <ross.burton@intel.com>
|
|
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|