Name libnghttp2-14
Description library implementing HTTP/2 protocol (shared library)
Version 1.64.0-1.1
Package Base nghttp2
Homepage https://nghttp2.org/
Maintainers ['Tomasz Buchert <tomasz@debian.org>']
Contributors ['Ondřej Surý <ondrej@debian.org>']
Distro-repo https://salsa.debian.org/debian/nghttp2
Sources ['https://sources.debian.org/data/main/n/nghttp2/1.64.0-1.1/debian/watch', 'https://sources.debian.org/src/nghttp2/1.64.0-1.1/debian/patches/0002-Workaround-for-963648.patch', 'https://sources.debian.org/src/nghttp2/1.64.0-1.1/debian/patches/0002-add-munit-explicitly.patch', 'https://sources.debian.org/src/nghttp2/1.64.0-1.1/debian/patches/lp-2104171-avoid-rubydomain-namespace.patch', 'https://sources.debian.org/src/nghttp2/1.64.0-1.1/debian/patches/series']
Dependencies ['libc6']
Optional-Dependencies []
Build-Dependencies ['debhelper', 'debhelper-compat', 'libc-ares-dev', 'libcunit1-dev <!nocheck>', 'libev-dev', 'libjansson-dev', 'libjemalloc-dev [!hurd-i386]', 'libssl-dev', 'libsystemd-dev', 'libxml2-dev', 'pkgconf', 'zlib1g-dev']
Provides []
Builddate
Architecture amd64
Distro-Version trixie
Licenses []
Hash 669cf255390473a9d85ccec07e84dc4f0c8df881327d203bddbecee1cafb107b
#!/usr/bin/make -f

# this makes the tests fail
# LDFLAGS += -Wl,--default-symver

override_dh_auto_configure:
	dh_auto_configure -- \
		--enable-python-bindings=no --disable-failmalloc --enable-app

override_dh_auto_build-arch:
	dh_auto_build

override_dh_auto_build-indep:
	$(MAKE) html

# don't run tests when building indep packages
override_dh_auto_test-indep:

override_dh_auto_clean:
	dh_auto_clean
	rm -rf doc/manual/html doc/manual/doctrees doc/apiref.rst

override_dh_auto_install-arch: custom_install_init_scripts custom_install_systemd
	dh_auto_install

override_dh_auto_install-indep: custom_install_manual

override_dh_installinit:
	dh_installinit -pnghttp2-proxy --onlyscripts --name=nghttpx --no-stop-on-upgrade --no-start

override_dh_installsystemd:
	dh_installsystemd --no-restart-after-upgrade --no-stop-on-upgrade --no-start

.PHONY: custom_install_manual custom_install_init_scripts custom_install_systemd

DOCDIR="debian/libnghttp2-doc/usr/share/doc/libnghttp2-doc"
custom_install_manual:
	mkdir -p $(DOCDIR)
	cp -pr doc/manual/html/* $(DOCDIR)
	rm $(DOCDIR)/objects.inv
	ln -sf /usr/share/javascript/jquery/jquery.js $(DOCDIR)/_static/jquery.js
	ln -sf /usr/share/javascript/underscore/underscore.js $(DOCDIR)/_static/underscore.js
	cp -p doc/README.rst $(DOCDIR)

ETCDIR="debian/nghttp2-proxy/etc"
custom_install_init_scripts:
	install -d $(ETCDIR)/init.d
	sed -e 's,^DAEMON=.*/,DAEMON=/usr/sbin/,' contrib/nghttpx-init > $(ETCDIR)/init.d/nghttpx
	chmod 755 $(ETCDIR)/init.d/nghttpx
	install -d $(ETCDIR)/nghttpx
	# we install our own version of config
	install -m644 debian/nghttpx.conf $(ETCDIR)/nghttpx/nghttpx.conf
	install -d $(ETCDIR)/logrotate.d
	install -p -m644 contrib/nghttpx-logrotate $(ETCDIR)/logrotate.d/nghttpx

# Currently we install our own systemd unit because
# the original one is slightly broken
custom_install_systemd:
	dh_installsystemd -pnghttp2-proxy --name nghttpx

%:
	dh $@