commit: 3430047a48a955ed4d9eae3f90b6fe40c5d36717 Author: Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com> AuthorDate: Mon May 9 05:50:55 2022 +0000 Commit: Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com> CommitDate: Mon May 9 05:52:00 2022 +0000 URL: https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=3430047a
net-misc/linuxptp: new package, add 3.1.1 Signed-off-by: Alessandro Barbieri <lssndrbarbieri <AT> gmail.com> net-misc/linuxptp/Manifest | 1 + .../linuxptp/files/linuxptp-3.1.1-makefile.patch | 34 ++++++++++++++++++++++ net-misc/linuxptp/linuxptp-3.1.1.ebuild | 29 ++++++++++++++++++ net-misc/linuxptp/metadata.xml | 12 ++++++++ 4 files changed, 76 insertions(+) diff --git a/net-misc/linuxptp/Manifest b/net-misc/linuxptp/Manifest new file mode 100644 index 000000000..bd6d2da1c --- /dev/null +++ b/net-misc/linuxptp/Manifest @@ -0,0 +1 @@ +DIST linuxptp-3.1.1.tgz 218784 BLAKE2B 5b46580a0e1b6e003f5f03e512c4f9b348c086f356fd47d3480da5e8223ba291fdb213798c696c37759896a99bccf21cd7e7daddce5aa5ed5701afb0e622a755 SHA512 c3c40987fe68480a8473097ebc3c506fb4f8f3b6456bbe637b2b3cb0b3e0182f1513b511fdc04b3607d5f7d8bd1bd22502bb86eb13f9fa4fa63a3331846b33ec diff --git a/net-misc/linuxptp/files/linuxptp-3.1.1-makefile.patch b/net-misc/linuxptp/files/linuxptp-3.1.1-makefile.patch new file mode 100644 index 000000000..f2ffe8f44 --- /dev/null +++ b/net-misc/linuxptp/files/linuxptp-3.1.1-makefile.patch @@ -0,0 +1,34 @@ +--- /var/tmp/portage/net-misc/linuxptp-3.1.1/work/linuxptp-3.1.1/makefile ++++ linuxptp-3.1.1/makefile +@@ -18,9 +18,8 @@ + KBUILD_OUTPUT = + + DEBUG = +-CC = $(CROSS_COMPILE)gcc + VER = -DVER=$(version) +-CFLAGS = -Wall $(VER) $(incdefs) $(DEBUG) $(EXTRA_CFLAGS) ++CFLAGS += -Wall $(VER) $(incdefs) $(DEBUG) $(EXTRA_CFLAGS) + LDLIBS = -lm -lrt -pthread $(EXTRA_LDFLAGS) + PRG = ptp4l hwstamp_ctl nsm phc2sys phc_ctl pmc timemaster ts2phc + FILTERS = filter.o mave.o mmedian.o +@@ -43,9 +42,9 @@ + version := $(shell $(srcdir)/version.sh $(srcdir)) + VPATH = $(srcdir) + +-prefix = /usr/local ++prefix = /usr + sbindir = $(prefix)/sbin +-mandir = $(prefix)/man ++mandir = $(prefix)/share/man + man8dir = $(mandir)/man8 + + all: $(PRG) +@@ -97,7 +96,7 @@ + %.d: %.c + @echo DEPEND $<; \ + rm -f $@; \ +- $(CC) -MM $(CPPFLAGS) $(CFLAGS) $< > $@.$$$$; \ ++ $(CC) -MM $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -fPIE $< > $@.$$$$; \ + sed 's,\($*\)\.o[ :]*,\1.o $@ : ,g' < $@.$$$$ > $@; \ + rm -f $@.$$$$ + diff --git a/net-misc/linuxptp/linuxptp-3.1.1.ebuild b/net-misc/linuxptp/linuxptp-3.1.1.ebuild new file mode 100644 index 000000000..d6e0a5f58 --- /dev/null +++ b/net-misc/linuxptp/linuxptp-3.1.1.ebuild @@ -0,0 +1,29 @@ +# Copyright 1999-2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit toolchain-funcs + +DESCRIPTION="PTP IEEE 1588 stack for Linux" +HOMEPAGE="https://sourceforge.net/projects/linuxptp" +SRC_URI="mirror://sourceforge/project/${PN}/v$(ver_cut 1-2)/${P}.tgz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64" + +BDEPEND="sys-kernel/linux-headers" + +RESTRICT="test" #no tests +PATCHES=( "${FILESDIR}/${P}-makefile.patch" ) + +src_compile() { + tc-export CC + default +} + +src_install() { + default + dodoc README.org +} diff --git a/net-misc/linuxptp/metadata.xml b/net-misc/linuxptp/metadata.xml new file mode 100644 index 000000000..152ed05a8 --- /dev/null +++ b/net-misc/linuxptp/metadata.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>lssndrbarbi...@gmail.com</email> + <name>Alessandro Barbieri</name> + </maintainer> + <upstream> + <bugs-to>https://lists.sourceforge.net/lists/listinfo/linuxptp-users</bugs-to> + <remote-id type="sourceforge">linuxptp</remote-id> + </upstream> +</pkgmetadata>