%define gitcommit 6052352 %define gitdate 20120526 %define patchlevel 0 Name: elixir Version: 0.5.0 Release: 1.%{gitdate}git%{gitcommit}%{?dist} Summary: A modern approach to programming for the Erlang VM Group: Development/Languages # See LEGAL (provided by upstream) for explaination/breakdown. License: ASL 2.0 and ERPL URL: http://elixir-lang.org/ # Source0 retrieved by pulling a Github tarball. # See: https://github.com/elixir-lang/elixir/tags Source0: %{name}-lang-%{name}-v%{version}-%{patchlevel}-g%{gitcommit}.tar.gz BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root BuildRequires: erlang-rebar Requires: erlang-erts >= R15B Requires: erlang-inets %description Elixir is a programming language built on top of the Erlang VM. As Erlang, it is a functional language built to support distributed, fault-tolerant, non-stop applications with hot code swapping. %prep %setup -q -n %{name}-lang-%{name}-%{gitcommit} sed -i -e "s/time //g" Makefile find -name '*.bat' -exec rm \{\} \; %build make %{?_smp_mflags} %check make test %install rm -rf %{buildroot} # Removed packaged binary (rebar) which we already have as a build dep rm rebar mkdir -p %{buildroot}/%{_datadir}/%{name}/%{version} cp -ra bin ebin include %{buildroot}/%{_datadir}/%{name}/%{version} mkdir -p %{buildroot}/%{_bindir} ln -s %{_datadir}/%{name}/%{version}/bin/{elixir,elixirc,iex} %{buildroot}/%{_bindir}/ %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) %doc LICENSE LEGAL %{_bindir}/elixir %{_bindir}/elixirc %{_bindir}/iex %{_datadir}/%{name} %changelog * Sat May 26 2012 Ricky Elrod - 0.5.0-1.20120526git6052352 - Initial build.