diff --git a/Makefile.am b/Makefile.am index 32e157e4..647f35e7 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,258 +1,189 @@ # # Copyright (C) 2010-2017 Red Hat, Inc. All rights reserved. # # Author: Fabio M. Di Nitto # # This software licensed under GPL-2.0+, LGPL-2.0+ # MAINTAINERCLEANFILES = Makefile.in aclocal.m4 configure depcomp \ config.guess config.sub missing install-sh \ ltmain.sh compile config.h.in config.h.in~ \ autoscan.log configure.scan test-driver include $(top_srcdir)/build-aux/check.mk AUTOMAKE_OPTIONS = foreign AM_DISTCHECK_CONFIGURE_FLAGS = --enable-kronosnetd ACLOCAL_AMFLAGS = -I m4 SPEC = $(PACKAGE_NAME).spec -DEBCHANGELOG = debian/changelog -DEBPOSTINST = debian/kronosnetd.postinst - TARGZFILE = $(PACKAGE_NAME)-$(VERSION).tar.gz EXTRA_DIST = build-aux autogen.sh .version \ - debian $(DEBCHANGELOG) $(DEBPOSTINST) \ $(SPEC) $(SPEC).in SUBDIRS = init libtap libknet kronosnetd if BUILD_DOCS SUBDIRS += docs endif if BUILD_POC SUBDIRS += poc-code endif dist_doc_DATA = \ COPYING.applications \ COPYING.libraries \ COPYRIGHT \ README.licence \ README \ TODO -all-local: $(SPEC) $(DEBCHANGELOG) $(DEBPOSTINST) +all-local: $(SPEC) clean-local: rm -f $(SPEC) - rm -f $(DEBPOSTINST) distclean-local: rm -f $(PACKAGE_NAME)-*.tar.* $(PACKAGE_NAME)-*.sha256* tag-* maintainer-clean-local: - make -f debian/rules clean || true - rm -rf m4 $(DEBCHANGELOG) $(DEBPOSTINST) debian/patches + rm -rf m4 ## make rpm/srpm section. $(SPEC): $(SPEC).in .version config.status rm -f $@-t $@ date="`LC_ALL=C date "+%a %b %d %Y"`" && \ if [ -f .tarball-version ]; then \ gitver="`cat .tarball-version`" && \ rpmver=$$gitver && \ alphatag="" && \ dirty="" && \ numcomm="0"; \ else \ gitver="`GIT_DIR=$(abs_srcdir)/.git git describe --abbrev=4 --match='v*' HEAD 2>/dev/null`" && \ rpmver=`echo $$gitver | sed -e "s/^v//" -e "s/-.*//g"` && \ alphatag=`echo $$gitver | sed -e "s/.*-//" -e "s/^g//"` && \ vtag=`echo $$gitver | sed -e "s/-.*//g"` && \ numcomm=`GIT_DIR=$(abs_srcdir)/.git git rev-list $$vtag..HEAD | wc -l` && \ GIT_DIR=$(abs_srcdir)/.git git update-index --refresh > /dev/null 2>&1 || true && \ dirty=`GIT_DIR=$(abs_srcdir)/.git git diff-index --name-only HEAD 2>/dev/null`; \ fi && \ if [ -n "$$dirty" ]; then dirty="dirty"; else dirty=""; fi && \ if [ "$$numcomm" = "0" ]; then \ sed \ -e "s#@version@#$$rpmver#g" \ -e "s#%glo.*alpha.*##g" \ -e "s#%glo.*numcomm.*##g" \ -e "s#@dirty@#$$dirty#g" \ -e "s#@date@#$$date#g" \ $(abs_srcdir)/$@.in > $@-t; \ else \ sed \ -e "s#@version@#$$rpmver#g" \ -e "s#@alphatag@#$$alphatag#g" \ -e "s#@numcomm@#$$numcomm#g" \ -e "s#@dirty@#$$dirty#g" \ -e "s#@date@#$$date#g" \ $(abs_srcdir)/$@.in > $@-t; \ fi; \ if [ -z "$$dirty" ]; then sed -i -e "s#%glo.*dirty.*##g" $@-t; fi if BUILDSCTP sed -i -e "s#@sctp@#bcond_without#g" $@-t else sed -i -e "s#@sctp@#bcond_with#g" $@-t endif if BUILDCRYPTONSS sed -i -e "s#@nss@#bcond_without#g" $@-t else sed -i -e "s#@nss@#bcond_with#g" $@-t endif if BUILDCRYPTOOPENSSL sed -i -e "s#@openssl@#bcond_without#g" $@-t else sed -i -e "s#@openssl@#bcond_with#g" $@-t endif if BUILDCOMPZLIB sed -i -e "s#@zlib@#bcond_without#g" $@-t else sed -i -e "s#@zlib@#bcond_with#g" $@-t endif if BUILDCOMPLZ4 sed -i -e "s#@lz4@#bcond_without#g" $@-t else sed -i -e "s#@lz4@#bcond_with#g" $@-t endif if BUILDCOMPLZO2 sed -i -e "s#@lzo2@#bcond_without#g" $@-t else sed -i -e "s#@lzo2@#bcond_with#g" $@-t endif if BUILDCOMPLZMA sed -i -e "s#@lzma@#bcond_without#g" $@-t else sed -i -e "s#@lzma@#bcond_with#g" $@-t endif if BUILDCOMPBZIP2 sed -i -e "s#@bzip2@#bcond_without#g" $@-t else sed -i -e "s#@bzip2@#bcond_with#g" $@-t endif if BUILD_KRONOSNETD sed -i -e "s#@kronosnetd@#bcond_without#g" $@-t else sed -i -e "s#@kronosnetd@#bcond_with#g" $@-t endif if BUILD_LIBTAP sed -i -e "s#@libtap@#bcond_without#g" $@-t else sed -i -e "s#@libtap@#bcond_with#g" $@-t endif if BUILD_RUNAUTOGEN sed -i -e "s#@runautogen@#bcond_without#g" $@-t else sed -i -e "s#@runautogen@#bcond_with#g" $@-t endif sed -i -e "s#@defaultadmgroup@#$(DEFAULTADMGROUP)#g" $@-t chmod a-w $@-t mv $@-t $@ $(TARGZFILE): $(MAKE) dist RPMBUILDOPTS = --define "_sourcedir $(abs_builddir)" \ --define "_specdir $(abs_builddir)" \ --define "_builddir $(abs_builddir)" \ --define "_srcrpmdir $(abs_builddir)" \ --define "_rpmdir $(abs_builddir)" srpm: clean $(MAKE) $(SPEC) $(TARGZFILE) rpmbuild $(RPMBUILDOPTS) --nodeps -bs $(SPEC) rpm: clean $(MAKE) $(SPEC) $(TARGZFILE) rpmbuild $(RPMBUILDOPTS) -ba $(SPEC) -## make deb - -$(DEBPOSTINST): $(DEBPOSTINST).in config.h - mkdir -p debian - rm -f $@-t $@ - sed -e "s#@defaultadmgroup@#$(DEFAULTADMGROUP)#g" $(abs_srcdir)/$@.in > $@-t - chmod a-w $@-t - mv $@-t $@ - -$(DEBCHANGELOG): $(DEBCHANGELOG).in .version - mkdir -p debian - rm -f $@-t $@ - date="`LC_ALL=C date -R`" && \ - if [ -f .tarball-version ]; then \ - gitver="`cat .tarball-version`" && \ - debver=$$gitver && \ - alphatag="" && \ - dirty="" && \ - numcomm="0"; \ - else \ - gitver="`GIT_DIR=$(abs_srcdir)/.git git describe --abbrev=4 --match='v*' HEAD 2>/dev/null`" && \ - debver=`echo $$gitver | sed -e "s/^v//" -e "s/-.*//g"` && \ - alphatag=`echo $$gitver | sed -e "s/.*-//" -e "s/^g//"` && \ - vtag=`echo $$gitver | sed -e "s/-.*//g"` && \ - numcomm=`GIT_DIR=$(abs_srcdir)/.git git rev-list $$vtag..HEAD | wc -l` && \ - GIT_DIR=$(abs_srcdir)/.git git update-index --refresh > /dev/null 2>&1 || true && \ - dirty=`GIT_DIR=$(abs_srcdir)/.git git diff-index --name-only HEAD 2>/dev/null`; \ - fi && \ - if [ -n "$$dirty" ]; then dirty="-dirty"; else dirty=""; fi && \ - if [ "$$numcomm" = "0" ]; then \ - sed \ - -e "s#@version@#$$debver#g" \ - -e "s#-@alphatag@##g" \ - -e "s#.@numcomm@##g" \ - -e "s#@dirty@#$$dirty#g" \ - -e "s#@date@#$$date#g" \ - $(abs_srcdir)/$@.in > $@-t; \ - else \ - sed \ - -e "s#@version@#$$debver#g" \ - -e "s#@alphatag@#$$alphatag#g" \ - -e "s#@numcomm@#$$numcomm#g" \ - -e "s#@dirty@#$$dirty#g" \ - -e "s#@date@#$$date#g" \ - $(abs_srcdir)/$@.in > $@-t; \ - fi; - chmod a-w $@-t - mv $@-t $@ - -deb-clean: - make -f debian/rules clean - ./configure - -debs: deb-clean dist - if [ -f .tarball-version ]; then \ - gitver="`cat .tarball-version`"; \ - else \ - gitver="`git describe --abbrev=4 --match='v*' HEAD 2>/dev/null`" && \ - gitver=`echo $$gitver | sed -e "s/^v//" -e "s/-g/-/" -e "s/-/./"`; \ - fi && \ - cp $(TARGZFILE) ../$(PACKAGE_NAME)_$$gitver.orig.tar.gz - dpkg-buildpackage -uc -us - # release/versioning BUILT_SOURCES = .version .version: echo $(VERSION) > $@-t && mv $@-t $@ dist-hook: gen-ChangeLog echo $(VERSION) > $(distdir)/.tarball-version gen_start_date = 2000-01-01 .PHONY: gen-ChangeLog gen-ChangeLog: if test -d .git; then \ LC_ALL=C $(top_srcdir)/build-aux/gitlog-to-changelog \ --since=$(gen_start_date) > $(distdir)/cl-t; \ rm -f $(distdir)/ChangeLog; \ mv $(distdir)/cl-t $(distdir)/ChangeLog; \ fi diff --git a/NOTES_TO_PACKAGE_MAINTAINERS b/NOTES_TO_PACKAGE_MAINTAINERS index b70e2941..829e7331 100644 --- a/NOTES_TO_PACKAGE_MAINTAINERS +++ b/NOTES_TO_PACKAGE_MAINTAINERS @@ -1,36 +1,31 @@ To: distribution package maintainers Those are a few things about this project that you should know. -Both spec file and debian/ are up for adoption. The spec file -is most often up to date to handle current HEAD of the tree. -The debian/ directory is probably obsoleted vs current -Debian packaging guidelines. - I surely welcome patches to support both in a better way. DO NOT ship kronosnetd. It's an experimental piece of super crappy code. IF you decide to ship it anyway, you get to be also the upstream maintainer :-) you have been warned. libtap is a simple commodity library used only by kronosnetd. I don't mind to support it, but don't ship just for the fun of it. It has no users, that I know of, outside of kronosnetd. libknet is still under heavy development. There might be more onwire network changes that could make current version incompatible with newer versions. Make sure to warn your users about it. Plan is to release a stable version (1.0) when we are confident that the current implementation is stable enough. libknet has a lot of build dependencies due to its modular implementation. It does not, however, link with all those libraries but uses a dlopen model to save runtime resources and provide flexibility to users to install only the libraries they are planning to use. Make sure that you do build with all feature enabled (compatible with your distribution licencing/patent policy of course) and tune your packaging to Recommend/Suggest the external libraries. Thanks Your upstream maintainers diff --git a/debian/changelog.in b/debian/changelog.in deleted file mode 100644 index 74ce9a00..00000000 --- a/debian/changelog.in +++ /dev/null @@ -1,5 +0,0 @@ -kronosnet (@version@.@numcomm@-@alphatag@@dirty@-1) unstable; urgency=low - - * These aren't the droids you're looking for. - - -- Autotools generated version @date@ diff --git a/debian/compat b/debian/compat deleted file mode 100644 index 7f8f011e..00000000 --- a/debian/compat +++ /dev/null @@ -1 +0,0 @@ -7 diff --git a/debian/control b/debian/control deleted file mode 100644 index 0e6dd15f..00000000 --- a/debian/control +++ /dev/null @@ -1,67 +0,0 @@ -Source: kronosnet -Priority: extra -Maintainer: Fabio M. Di Nitto -Build-Depends: debhelper (>= 7.0.50~), autoconf, autotools-dev, libtool, libqb-dev (>= 0.14.3), libnss3-dev, libnspr4-dev, libssl-dev, pkg-config, libpam-dev, zlib1g-dev, liblz4-dev (>= 1.7.3), liblzo2-dev, liblzma-dev, libbz2-dev, libsctp-dev -Standards-Version: 3.8.4 -Section: admin - -Package: kronosnetd -Section: admin -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends} -Description: Multipoint-to-Multipoint VPN daemon - The kronosnet daemon is a bridge between kronosnet switching engine - and kernel network tap devices, to create and administer a - distributed LAN over multipoint-to-multipoint VPNs. - The daemon does a poor attempt to provide a configure UI similar - to other known network devices/tools (Cisco, quagga). - Beside looking horrific, it allows runtime changes and - reconfiguration of the kronosnet(s) without daemon reload - or service disruption. - . - This package contains the kronosnet daemon and utils. - -Package: libtap1 -Section: libs -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends} -Description: Simple userland wrapper around kernel tap devices - This is an over-engineered commodity library to manage a pool - of tap devices and provides the basic - pre-up.d/up.d/down.d/post-down.d infrastructure. - . - This package contains libraries that should be used by libtap clients. - -Package: libtap-dev -Section: libdevel -Architecture: any -Depends: libtap1 (= ${binary:Version}), ${misc:Depends} -Description: Simple userland wrapper around kernel tap devices (developer files) - This is an over-engineered commodity library to manage a pool - of tap devices and provides the basic - pre-up.d/up.d/down.d/post-down.d infrastructure. - . - This package contains header files required to build clients for libtap clients. - -Package: libknet1 -Section: libs -Architecture: any -Depends: ${shlibs:Depends}, ${misc:Depends} -Description: kronosnet core switching implementation - The whole kronosnet core is implemented in this library. - Please refer to the not-yet-existing documentation for further - information. - . - This package contains libraries that should be used by libknet clients. - -Package: libknet-dev -Section: libdevel -Architecture: any -Depends: libknet1 (= ${binary:Version}), ${misc:Depends} -Description: kronosnet core switching implementation (developer files) - The whole kronosnet core is implemented in this library. - Please refer to the not-yet-existing documentation for further - information. - . - This package contains header files required to build clients for - libknet clients. diff --git a/debian/copyright b/debian/copyright deleted file mode 100644 index 41603a8e..00000000 --- a/debian/copyright +++ /dev/null @@ -1,24 +0,0 @@ -Format: http://dep.debian.net/deps/dep5 -Upstream-Name: kronosnetd -Source: https://github.com/fabbione/kronosnet - -Files: * -Copyright: 2010-2015 Red Hat, Inc. All rights reserved. -License: GPL-2.0+, LGPL-2.0+ - -License: GPL-2.0+, LGPL-2.0+ - This package is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. - . - This package is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - . - You should have received a copy of the GNU General Public License - along with this program. If not, see . - . - On Debian systems, the complete text of the GNU Lesser General - Public License can be found in "/usr/share/common-licenses/LGPL-2". diff --git a/debian/kronosnetd.install b/debian/kronosnetd.install deleted file mode 100644 index 48b46d6a..00000000 --- a/debian/kronosnetd.install +++ /dev/null @@ -1,7 +0,0 @@ -etc/kronosnet/* -etc/default/kronosnetd -etc/init.d/kronosnetd -etc/logrotate.d/kronosnetd -etc/pam.d/kronosnetd -usr/sbin/* -usr/share/man/man8/* diff --git a/debian/kronosnetd.postinst.in b/debian/kronosnetd.postinst.in deleted file mode 100644 index 3070c27e..00000000 --- a/debian/kronosnetd.postinst.in +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh - -set -e - -case "$1" in - configure) - groupadd --force --system @defaultadmgroup@ > /dev/null 2>&1 - ;; - purge|abort-upgrade|abort-remove|abort-deconfigure) - ;; - *) - echo "postinst called with unknown argument \`$1'" >&2 - exit 0 - ;; -esac - -#DEBHELPER# - -exit 0 diff --git a/debian/libknet-dev.install b/debian/libknet-dev.install deleted file mode 100644 index f97a6779..00000000 --- a/debian/libknet-dev.install +++ /dev/null @@ -1,4 +0,0 @@ -usr/include/libknet.h -usr/lib/libknet.a -usr/lib/libknet.so -usr/lib/pkgconfig/libknet.pc diff --git a/debian/libknet1.install b/debian/libknet1.install deleted file mode 100644 index 23db98c3..00000000 --- a/debian/libknet1.install +++ /dev/null @@ -1 +0,0 @@ -usr/lib/libknet.so.* diff --git a/debian/libtap-dev.install b/debian/libtap-dev.install deleted file mode 100644 index 7fc27158..00000000 --- a/debian/libtap-dev.install +++ /dev/null @@ -1,4 +0,0 @@ -usr/include/libtap.h -usr/lib/libtap.a -usr/lib/libtap.so -usr/lib/pkgconfig/libtap.pc diff --git a/debian/libtap1.install b/debian/libtap1.install deleted file mode 100644 index 68050e27..00000000 --- a/debian/libtap1.install +++ /dev/null @@ -1 +0,0 @@ -usr/lib/libtap.so.* diff --git a/debian/rules b/debian/rules deleted file mode 100755 index 6b22c651..00000000 --- a/debian/rules +++ /dev/null @@ -1,23 +0,0 @@ -#!/usr/bin/make -f -# -*- makefile -*- -# Sample debian/rules that uses debhelper. -# This file was originally written by Joey Hess and Craig Small. -# As a special exception, when this file is copied by dh-make into a -# dh-make output file, you may use that output file without restriction. -# This special exception was added by Craig Small in version 0.37 of dh-make. - -# Uncomment this to turn on verbose mode. -#export DH_VERBOSE=1 - -# package check requires root and does nasty things -export DEB_BUILD_OPTIONS=nocheck - -%: - dh $@ - -override_dh_installinit: - dh_installinit \ - --package kronosnetd \ - --onlyscripts \ - --no-restart-on-upgrade \ - --init-script=kronosnetd diff --git a/debian/source/format b/debian/source/format deleted file mode 100644 index 163aaf8d..00000000 --- a/debian/source/format +++ /dev/null @@ -1 +0,0 @@ -3.0 (quilt)