ninja/ninja.spec
Martin Pluskal 94dd2c0e8d - Update to version 1.7.2:
* %e and %r work again in dumb terminals (#1146, #1148)
  * `-t browse` now HTML-escapes rule names (#1157)
  * an edge may now have 0 explicit outputs if it has implicit
    outputs (#1159)
  * make misc/measure.py python 3-compatible
  * misc/write_fake_manifest.py now optionally writes source files,
    use it to quickly produce large, buildable projects for testing
    (#1109, #1198)
  * on newer FreeBSDs, use ppoll()
- Refresh ninja-disable-maxprocs-test.patch

OBS-URL: https://build.opensuse.org/package/show/devel:tools:building/ninja?expand=0&rev=30
2016-11-13 11:22:15 +00:00

74 lines
2.2 KiB
RPMSpec

#
# spec file for package ninja
#
# Copyright (c) 2016 SUSE LINUX 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: ninja
Version: 1.7.2
Release: 0
Summary: A small build system closest in spirit to Make
License: Apache-2.0
Group: Development/Tools/Building
Url: https://ninja-build.org/
Source0: https://github.com/ninja-build/ninja/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
Patch1: ninja-disable-maxprocs-test.patch
BuildRequires: gcc-c++
%if 0%{?suse_version} <= 1110
BuildRequires: python-base
%else
BuildRequires: python3-base
%endif
BuildRequires: re2c
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
Ninja is yet another build system.
It takes as input the interdependencies of files (typically source code and output executables)
and orchestrates building them, quickly.
%prep
%setup -q
%patch1
%build
export CFLAGS="%{optflags}"
export CXXFLAGS="%{optflags}"
%if 0%{?suse_version} <= 1110
python2./configure.py --bootstrap --verbose
%else
python3 ./configure.py --bootstrap --verbose
%endif
%install
install -D -p -m 0755 ninja %{buildroot}%{_bindir}/ninja
install -D -p -m 0644 misc/zsh-completion %{buildroot}%{_datadir}/zsh/site-functions/_ninja
install -D -p -m 0644 misc/ninja.vim %{buildroot}%{_datadir}/vim/site/syntax/ninja.vim
install -D -p -m 0644 misc/bash-completion %{buildroot}%{_sysconfdir}/bash_completion.d/ninja
%check
./ninja ninja_test
./ninja_test
%files
%defattr(-,root,root)
%doc COPYING
%{_bindir}/ninja
%{_datadir}/zsh
%{_datadir}/vim
%{_sysconfdir}/bash_completion.d
%changelog