mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
From: Michael Olbrich <m.olbrich@pengutronix.de>
To: ptxdist@pengutronix.de
Cc: Roland Hieber <rhi@pengutronix.de>
Subject: Re: [ptxdist] [APPLIED] pps-tools: new package
Date: Wed, 16 Jun 2021 12:35:21 +0200	[thread overview]
Message-ID: <20210616103521.1997821-1-m.olbrich@pengutronix.de> (raw)
In-Reply-To: <20210604180715.4674-1-rhi@pengutronix.de>

Thanks, applied as 4c421f627894f8894c1817183d5744eafe8ee6da.

Michael

[sent from post-receive hook]

On Wed, 16 Jun 2021 12:35:21 +0200, Roland Hieber <rhi@pengutronix.de> wrote:
> Signed-off-by: Roland Hieber <rhi@pengutronix.de>
> Message-Id: <20210604180715.4674-1-rhi@pengutronix.de>
> Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
> 
> diff --git a/patches/pps-tools-1.0.2/0001-Makefile-fix-installation-to-empty-DESTDIR.patch b/patches/pps-tools-1.0.2/0001-Makefile-fix-installation-to-empty-DESTDIR.patch
> new file mode 100644
> index 000000000000..97498dc22e1b
> --- /dev/null
> +++ b/patches/pps-tools-1.0.2/0001-Makefile-fix-installation-to-empty-DESTDIR.patch
> @@ -0,0 +1,40 @@
> +From: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> +Date: Mon, 3 Dec 2018 13:55:02 +0100
> +Subject: [PATCH] Makefile: fix installation to empty DESTDIR
> +
> +When DESTDIR is empty, or at least does not contain usr/bin or
> +usr/include, the installation fails, because install does not create
> +those intermediate directories:
> +
> +$ make DESTDIR=/tmp/koin install
> +install -m 755 -t /tmp/koin/usr/bin ppsfind ppstest ppsctl ppswatch ppsldisc
> +install: failed to access '/tmp/koin/usr/bin': No such file or directory
> +
> +Using the -D option of install fixes this:
> +
> +$ make DESTDIR=/tmp/koin install
> +install -D -m 755 -t /tmp/koin/usr/bin ppsfind ppstest ppsctl ppswatch ppsldisc
> +install -D -m 644 -t /tmp/koin/usr/include/sys timepps.h
> +
> +Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
> +Origin: upstream; https://github.com/redlab-i/pps-tools/commit/b3eae485a8c759d1ce1727076b2c287deb5f24e1
> +Signed-off-by: Roland Hieber <rhi@pengutronix.de>
> +---
> + Makefile | 4 ++--
> + 1 file changed, 2 insertions(+), 2 deletions(-)
> +
> +diff --git a/Makefile b/Makefile
> +index 939466885e9f..30672f79585c 100644
> +--- a/Makefile
> ++++ b/Makefile
> +@@ -19,8 +19,8 @@ include .depend
> + endif
> + 
> + install : all
> +-	install -m 755 -t $(DESTDIR)/usr/bin ppsfind $(TARGETS)
> +-	install -m 644 -t $(DESTDIR)/usr/include/sys timepps.h
> ++	install -D -m 755 -t $(DESTDIR)/usr/bin ppsfind $(TARGETS)
> ++	install -D -m 644 -t $(DESTDIR)/usr/include/sys timepps.h
> + 
> + uninstall :
> + 	for f in $(TARGETS); do rm $(DESTDIR)/usr/bin/$$f; done
> diff --git a/patches/pps-tools-1.0.2/series b/patches/pps-tools-1.0.2/series
> new file mode 100644
> index 000000000000..7b3c7762325f
> --- /dev/null
> +++ b/patches/pps-tools-1.0.2/series
> @@ -0,0 +1,4 @@
> +# generated by git-ptx-patches
> +#tag:base --start-number 1
> +0001-Makefile-fix-installation-to-empty-DESTDIR.patch
> +# eb24c32ce10c0f011f2d37488c8de58c  - git-ptx-patches magic
> diff --git a/rules/pps-tools.in b/rules/pps-tools.in
> new file mode 100644
> index 000000000000..2cce9464ae93
> --- /dev/null
> +++ b/rules/pps-tools.in
> @@ -0,0 +1,10 @@
> +## SECTION=shell_and_console
> +
> +config PPS_TOOLS
> +	tristate
> +	prompt "pps-tools"
> +	select LIBC_M
> +	help
> +	  The pps-tools provide applications to configure and test pulse per
> +	  second devices. They also provide the official PPS API header
> +	  timepps.h.
> diff --git a/rules/pps-tools.make b/rules/pps-tools.make
> new file mode 100644
> index 000000000000..65a06c7d128b
> --- /dev/null
> +++ b/rules/pps-tools.make
> @@ -0,0 +1,76 @@
> +# -*-makefile-*-
> +#
> +# Copyright (C) 2020 by Daniel Glöckner <dg@emlix.com>
> +# Copyright (C) 2021 Roland Hieber, Pengutronix <rhi@pengutronix.de>
> +#
> +# For further information about the PTXdist project and license conditions
> +# see the README file.
> +#
> +
> +#
> +# We provide this package
> +#
> +PACKAGES-$(PTXCONF_PPS_TOOLS) += pps-tools
> +
> +#
> +# Paths and names
> +#
> +PPS_TOOLS_VERSION	:= 1.0.2
> +PPS_TOOLS_MD5		:= 6eddfeb151cffe8751f4766e428b8eb7
> +PPS_TOOLS		:= pps-tools-$(PPS_TOOLS_VERSION)
> +PPS_TOOLS_SUFFIX	:= tar.gz
> +PPS_TOOLS_URL		:= https://github.com/redlab-i/pps-tools/archive/v$(PPS_TOOLS_VERSION).$(PPS_TOOLS_SUFFIX)
> +PPS_TOOLS_SOURCE	:= $(SRCDIR)/$(PPS_TOOLS).$(PPS_TOOLS_SUFFIX)
> +PPS_TOOLS_DIR		:= $(BUILDDIR)/$(PPS_TOOLS)
> +PPS_TOOLS_LICENSE	:= GPL-2.0-or-later
> +PPS_TOOLS_LICENSE_FILES	:= \
> +	file://COPYING;md5=751419260aa954499f7abaabaa882bbe \
> +	file://ppsctl.c;startline=6;endline=14;md5=681a7c053fa782c41658ac9fc7dd1579
> +
> +# ----------------------------------------------------------------------------
> +# Prepare
> +# ----------------------------------------------------------------------------
> +
> +PPS_TOOLS_CONF_TOOL	:= NO
> +
> +# ----------------------------------------------------------------------------
> +# Compile
> +# ----------------------------------------------------------------------------
> +
> +PPS_TOOLS_MAKE_ENV	:= $(CROSS_ENV)
> +
> +$(STATEDIR)/pps-tools.compile:
> +	@$(call targetinfo)
> +
> +	@# Everything depends on .depends, which is made by but also included
> +	@# in the Makefile, so make sure that "make install" does not rebuild
> +	@# everything
> +	@$(call compile, PPS_TOOLS, .depend)
> +	@$(call world/compile, PPS_TOOLS)
> +
> +	@$(call touch)
> +
> +# ----------------------------------------------------------------------------
> +# Target-Install
> +# ----------------------------------------------------------------------------
> +
> +$(STATEDIR)/pps-tools.targetinstall:
> +	@$(call targetinfo)
> +
> +	@$(call install_init, pps-tools)
> +	@$(call install_fixup, pps-tools,PRIORITY,optional)
> +	@$(call install_fixup, pps-tools,SECTION,base)
> +	@$(call install_fixup, pps-tools,AUTHOR,"Daniel Glöckner <dg@emlix.com>")
> +	@$(call install_fixup, pps-tools,DESCRIPTION,missing)
> +
> +	@$(call install_copy, pps-tools, 0, 0, 0755, -, /usr/bin/ppsfind)
> +	@$(call install_copy, pps-tools, 0, 0, 0755, -, /usr/bin/ppstest)
> +	@$(call install_copy, pps-tools, 0, 0, 0755, -, /usr/bin/ppsctl)
> +	@$(call install_copy, pps-tools, 0, 0, 0755, -, /usr/bin/ppswatch)
> +	@$(call install_copy, pps-tools, 0, 0, 0755, -, /usr/bin/ppsldisc)
> +
> +	@$(call install_finish, pps-tools)
> +
> +	@$(call touch)
> +
> +# vim: syntax=make

_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
To unsubscribe, send a mail with subject "unsubscribe" to ptxdist-request@pengutronix.de

      parent reply	other threads:[~2021-06-16 10:36 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-04 18:07 [ptxdist] [PATCH v2 1/3] " Roland Hieber
2021-06-04 18:07 ` [ptxdist] [PATCH v2 2/3] chrony: enable support for PPS devices Roland Hieber
2021-06-16 10:35   ` [ptxdist] [APPLIED] " Michael Olbrich
2021-06-04 18:07 ` [ptxdist] [PATCH v2 3/3] chrony: fix typo Roland Hieber
2021-06-16 10:35   ` [ptxdist] [APPLIED] " Michael Olbrich
2021-06-16 10:35 ` Michael Olbrich [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210616103521.1997821-1-m.olbrich@pengutronix.de \
    --to=m.olbrich@pengutronix.de \
    --cc=ptxdist@pengutronix.de \
    --cc=rhi@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox