Accepting request 1127963 from home:matwey:branches:devel:languages:erlang

Use pregenerated documentation

OBS-URL: https://build.opensuse.org/request/show/1127963
OBS-URL: https://build.opensuse.org/package/show/devel:languages:erlang/elixir?expand=0&rev=90
This commit is contained in:
Matwey Kornilov 2023-11-25 14:26:16 +00:00 committed by Git OBS Bridge
parent 1a8ef9cb5a
commit 7c4a1f521c
6 changed files with 37 additions and 86 deletions

View File

@ -1,4 +0,0 @@
<multibuild>
<package>elixir-doc</package>
</multibuild>

3
elixir-1.15.7-doc.zip Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:115afa2842dd630dd15c6488849007b6f08bb661d072a812d53b11e5f4f6dfdf
size 4246858

View File

@ -1,15 +0,0 @@
-------------------------------------------------------------------
Mon Nov 13 06:46:25 UTC 2023 - Simon Lees <sflees@suse.de>
- swap to %autosetup
-------------------------------------------------------------------
Wed Dec 19 18:56:20 UTC 2018 - matwey.kornilov@gmail.com
- Set License to Apache-2.0.
I have not found where did ErlPL come from.
-------------------------------------------------------------------
Mon Dec 10 11:16:45 UTC 2018 - matwey.kornilov@gmail.com
- Add elixir-doc.changes

View File

@ -1,56 +0,0 @@
#
# spec file for package elixir-doc
#
# Copyright (c) 2023 SUSE LLC
#
# 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 https://bugs.opensuse.org/
#
Name: elixir-doc
Version: 1.15.7
Release: 0
Summary: Documentation for elixir
License: Apache-2.0
Group: Documentation/Other
URL: http://elixir-lang.org
Source0: https://github.com/elixir-lang/elixir/archive/v%{version}.tar.gz#/elixir-%{version}.tar.gz
BuildRequires: elixir
BuildRequires: elixir-ex_doc
BuildRequires: unzip
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildArch: noarch
Requires: elixir = %{version}
%description
Documentation for the Elixir language.
%prep
%autosetup -n elixir-%{version} -p1
%build
# Elixir wants UTF-8 locale, force it
export LANG=en_US.UTF-8
ex_doc "Elixir" "%{version}" "lib/elixir/ebin" -m "Kernel" -u "https://github.com/elixir-lang/elixir" -o doc/elixir -p http://elixir-lang.org/docs.html
ex_doc "EEx" "%{version}" "lib/eex/ebin" -m "EEx" -u "https://github.com/elixir-lang/elixir" -o doc/eex -p http://elixir-lang.org/docs.html
ex_doc "Mix" "%{version}" "lib/mix/ebin" -m "Mix" -u "https://github.com/elixir-lang/elixir" -o doc/mix -p http://elixir-lang.org/docs.html
ex_doc "IEx" "%{version}" "lib/iex/ebin" -m "IEx" -u "https://github.com/elixir-lang/elixir" -o doc/iex -p http://elixir-lang.org/docs.html
ex_doc "ExUnit" "%{version}" "lib/ex_unit/ebin" -m "ExUint" -u "https://github.com/elixir-lang/elixir" -o doc/ex_unit -p http://elixir-lang.org/docs.html
ex_doc "Logger" "%{version}" "lib/logger/ebin" -m "Logger" -u "https://github.com/elixir-lang/elixir" -o doc/logger -p http://elixir-lang.org/docs.html
%install
%files
%defattr(-,root,root)
%doc doc
%changelog

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Tue Nov 21 15:47:29 UTC 2023 - Matwey Kornilov <matwey.kornilov@gmail.com>
- Use pregenerated documentation
-------------------------------------------------------------------
Mon Nov 13 06:45:28 UTC 2023 - Simon Lees <sflees@suse.de>

View File

@ -16,6 +16,8 @@
#
%define elixirdir %{_prefix}/lib/elixir
Name: elixir
Version: 1.15.7
Release: 0
@ -23,10 +25,12 @@ Summary: Functional meta-programming aware language built atop Erlang
License: Apache-2.0
Group: Development/Languages/Other
URL: http://elixir-lang.org
Source0: https://github.com/elixir-lang/elixir/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
Source0: https://github.com/elixir-lang/%{name}/archive/v%{version}/%{name}-%{version}.tar.gz
Source1: https://github.com/elixir-lang/%{name}/releases/download/v%{version}/Docs.zip#/%{name}-%{version}-doc.zip
Source2: macros.elixir
Patch0: 0001-Use-PID-valid-for-32-bit-systems-closes-12741.patch
Patch1: 0001-Use-PID-valid-for-32-bit-systems-followup-to-12741-1.patch
BuildRequires: fdupes
BuildRequires: gcc
BuildRequires: make
Requires: erlang >= 24
@ -54,19 +58,21 @@ Finally, Elixir and Erlang share the same bytecode and data types.
This means one can invoke Erlang code from Elixir (and vice-versa)
without any conversion or performance impact.
%package src
Summary: Elixir programming language sources
Group: Development/Sources
Requires: %{name} = %{version}
%package doc
Summary: Documentation for elixir
Group: Documentation/Other
BuildArch: noarch
Requires: elixir = %{version}
%description src
Elixir source code.
%define elixirdir %{_prefix}/lib/elixir
%description doc
Documentation for the Elixir language.
%prep
%autosetup -p1
unzip -o %{SOURCE1}
find doc \( -name ".build" -or -name ".ex_doc" \) -delete
%build
# Elixir wants UTF-8 locale, force it
export LANG=en_US.UTF-8
@ -75,14 +81,21 @@ make
%install
make install DESTDIR=%{buildroot} PREFIX=%{_prefix}
# install -D -m 0644
# Relink
mkdir -p %{buildroot}%{_bindir}
for I in iex elixir elixirc mix
do
ln -sf %{elixirdir}/bin/$I %{buildroot}%{_bindir}/$I
done
install -D -m 0644 %{S:2} %{buildroot}%{_rpmmacrodir}/macros.elixir
mkdir -p %{buildroot}%{_defaultdocdir}
cp -pa doc %{buildroot}%{_defaultdocdir}/elixir-doc
%fdupes -s %{buildroot}/%{_mandir}
%fdupes %{buildroot}/%{_prefix}
%check
export LANG=en_US.UTF-8
make test
@ -109,4 +122,9 @@ make test
%{elixirdir}/lib/*
%{_rpmmacrodir}/macros.elixir
%files doc
%defattr(-,root,root)
%license LICENSE
%{_defaultdocdir}/elixir-doc
%changelog