From 1656b7eafa51b5bf6b322f69ebcc0606a1bfa798 Mon Sep 17 00:00:00 2001 From: Tom Hughes Date: Mon, 16 Nov 2015 17:26:56 +0000 Subject: [PATCH] nodejs-symlink-deps: handle caret in versions --- nodejs-packaging-caret.patch | 19 +++++++++++++++++++ nodejs-packaging.spec | 8 +++++++- 2 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 nodejs-packaging-caret.patch diff --git a/nodejs-packaging-caret.patch b/nodejs-packaging-caret.patch new file mode 100644 index 0000000..6be8316 --- /dev/null +++ b/nodejs-packaging-caret.patch @@ -0,0 +1,19 @@ +commit 36e6f21081588f54b15c059e67576451ff457cdf +Author: Tom Hughes +Date: Mon Nov 16 17:20:04 2015 +0000 + + nodejs-symlink-deps: handle caret in versions + +diff --git a/nodejs-symlink-deps b/nodejs-symlink-deps +index 624293d..f984e3b 100755 +--- a/nodejs-symlink-deps ++++ b/nodejs-symlink-deps +@@ -78,7 +78,7 @@ def symlink_deps(deps, check): + + for dep, ver in deps.iteritems(): + if dep in mvpkgs and ver != '' and ver != '*': +- depver = ver.lstrip('~').split('.')[0] ++ depver = ver.lstrip('~^').split('.')[0] + target = os.path.join(sitelib, '{0}@{1}'.format(dep, depver)) + else: + target = os.path.join(sitelib, dep) diff --git a/nodejs-packaging.spec b/nodejs-packaging.spec index d844fc7..5495254 100644 --- a/nodejs-packaging.spec +++ b/nodejs-packaging.spec @@ -2,12 +2,14 @@ Name: nodejs-packaging Version: 7 -Release: 4%{?dist} +Release: 5%{?dist} Summary: RPM Macros and Utilities for Node.js Packaging BuildArch: noarch License: MIT URL: https://fedoraproject.org/wiki/Node.js/Packagers Source0: https://fedorahosted.org/released/%{name}/%{name}-fedora-%{version}.tar.xz +# https://bugzilla.redhat.com/show_bug.cgi?id=1120868 +Patch0: nodejs-packaging-caret.patch ExclusiveArch: %{nodejs_arches} noarch #nodejs-devel before 0.10.12 provided these macros and owned /usr/share/node @@ -20,6 +22,7 @@ Node.js modules and applications in RPM-based distributions. %prep %setup -qn %{name}-fedora-%{version} +%patch0 -p1 %build #nothing to do @@ -41,6 +44,9 @@ install -Dpm0644 multiver_modules %{buildroot}%{_datadir}/node/multiver_modules %doc LICENSE %changelog +* Mon Nov 16 2015 Tom Hughes - 7-5 +- nodejs-symlink-deps: handle caret in versions + * Wed Jun 17 2015 Fedora Release Engineering - 7-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild