elixir/elixir.spec
Matwey Kornilov 62eb668834 Accepting request 222665 from home:develop7:branches:devel:languages:erlang
New upstream release

- Update to 0.12.4
  * see CHANGELOG.md for backward incompatibilities and 
    enhancements

OBS-URL: https://build.opensuse.org/request/show/222665
OBS-URL: https://build.opensuse.org/package/show/devel:languages:erlang/elixir?expand=0&rev=6
2014-02-18 07:32:21 +00:00

96 lines
3.1 KiB
RPMSpec

#
# spec file for package
#
# Copyright (c) 2013 SUSE LINUX Products 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: elixir
Version: 0.12.4
Release: 1
License: Apache-2.0 and ErlPL-1.1
Summary: Functional meta-programming aware language built on top of the Erlang
Url: http://elixir-lang.org
Group: Development/Languages/Other
Source0: elixir-v%{version}.tar.bz2
Source1: ex_doc-master.tar.bz2
Source2: macros.elixir
BuildRequires: erlang make gcc
# required by Mix.SCM.Git see also (https://github.com/elixir-lang/elixir/issues/1386)
Requires: git >= 1.7
BuildRequires: git >= 1.7
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildArch: noarch
%description
Elixir is a functional meta-programming aware language built on top of the Erlang VM. It is a dynamic language with flexible syntax with macros support that leverages Erlang's abilities to build concurrent, distributed, fault-tolerant applications with hot code upgrades.
Elixir also provides first-class support for pattern matching, polymorphism via protocols (similar to Clojure's), aliases and associative data structures (usually known as dicts or hashes in other programming languages).
Finally, Elixir and Erlang share the same bytecode and data types. This means you can invoke Erlang code from Elixir (and vice-versa) without any conversion or performance hit. This allows a developer to mix the expressiveness of Elixir with the robustness and performance of Erlang.
%package doc
Summary: Documentation for elexir
Group: Documentation/Other
Requires: elexir
%description doc
Documentation for Elexir language.
%define elixirdir %{_prefix}/lib/elixir
%prep
%setup -q -b 1 -n %{name}-v%{version}
%build
# Make Elixir
make
# Make docs
ln -s ex_doc-master ../ex_doc
PATH=$PATH:$PWD/bin make -C ../ex_doc
make docs
%install
make install DESTDIR=%{buildroot} PREFIX=%{_prefix}
# Relink
for I in iex elixir elixirc mix
do
ln -sf %{elixirdir}/bin/$I %{buildroot}%{_bindir}/$I
done
install -D -m 0644 %{S:2} %{buildroot}%{_sysconfdir}/rpm/macros.elixir
%check
make test
%files
%defattr(-,root,root)
%dir %{elixirdir}
%dir %{elixirdir}/bin
%dir %{elixirdir}/lib
%{_bindir}/iex
%{_bindir}/elixir
%{_bindir}/elixirc
%{_bindir}/mix
%{elixirdir}/bin/iex
%{elixirdir}/bin/elixirc
%{elixirdir}/bin/mix
%{elixirdir}/bin/elixir
%{elixirdir}/lib/*
%config %{_sysconfdir}/rpm/macros.elixir
%files doc
%defattr(-,root,root)
%doc CHANGELOG.md README.md LICENSE LEGAL docs
%changelog