Blob Blame History Raw
%{?nodejs_find_provides_and_requires}

%global enable_tests 1

Name:       nodejs-ltx
Version:    0.5.0
Release:    1%{?dist}
Summary:    A Node.js module for parsing, modifying and building XML
License:    MIT
Group:      System Environment/Libraries
URL:        https://github.com/astro/ltx
Source0:    http://registry.npmjs.org/ltx/-/ltx-%{version}.tgz

BuildArch:  noarch
%if 0%{?fedora} >= 19
ExclusiveArch: %{nodejs_arches} noarch
%else
ExclusiveArch: %{ix86} x86_64 %{arm} noarch
%endif

BuildRequires:  nodejs-packaging

%if 0%{?enable_tests}
BuildRequires:  npm(vows)
%endif

%description
%{summary}.


%prep
%setup -q -n package
%nodejs_fixdep node-expat '~2.0'


%build
#nothing to do


%install
mkdir -p %{buildroot}%{nodejs_sitelib}/ltx
cp -pr package.json index.js lib/ \
    %{buildroot}%{nodejs_sitelib}/ltx

%nodejs_symlink_deps


%if 0%{?enable_tests}
%check
%nodejs_symlink_deps --check
%__nodejs test/dom-element-test.js
%__nodejs test/element-test.js
%__nodejs test/parse-test.js
%__nodejs test/unicode-test.js
%endif


%files
%doc LICENSE README.markdown
%{nodejs_sitelib}/ltx


%changelog
* Sat Apr 19 2014 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.5.0-1
- update to upstream release 0.5.0

* Sat Jul 27 2013 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.2.4-1
- update to upstream release 0.2.4

* Sat May 25 2013 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.2.3-1
- update to upstream release 0.2.3

* Sun Mar 17 2013 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.2.2-2
- do not include benchmark directory in %%doc

* Mon Feb 11 2013 Jamie Nguyen <jamielinux@fedoraproject.org> - 0.2.2-1
- initial package