pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

guessit: properly handle installation with multiple Python versions



Module Name:	pkgsrc-wip
Committed By:	Leonardo Taccari <leot%NetBSD.org@localhost>
Pushed By:	leot
Date:		Mon Feb 13 13:13:59 2017 +0100
Changeset:	e756f312c2bb986f9c478635082e43bf2fc968c4

Modified Files:
	guessit/Makefile
	guessit/PLIST
Added Files:
	guessit/ALTERNATIVES

Log Message:
guessit: properly handle installation with multiple Python versions

- Properly rename guessit script with a -${PYVERSSUFFIX} suffix appended in the
  post-install phase and adjust PLIST accordingly
- Add ALTERNATIVES

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=e756f312c2bb986f9c478635082e43bf2fc968c4

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 guessit/ALTERNATIVES | 1 +
 guessit/Makefile     | 3 +++
 guessit/PLIST        | 2 +-
 3 files changed, 5 insertions(+), 1 deletion(-)

diffs:
diff --git a/guessit/ALTERNATIVES b/guessit/ALTERNATIVES
new file mode 100644
index 0000000000..b694841369
--- /dev/null
+++ b/guessit/ALTERNATIVES
@@ -0,0 +1 @@
+bin/guessit @PREFIX@/bin/guessit-@PYVERSSUFFIX@
diff --git a/guessit/Makefile b/guessit/Makefile
index 9f0a5e83f7..b9074c2668 100644
--- a/guessit/Makefile
+++ b/guessit/Makefile
@@ -15,6 +15,9 @@ DEPENDS+=	${PYPKGPREFIX}-rebulk>=0.8.2:../../wip/py-rebulk
 
 USE_LANGUAGES=	# none
 
+post-install:
+	${MV} ${DESTDIR}${PREFIX}/bin/guessit ${DESTDIR}${PREFIX}/bin/guessit-${PYVERSSUFFIX} || ${TRUE}
+
 .include "../../lang/python/application.mk"
 .include "../../lang/python/egg.mk"
 .include "../../mk/bsd.pkg.mk"
diff --git a/guessit/PLIST b/guessit/PLIST
index dbe6219342..7f4e7845de 100644
--- a/guessit/PLIST
+++ b/guessit/PLIST
@@ -1,5 +1,5 @@
 @comment $NetBSD$
-bin/guessit
+bin/guessit-${PYVERSSUFFIX}
 ${PYSITELIB}/${EGG_INFODIR}/PKG-INFO
 ${PYSITELIB}/${EGG_INFODIR}/SOURCES.txt
 ${PYSITELIB}/${EGG_INFODIR}/dependency_links.txt


Home | Main Index | Thread Index | Old Index