From 2ca229ed7c817555b24ef3fdf312b058a04da605 Mon Sep 17 00:00:00 2001 From: R4SAS Date: Wed, 22 Mar 2023 02:51:22 +0300 Subject: [PATCH] [debian] switch to cmake Signed-off-by: R4SAS --- debian/control | 2 +- debian/copyright | 10 +++------- debian/i2pd.install | 2 +- debian/patches/01-upnp.patch | 17 ----------------- debian/patches/series | 1 - debian/rules | 12 +++++++++++- 6 files changed, 16 insertions(+), 28 deletions(-) delete mode 100644 debian/patches/01-upnp.patch delete mode 100644 debian/patches/series diff --git a/debian/control b/debian/control index 48f5e680..98ce52c3 100644 --- a/debian/control +++ b/debian/control @@ -2,7 +2,7 @@ Source: i2pd Section: net Priority: optional Maintainer: r4sas -Build-Depends: debhelper (>= 12~), libboost-system-dev (>= 1.46), libboost-date-time-dev (>= 1.46), libboost-filesystem-dev (>= 1.46), libboost-program-options-dev (>= 1.46), libminiupnpc-dev, libssl-dev, zlib1g-dev +Build-Depends: debhelper (>= 12~), cmake, libboost-system-dev (>= 1.46), libboost-date-time-dev (>= 1.46), libboost-filesystem-dev (>= 1.46), libboost-program-options-dev (>= 1.46), libminiupnpc-dev, libssl-dev, zlib1g-dev Standards-Version: 4.3.0 Homepage: http://i2pd.website/ Vcs-Git: git://github.com/PurpleI2P/i2pd.git diff --git a/debian/copyright b/debian/copyright index 352e260b..fe1c83a7 100644 --- a/debian/copyright +++ b/debian/copyright @@ -1,23 +1,19 @@ Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: i2pd -Source: https://github.com/PurpleI2P +Source: https://github.com/PurpleI2P/i2pd Files: * -Copyright: 2013-2023 PurpleI2P +Copyright: 2013-2023 The PurpleI2P Project License: BSD-3-clause Files: debian/* Copyright: 2013-2015 Kill Your TV 2014-2016 hagen 2016-2023 R4SAS - 2017-2020 Yangfl + 2017-2023 Yangfl License: GPL-2+ License: BSD-3-clause - Copyright (c) 2013-2023, The PurpleI2P Project - . - All rights reserved. - . Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: . diff --git a/debian/i2pd.install b/debian/i2pd.install index 93eee7a1..cdff3173 100644 --- a/debian/i2pd.install +++ b/debian/i2pd.install @@ -1,4 +1,4 @@ -i2pd usr/sbin/ +obj-*/i2pd usr/sbin/ contrib/i2pd.conf etc/i2pd/ contrib/tunnels.conf etc/i2pd/ contrib/certificates/ usr/share/i2pd/ diff --git a/debian/patches/01-upnp.patch b/debian/patches/01-upnp.patch deleted file mode 100644 index bec8f2b0..00000000 --- a/debian/patches/01-upnp.patch +++ /dev/null @@ -1,17 +0,0 @@ -Description: Enable UPnP usage in package -Author: r4sas - -Reviewed-By: r4sas -Last-Update: 2022-03-23 - ---- i2pd.orig/Makefile -+++ i2pd/Makefile -@@ -31,7 +31,7 @@ include filelist.mk - - USE_AESNI := $(or $(USE_AESNI),yes) - USE_STATIC := $(or $(USE_STATIC),no) --USE_UPNP := $(or $(USE_UPNP),no) -+USE_UPNP := $(or $(USE_UPNP),yes) - DEBUG := $(or $(DEBUG),yes) - - # for debugging purposes only, when commit hash needed in trunk builds in i2pd version string diff --git a/debian/patches/series b/debian/patches/series deleted file mode 100644 index f97fdf65..00000000 --- a/debian/patches/series +++ /dev/null @@ -1 +0,0 @@ -01-upnp.patch diff --git a/debian/rules b/debian/rules index fc769066..a76894da 100755 --- a/debian/rules +++ b/debian/rules @@ -8,6 +8,16 @@ export DEB_CXXFLAGS_MAINT_APPEND = -Wall -pedantic export DEB_LDFLAGS_MAINT_APPEND = %: - dh $@ + dh $@ --buildsystem=cmake + +override_dh_auto_clean: + dh_auto_clean --buildsystem=cmake --sourcedirectory=build/ + +override_dh_auto_configure: + dh_auto_configure --buildsystem=cmake --sourcedirectory=build/ -- \ + -DWITH_UPNP=ON + +override_dh_auto_build: + dh_auto_build --buildsystem=cmake override_dh_auto_install: