SHA256
1
0
forked from pool/ldc

Accepting request 659324 from home:Guillaume_G:branches:devel:languages:D

- Disable bootstrap in Tumbleweed and Leap 15+ as it is bootstrapped already
  and to workaround https://github.com/ldc-developers/ldc/issues/2947
- Add bash-completion sub-package
- Update to 1.13.0
/bin/bash: :wq : commande introuvable
- Disable ppc64 builds (boo#1113531)

OBS-URL: https://build.opensuse.org/request/show/659324
OBS-URL: https://build.opensuse.org/package/show/devel:languages:D/ldc?expand=0&rev=25
This commit is contained in:
2018-12-18 15:16:32 +00:00
committed by Git OBS Bridge
parent a240f8e872
commit 3aedf42ae9
4 changed files with 105 additions and 9 deletions

View File

@@ -16,13 +16,19 @@
#
%define so_ver 82
%define so_ver 83
%define lname_runtime libdruntime-%{name}
%define lname_phobos libphobos2-%{name}
%define _bashcompletionsdir %{_datadir}/bash-completion/completions
# Do not bootstrap in Tumbleweed, and Leap 15+ as LDC is already available
%if 0%{suse_version} >= 1500
%bcond_with ldc_bootstrap
%else
%bcond_without ldc_bootstrap
%endif
%bcond_with ldc_tests
Name: ldc
Version: 1.12.0
Version: 1.13.0
Release: 0
Summary: The LLVM D Compiler
License: BSD-3-Clause AND Artistic-1.0
@@ -37,13 +43,15 @@ BuildRequires: libconfig++-devel
BuildRequires: libcurl-devel
BuildRequires: libstdc++-devel
BuildRequires: llvm-clang
BuildRequires: llvm-devel >= 3.7
BuildRequires: llvm-devel >= 3.9
BuildRequires: ncurses-devel
BuildRequires: sqlite3-devel
BuildRequires: zlib-devel
BuildRequires: pkgconfig(bash-completion)
# Should be installed, at least runtime
Recommends: ldc-phobos-devel = %{version}
Recommends: ldc-runtime-devel = %{version}
Recommends: %{name}-bash-completion
%if %{with ldc_bootstrap}
# v0.17.6 is the last version buildable with a C++ compiler, so use it for bootstrapping
Source10: https://github.com/ldc-developers/ldc/releases/download/v0.17.6/ldc-0.17.6-src.tar.gz
@@ -53,6 +61,7 @@ BuildRequires: gcc-c++
BuildRequires: gdb
%endif
%if %{without ldc_bootstrap}
BuildRequires: binutils-gold
BuildRequires: ldc
BuildRequires: ldc-phobos-devel
BuildRequires: ldc-runtime-devel
@@ -64,6 +73,8 @@ BuildRequires: python
BuildRequires: timezone
BuildRequires: unzip
%endif
# ppc64 is disabled due to boo#1113531
ExclusiveArch: %{ix86} x86_64 %arm aarch64
%description
LDC is an LLVM based compiler for the D programming language. It uses the
@@ -105,6 +116,16 @@ Requires: %{name}-runtime-devel = %{version}
This package contains the Phobos development files necessary for developing
with LDC.
%package bash-completion
Summary: LDC Bash completion
Group: System/Shells
Requires: %{name}-utils = %{version}
Requires: bash-completion
%description bash-completion
Optional dependency offering bash completion for ldc2
%prep
%setup -q -n ldc-%{version}-src
%patch0 -p1
@@ -155,6 +176,10 @@ popd
%install
%cmake_install
# Install bash completion in the right folder
install -d %{buildroot}%{_bashcompletionsdir}
mv %{buildroot}/etc/bash_completion.d/ldc2 %{buildroot}%{_bashcompletionsdir}
rmdir %{buildroot}/etc/bash_completion.d/
# Build man pages
help2man %{buildroot}%{_bindir}/ldc2 > ldc2.1 && gzip ldc2.1
help2man %{buildroot}%{_bindir}/ldmd2 > ldmd2.1 && gzip ldmd2.1
@@ -171,7 +196,6 @@ rm -rf %{buildroot}%{_libexecdir}/debug
%license LICENSE
%doc README.md
%{_mandir}/man1/*.1%{?ext_man}
%config %{_sysconfdir}/bash_completion.d/ldc2
%config %{_sysconfdir}/ldc2.conf
%{_bindir}/ldc*
%{_bindir}/ldmd2
@@ -184,8 +208,9 @@ rm -rf %{buildroot}%{_libexecdir}/debug
%{_libdir}/%{lname_runtime}-shared.so
%{_libdir}/%{lname_runtime}-debug-shared.so
%dir %{_includedir}/d
%{_includedir}/d/ldc
%{_includedir}/d/core
%{_includedir}/d/ldc
%{_includedir}/d/object.d
%files -n %{lname_phobos}%{so_ver}
%{_libdir}/%{lname_phobos}-shared.so.*
@@ -194,7 +219,12 @@ rm -rf %{buildroot}%{_libexecdir}/debug
%files phobos-devel
%{_libdir}/%{lname_phobos}-shared.so
%{_libdir}/%{lname_phobos}-debug-shared.so
%{_includedir}/d/std
%{_includedir}/d/etc
%{_includedir}/d/std
%files bash-completion
%dir %{_datadir}/bash-completion
%dir %{_datadir}/bash-completion/completions
%{_bashcompletionsdir}/ldc2
%changelog