Rename ninja-build executable to ninja
This commit is contained in:
parent
fca1e9efe9
commit
1e9774b06f
@ -1,103 +0,0 @@
|
|||||||
From 277589c0ca3250034edacee159cdf6860d5d7ae2 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Igor Gnatenko <i.gnatenko.brain@gmail.com>
|
|
||||||
Date: Mon, 28 Nov 2016 20:00:03 +0100
|
|
||||||
Subject: [PATCH 1/2] Rename mentions of the executable name to be ninja-build
|
|
||||||
|
|
||||||
Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
|
|
||||||
---
|
|
||||||
misc/bash-completion | 4 ++--
|
|
||||||
misc/zsh-completion | 2 +-
|
|
||||||
src/msvc_helper_main-win32.cc | 2 +-
|
|
||||||
src/ninja.cc | 8 ++++----
|
|
||||||
src/version.cc | 2 +-
|
|
||||||
5 files changed, 9 insertions(+), 9 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/misc/bash-completion b/misc/bash-completion
|
|
||||||
index e604cd4..be2009c 100644
|
|
||||||
--- a/misc/bash-completion
|
|
||||||
+++ b/misc/bash-completion
|
|
||||||
@@ -49,9 +49,9 @@ _ninja_target() {
|
|
||||||
C) eval dir="$OPTARG" ;;
|
|
||||||
esac
|
|
||||||
done;
|
|
||||||
- targets_command="eval ninja -C \"${dir}\" -t targets all 2>/dev/null | cut -d: -f1"
|
|
||||||
+ targets_command="eval ninja-build -C \"${dir}\" -t targets all 2>/dev/null | cut -d: -f1"
|
|
||||||
COMPREPLY=($(compgen -W '`${targets_command}`' -- "$cur"))
|
|
||||||
fi
|
|
||||||
return
|
|
||||||
}
|
|
||||||
-complete -F _ninja_target ninja
|
|
||||||
+complete -F _ninja_target ninja ninja-build
|
|
||||||
diff --git a/misc/zsh-completion b/misc/zsh-completion
|
|
||||||
index 446e269..eca884a 100644
|
|
||||||
--- a/misc/zsh-completion
|
|
||||||
+++ b/misc/zsh-completion
|
|
||||||
@@ -1,4 +1,4 @@
|
|
||||||
-#compdef ninja
|
|
||||||
+#compdef ninja ninja-build
|
|
||||||
# Copyright 2011 Google Inc. All Rights Reserved.
|
|
||||||
#
|
|
||||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
diff --git a/src/msvc_helper_main-win32.cc b/src/msvc_helper_main-win32.cc
|
|
||||||
index e419cd7..6472beb 100644
|
|
||||||
--- a/src/msvc_helper_main-win32.cc
|
|
||||||
+++ b/src/msvc_helper_main-win32.cc
|
|
||||||
@@ -28,7 +28,7 @@ namespace {
|
|
||||||
|
|
||||||
void Usage() {
|
|
||||||
printf(
|
|
||||||
-"usage: ninja -t msvc [options] -- cl.exe /showIncludes /otherArgs\n"
|
|
||||||
+"usage: ninja-build -t msvc [options] -- cl.exe /showIncludes /otherArgs\n"
|
|
||||||
"options:\n"
|
|
||||||
" -e ENVFILE load environment block from ENVFILE as environment\n"
|
|
||||||
" -o FILE write output dependency information to FILE.d\n"
|
|
||||||
diff --git a/src/ninja.cc b/src/ninja.cc
|
|
||||||
index 25eafe8..ab6a320 100644
|
|
||||||
--- a/src/ninja.cc
|
|
||||||
+++ b/src/ninja.cc
|
|
||||||
@@ -193,7 +193,7 @@ struct Tool {
|
|
||||||
/// Print usage information.
|
|
||||||
void Usage(const BuildConfig& config) {
|
|
||||||
fprintf(stderr,
|
|
||||||
-"usage: ninja [options] [targets...]\n"
|
|
||||||
+"usage: ninja-build [options] [targets...]\n"
|
|
||||||
"\n"
|
|
||||||
"if targets are unspecified, builds the 'default' target (see manual).\n"
|
|
||||||
"\n"
|
|
||||||
@@ -285,9 +285,9 @@ Node* NinjaMain::CollectTarget(const char* cpath, string* err) {
|
|
||||||
*err =
|
|
||||||
"unknown target '" + Node::PathDecanonicalized(path, slash_bits) + "'";
|
|
||||||
if (path == "clean") {
|
|
||||||
- *err += ", did you mean 'ninja -t clean'?";
|
|
||||||
+ *err += ", did you mean 'ninja-build -t clean'?";
|
|
||||||
} else if (path == "help") {
|
|
||||||
- *err += ", did you mean 'ninja -h'?";
|
|
||||||
+ *err += ", did you mean 'ninja-build -h'?";
|
|
||||||
} else {
|
|
||||||
Node* suggestion = state_.SpellcheckNode(path);
|
|
||||||
if (suggestion) {
|
|
||||||
@@ -583,7 +583,7 @@ int NinjaMain::ToolClean(const Options* options, int argc, char* argv[]) {
|
|
||||||
break;
|
|
||||||
case 'h':
|
|
||||||
default:
|
|
||||||
- printf("usage: ninja -t clean [options] [targets]\n"
|
|
||||||
+ printf("usage: ninja-build -t clean [options] [targets]\n"
|
|
||||||
"\n"
|
|
||||||
"options:\n"
|
|
||||||
" -g also clean files marked as ninja generator output\n"
|
|
||||||
diff --git a/src/version.cc b/src/version.cc
|
|
||||||
index eafa082..a9964d7 100644
|
|
||||||
--- a/src/version.cc
|
|
||||||
+++ b/src/version.cc
|
|
||||||
@@ -38,7 +38,7 @@ void CheckNinjaVersion(const string& version) {
|
|
||||||
ParseVersion(version, &file_major, &file_minor);
|
|
||||||
|
|
||||||
if (bin_major > file_major) {
|
|
||||||
- Warning("ninja executable version (%s) greater than build file "
|
|
||||||
+ Warning("ninja-build executable version (%s) greater than build file "
|
|
||||||
"ninja_required_version (%s); versions may be incompatible.",
|
|
||||||
kNinjaVersion, version.c_str());
|
|
||||||
return;
|
|
||||||
--
|
|
||||||
2.10.2
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
%__ninja %{_bindir}/ninja-build
|
%__ninja %{_bindir}/ninja
|
||||||
%__ninja_common_opts -v %{?_smp_mflags}
|
%__ninja_common_opts -v %{?_smp_mflags}
|
||||||
|
|
||||||
%ninja_build \
|
%ninja_build \
|
||||||
|
@ -1,13 +1,12 @@
|
|||||||
Name: ninja-build
|
Name: ninja-build
|
||||||
Version: 1.7.2
|
Version: 1.7.2
|
||||||
Release: 3%{?dist}
|
Release: 4%{?dist}
|
||||||
Summary: A small build system with a focus on speed
|
Summary: A small build system with a focus on speed
|
||||||
License: ASL 2.0
|
License: ASL 2.0
|
||||||
URL: http://martine.github.com/ninja/
|
URL: http://martine.github.com/ninja/
|
||||||
Source0: https://github.com/martine/ninja/archive/v%{version}.tar.gz#/ninja-%{version}.tar.gz
|
Source0: https://github.com/martine/ninja/archive/v%{version}.tar.gz#/ninja-%{version}.tar.gz
|
||||||
Source1: ninja.vim
|
Source1: ninja.vim
|
||||||
Source2: macros.ninja
|
Source2: macros.ninja
|
||||||
Patch0001: 0001-Rename-mentions-of-the-executable-name-to-be-ninja-b.patch
|
|
||||||
Patch0002: 0002-Disable-test-which-takes-too-many-resources-for-koji.patch
|
Patch0002: 0002-Disable-test-which-takes-too-many-resources-for-koji.patch
|
||||||
BuildRequires: gcc-c++
|
BuildRequires: gcc-c++
|
||||||
%if 0%{?rhel} && 0%{?rhel} <= 7
|
%if 0%{?rhel} && 0%{?rhel} <= 7
|
||||||
@ -43,22 +42,25 @@ CFLAGS="%{optflags}" LDFLAGS="%{?__global_ldflags}" \
|
|||||||
|
|
||||||
%install
|
%install
|
||||||
# TODO: Install ninja_syntax.py?
|
# TODO: Install ninja_syntax.py?
|
||||||
install -Dpm0755 ninja %{buildroot}%{_bindir}/ninja-build
|
install -Dpm0755 ninja -t %{buildroot}%{_bindir}/
|
||||||
install -Dpm0644 misc/bash-completion %{buildroot}%{_datadir}/bash-completion/completions/ninja-build
|
install -Dpm0644 misc/bash-completion %{buildroot}%{_datadir}/bash-completion/completions/ninja
|
||||||
install -Dpm0644 misc/ninja-mode.el %{buildroot}%{_datadir}/emacs/site-lisp/ninja-mode.el
|
install -Dpm0644 misc/ninja-mode.el %{buildroot}%{_datadir}/emacs/site-lisp/ninja-mode.el
|
||||||
install -Dpm0644 misc/ninja.vim %{buildroot}%{_datadir}/vim/vimfiles/syntax/ninja.vim
|
install -Dpm0644 misc/ninja.vim %{buildroot}%{_datadir}/vim/vimfiles/syntax/ninja.vim
|
||||||
install -Dpm0644 %{S:1} %{buildroot}%{_datadir}/vim/vimfiles/ftdetect/ninja.vim
|
install -Dpm0644 %{S:1} %{buildroot}%{_datadir}/vim/vimfiles/ftdetect/ninja.vim
|
||||||
install -Dpm0644 misc/zsh-completion %{buildroot}%{_datadir}/zsh/site-functions/_ninja
|
install -Dpm0644 misc/zsh-completion %{buildroot}%{_datadir}/zsh/site-functions/_ninja
|
||||||
install -Dpm0644 %{S:2} %{buildroot}%{rpmmacrodir}/macros.ninja
|
install -Dpm0644 %{S:2} %{buildroot}%{rpmmacrodir}/macros.ninja
|
||||||
|
|
||||||
|
ln -s ninja %{buildroot}%{_bindir}/ninja-build
|
||||||
|
|
||||||
%check
|
%check
|
||||||
./ninja_test
|
./ninja_test
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%license COPYING
|
%license COPYING
|
||||||
%doc HACKING.md README doc/manual.html
|
%doc HACKING.md README doc/manual.html
|
||||||
|
%{_bindir}/ninja
|
||||||
%{_bindir}/ninja-build
|
%{_bindir}/ninja-build
|
||||||
%{_datadir}/bash-completion/completions/ninja-build
|
%{_datadir}/bash-completion/completions/ninja
|
||||||
%{_datadir}/emacs/site-lisp/ninja-mode.el
|
%{_datadir}/emacs/site-lisp/ninja-mode.el
|
||||||
%{_datadir}/vim/vimfiles/syntax/ninja.vim
|
%{_datadir}/vim/vimfiles/syntax/ninja.vim
|
||||||
%{_datadir}/vim/vimfiles/ftdetect/ninja.vim
|
%{_datadir}/vim/vimfiles/ftdetect/ninja.vim
|
||||||
@ -67,6 +69,10 @@ install -Dpm0644 %{S:2} %{buildroot}%{rpmmacrodir}/macros.ninja
|
|||||||
%{rpmmacrodir}/macros.ninja
|
%{rpmmacrodir}/macros.ninja
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Apr 21 2017 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 1.7.2-4
|
||||||
|
- Rename main executable to ninja (#1166135)
|
||||||
|
(compatibility symlink is added)
|
||||||
|
|
||||||
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.7.2-3
|
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.7.2-3
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user