From 1a42ffc292f575d25c6803f7adc1b6bd46b14cc2 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Thu, 21 May 2020 19:14:50 +0100 Subject: Makefile: new trivial makefile to build tarballs and install them Signed-off-by: Sergei Trofimovich --- Makefile | 33 +++++++++++++++++++++++++++++++++ README.md | 2 -- src/binutils-config | 0 3 files changed, 33 insertions(+), 2 deletions(-) create mode 100644 Makefile mode change 100644 => 100755 src/binutils-config diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..42dbeff --- /dev/null +++ b/Makefile @@ -0,0 +1,33 @@ +EPREFIX ?= + +PN = binutils-config +PV = git +P = $(PN)-$(PV) + +PREFIX = $(EPREFIX)/usr +BINDIR = $(PREFIX)/bin +DOCDIR = $(PREFIX)/share/doc/$(P) +ESELECTDIR = $(PREFIX)/share/eselect/modules +MANDIR = $(PREFIX)/share/man + +MKDIR_P = mkdir -p -m 755 +INSTALL_EXE = install -m 755 +INSTALL_DATA = install -m 644 + +all: # no-op + +install: all + $(MKDIR_P) $(DESTDIR)$(BINDIR) $(DESTDIR)$(DOCDIR) $(DESTDIR)$(ESELECTDIR) $(DESTDIR)$(MANDIR)/man8 + $(INSTALL_EXE) src/binutils-config $(DESTDIR)$(BINDIR) + $(INSTALL_DATA) README.md $(DESTDIR)$(DOCDIR) + $(INSTALL_DATA) src/binutils.eselect $(DESTDIR)$(ESELECTDIR) + $(INSTALL_DATA) src/binutils-config.8 $(DESTDIR)$(MANDIR)/man8 + +dist: + @if [ "$(PV)" = "git" ] ; then \ + printf "please run: make dist PV=xxx\n(where xxx is a git tag)\n" ; \ + exit 1 ; \ + fi + git archive --prefix=$(P)/ v$(PV) | xz > $(P).tar.xz + +.PHONY: all clean dist install diff --git a/README.md b/README.md index 3eadab1..ec556d5 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,2 @@ # binutils-config sys-devel/binutils-config : Utility to change the binutils version being used - -History converted from the attic of the old Gentoo CVS repository. diff --git a/src/binutils-config b/src/binutils-config old mode 100644 new mode 100755 -- cgit v1.2.3-65-gdbad