summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-games/tiled/tiled-1.9.2.ebuild')
-rw-r--r--dev-games/tiled/tiled-1.9.2.ebuild50
1 files changed, 29 insertions, 21 deletions
diff --git a/dev-games/tiled/tiled-1.9.2.ebuild b/dev-games/tiled/tiled-1.9.2.ebuild
index 4c2cfd5..e32de30 100644
--- a/dev-games/tiled/tiled-1.9.2.ebuild
+++ b/dev-games/tiled/tiled-1.9.2.ebuild
@@ -13,7 +13,7 @@ SRC_URI="https://github.com/bjorn/tiled/archive/v${PV}/${P}.tar.gz"
LICENSE="BSD BSD-2 GPL-2+"
SLOT="0"
KEYWORDS="~amd64"
-IUSE="examples python"
+IUSE="examples qt5 python"
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
@@ -38,34 +38,42 @@ BDEPEND="
DOCS=( AUTHORS COPYING NEWS.md README.md )
pkg_setup() {
- use python && python-single-r1_pkg_setup
- # Create a Qt5 profile for Qbs
- qbs setup-qt "$(qt5_get_bindir)/qmake" qt5
+ use qt5 && python && python-single-r1_pkg_setup
+}
+
+src_prepare() {
+ eapply "${FILESDIR}"/${PN}-1.9.2-set-plugin-path.patch
+ eapply_user
+
+ sed -e "s|__EBUILD_TILED_PLUGIN_DIR__|$(get_libdir)/tiled/plugins|g" -i src/libtiled/libtiled.qbs
}
src_configure() {
# Setup toolchains
qbs setup-toolchains --detect
- # The installdir is appended to installPrefix
- qbs build profile:qt5 \
- qbs.installPrefix:"/usr" \
- qbs.installDir:"$(get_libdir)" \
- qbs.install:true
- #SYSTEM_ZSTD="yes" \
- #DISABLE_PYTHON_PLUGIN="$(usex !python)" \
- #USE_FHS_PLUGIN_PATH="true"
+ # Create a Qt5 profile for Qbs
+ qbs setup-qt "$(qt5_get_bindir)/qmake" qt5
}
-src_install() {
- #emake INSTALL_ROOT="${D}" install
- qbs install --install-root="${D}" profile:qt5
-
- einstalldocs
+src_compile() {
+ # The installDir is appended to installPrefix
+ qbs build --no-install \
+ config:release \
+ profile:qt5 \
+ qbs.installDir:$(get_libdir) \
+ qbs.installPrefix:/usr
+}
- if use examples ; then
- docompress -x /usr/share/doc/${PF}/examples
- dodoc -r examples
- fi
+src_install() {
+ LIBDIR=$(get_libdir)
+ PREFIX="/usr"
+ qbs install -v --no-build \
+ config:release \
+ --install-root ${D} \
+ qbs.installDir:${LIBDIR} \
+ qbs.installPrefix:${PREFIX}
+ mkdir -p "${ED}${PREFIX}/${LIBDIR}"
+ mv -v "${ED}${PREFIX}"/lib/* "${ED}${PREFIX}"/"${LIBDIR}"/
}
pkg_postinst() {