commit:     1a42ffc292f575d25c6803f7adc1b6bd46b14cc2
Author:     Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
AuthorDate: Thu May 21 18:14:50 2020 +0000
Commit:     Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
CommitDate: Thu May 21 18:14:50 2020 +0000
URL:        
https://gitweb.gentoo.org/proj/binutils-config.git/commit/?id=1a42ffc2

Makefile: new trivial makefile to build tarballs and install them

Signed-off-by: Sergei Trofimovich <slyfox <AT> gentoo.org>

 Makefile            | 33 +++++++++++++++++++++++++++++++++
 README.md           |  2 --
 src/binutils-config |  0
 3 files changed, 33 insertions(+), 2 deletions(-)

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

Reply via email to