xbps-src: New build-style qmake
This commit is contained in:
parent
38f9e6b34e
commit
1fdd815143
|
@ -596,6 +596,12 @@ be defined to set the allowed python versions to be built, i.e:
|
|||
- `slashpackage` For packages that use the /package hierarchy and package/compile to build,
|
||||
such as `daemontools` or any `djb` software.
|
||||
|
||||
- `qmake` For packages that use Qt4/Qt5 qmake profiles (`*.pro`), qmake arguments
|
||||
for the configure phase can be passed in via `configure_args`, make build arguments can
|
||||
be passed in via `make_build_args` and install arguments via `make_install_args`. The build
|
||||
target can be overridden via `make_build_target` and the install target
|
||||
via `make_install_target`.
|
||||
|
||||
> If `build_style` is not set, the template must (at least) define a
|
||||
`do_install()` function and optionally more phases via `do_xxx()` functions.
|
||||
|
||||
|
|
|
@ -0,0 +1,28 @@
|
|||
#
|
||||
# This helper is for templates using Qt4/Qt5 qmake.
|
||||
#
|
||||
do_configure() {
|
||||
: ${configure_script:=qmake}
|
||||
|
||||
if [ -n "$build_pie" ]; then
|
||||
${configure_script} ${configure_args} \
|
||||
QMAKE_LFLAGS_SHLIB+=" -Wl,-z,now" \
|
||||
QMAKE_LFLAGS_PLUGIN+=" -Wl,-z,now"
|
||||
else
|
||||
${configure_script} ${configure_args}
|
||||
fi
|
||||
}
|
||||
|
||||
do_build() {
|
||||
: ${make_cmd:=make}
|
||||
|
||||
${make_cmd} ${makejobs} ${make_build_args} ${make_build_target}
|
||||
}
|
||||
|
||||
do_install() {
|
||||
: ${make_cmd:=make}
|
||||
: ${make_install_target:=install}
|
||||
|
||||
${make_cmd} STRIP=true PREFIX=/usr DESTDIR=${DESTDIR} \
|
||||
INSTALL_ROOT=${DESTDIR}/usr ${make_install_args} ${make_install_target}
|
||||
}
|
Loading…
Reference in New Issue