From: Jakub Ružička Date: Thu, 19 Sep 2024 14:05:44 +0000 (+0200) Subject: distro/pkg: update packaging for single python module X-Git-Tag: v6.0.9~9^2~3 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=101248e7b43e5322b33eea2d49cc50a3b4a6bd36;p=thirdparty%2Fknot-resolver.git distro/pkg: update packaging for single python module --- diff --git a/distro/pkg/arch/PKGBUILD b/distro/pkg/arch/PKGBUILD index 6f473ca55..ebbd164d1 100644 --- a/distro/pkg/arch/PKGBUILD +++ b/distro/pkg/arch/PKGBUILD @@ -63,9 +63,6 @@ build() { -D malloc=jemalloc \ -D unit_tests=enabled ninja -C build - pushd build/python - python -Pm build --wheel --no-isolation - popd python -Pm build --wheel --no-isolation } @@ -85,13 +82,8 @@ package() { # remove modules with missing dependencies rm "${pkgdir}/usr/lib/knot-resolver/kres_modules/etcd.lua" - # install knot-resolver metadata Python module - pushd build/python + # install knot-resolver Python module python -Pm installer --destdir="$pkgdir" dist/*.whl - popd - # install knot-resolver-manager - python -Pm installer --destdir="$pkgdir" dist/*.whl install -m 644 -D etc/config/config.yaml ${pkgdir}/etc/knot-resolver/config.yaml - } diff --git a/distro/pkg/deb/rules b/distro/pkg/deb/rules index a682d79b1..66c71c3ee 100755 --- a/distro/pkg/deb/rules +++ b/distro/pkg/deb/rules @@ -35,17 +35,11 @@ override_dh_auto_build: -Dc_args="$${CFLAGS}" \ -Dc_link_args="$${LDFLAGS}" ninja -v -C build_deb - PYBUILD_NAME=knot_resolver PYBUILD_DESTDIR="$${PYKRES_DESTDIR}" \ - dh_auto_build --buildsystem=pybuild - PYBUILD_NAME=knot_resolver_build_options PYBUILD_DESTDIR="$${PYKRES_DESTDIR}" \ - dh_auto_build --buildsystem=pybuild --sourcedirectory build_deb/python + PYBUILD_NAME=knot_resolver PYBUILD_DESTDIR="$${PYKRES_DESTDIR}" dh_auto_build override_dh_auto_install: DESTDIR="$(shell pwd)/debian/tmp" ninja -v -C build_deb install - PYBUILD_NAME=knot_resolver PYBUILD_DESTDIR="$${PYKRES_DESTDIR}" \ - dh_auto_install --buildsystem=pybuild - PYBUILD_NAME=knot_resolver_build_options PYBUILD_DESTDIR="$${PYKRES_DESTDIR}" \ - dh_auto_install --buildsystem=pybuild --sourcedirectory build_deb/python + PYBUILD_NAME=knot_resolver PYBUILD_DESTDIR="$${PYKRES_DESTDIR}" dh_auto_install install -m 644 -D etc/config/config.yaml debian/tmp/etc/knot-resolver/config.yaml override_dh_auto_test: diff --git a/distro/pkg/rpm/knot-resolver.spec b/distro/pkg/rpm/knot-resolver.spec index d1ec860c2..ca8602ffd 100644 --- a/distro/pkg/rpm/knot-resolver.spec +++ b/distro/pkg/rpm/knot-resolver.spec @@ -181,10 +181,6 @@ CFLAGS="%{optflags}" LDFLAGS="%{?__global_ldflags}" meson build_rpm \ %{NINJA} -v -C build_rpm -pushd build_rpm/python -%py3_build -popd - %py3_build %install @@ -216,11 +212,6 @@ mv %{buildroot}/%{_datadir}/doc/%{name}/* %{buildroot}/%{_pkgdocdir}/ # install knot_resolver python module %py3_install -# install knot_resolver_build_options python module -pushd build_rpm/python -%py3_install -popd - install -m 644 -D etc/config/config.yaml %{buildroot}%{_sysconfdir}/knot-resolver/config.yaml %pre @@ -301,14 +292,7 @@ getent passwd knot-resolver >/dev/null || useradd -r -g knot-resolver -d %{_sysc %{_libdir}/knot-resolver/kres_modules/view.lua %{_libdir}/knot-resolver/kres_modules/watchdog.lua %{_libdir}/knot-resolver/kres_modules/workarounds.lua -%{python3_sitelib}/knot_resolver_build_options.py -%{python3_sitelib}/knot_resolver_build_options-* %{python3_sitearch}/knot_resolver* -%if 0%{?suse_version} -%pycache_only %{python3_sitelib}/__pycache__/knot_resolver_build_options.* -%else -%{python3_sitelib}/__pycache__/knot_resolver_build_options.* -%endif %{_mandir}/man8/kresd.8.gz %{_mandir}/man8/kresctl.8.gz