File nodejs-less.js.spec of Package nodejs-less.js

#
# spec file for package nodejs-less.js
#
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via http://bugs.opensuse.org/
#

Name:           nodejs-less.js
Version:        1.6.1
Release:        0
Summary:        The dynamic stylesheet language
License:        Apache-2.0
Group:          Development/Libraries/Other
Url:            https://github.com/less/less.js
Source0:        less.js-%{version}.tar.gz
BuildRequires:  nodejs
BuildRequires:  zlib-devel
BuildRequires:  fdupes
Requires:       nodejs
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildArch:      noarch
%define         mod_name less.js
%define         local_dependencies_path %{buildroot}%{_prefix}/lib/node_modules/%{mod_name}/node_modules

%description
This is the JavaScript, and now official, stable version of LESS.

%prep
%setup -q -n less.js-%{version}
#NOTE(saschpe): Remove source-map tests, dep download fails:
rm -rf test/sourcemaps/

%build

%install
npm_config_binroot=%{buildroot}%{_bindir} \
npm_config_manroot=%{buildroot}%{_mandir} \
npm_config_prefix=%{buildroot}%{_prefix} npm install -g .
%fdupes %{buildroot}%{_prefix}/lib/node_modules

%check
node test

%files
%defattr(-,root,root)
%doc LICENSE README.md
%{_bindir}/lessc
%{_prefix}/lib/node_modules

%changelog
openSUSE Build Service is sponsored by