[packages/netdata] autogenerate node dep
glen
glen at pld-linux.org
Wed Apr 6 13:05:49 CEST 2016
commit ea1ae9aa4b560976a1833129cfdc63a66b1d812d
Author: Elan Ruusamäe <glen at delfi.ee>
Date: Wed Apr 6 14:05:37 2016 +0300
autogenerate node dep
netdata.spec | 5 +++--
nodejs.patch | 17 +++++++++++++++++
2 files changed, 20 insertions(+), 2 deletions(-)
---
diff --git a/netdata.spec b/netdata.spec
index ba3dad0..470eb43 100644
--- a/netdata.spec
+++ b/netdata.spec
@@ -6,12 +6,13 @@
Summary: Linux real time system monitoring, over the web
Name: netdata
Version: 1.0.0
-Release: 0.8
+Release: 0.9
License: GPL v3+
Group: Applications/System
Source0: https://github.com/firehol/netdata/archive/v%{version}/%{name}-%{version}.tar.gz
# Source0-md5: 53a432f8849da6bd49b0853dd79551c5
Source1: %{name}.conf
+Patch0: nodejs.patch
URL: http://netdata.firehol.org/
BuildRequires: autoconf
BuildRequires: automake
@@ -48,7 +49,6 @@ Summary: netdata node.js plugins
Group: Applications/System
URL: https://github.com/firehol/netdata/wiki/General-Info---node.d
Requires: %{name} = %{version}-%{release}
-Requires: nodejs
%if "%{_rpmversion}" >= "5"
BuildArch: noarch
%endif
@@ -62,6 +62,7 @@ collection.
%prep
%setup -q
+%patch0 -p1
%build
%{__aclocal} -I m4
diff --git a/nodejs.patch b/nodejs.patch
new file mode 100644
index 0000000..7ba6ef9
--- /dev/null
+++ b/nodejs.patch
@@ -0,0 +1,17 @@
+--- netdata-1.0.0/plugins.d/node.d.plugin~ 2016-03-22 22:36:06.000000000 +0200
++++ netdata-1.0.0/plugins.d/node.d.plugin 2016-04-06 14:04:17.294990309 +0300
+@@ -1,13 +1,4 @@
+-#!/bin/sh
+-':' //; exec "$(command -v nodejs || command -v node || command -v js || echo "ERROR node.js IS NOT AVAILABLE IN THIS SYSTEM")" "$0" "$@"
+-
+-// shebang hack from:
+-// http://unix.stackexchange.com/questions/65235/universal-node-js-shebang
+-
+-// Initially this is run as a shell script (#!/bin/sh).
+-// Then, the second line, finds nodejs or node or js in the system path
+-// and executes it with the shell parameters.
+-
++#!/usr/bin/node
+ // --------------------------------------------------------------------------------------------------------------------
+
+ 'use strict';
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/netdata.git/commitdiff/ea1ae9aa4b560976a1833129cfdc63a66b1d812d
More information about the pld-cvs-commit
mailing list