michael@112: ## michael@112: ## haxe.spec -- OpenPKG RPM Package Specification michael@112: ## Copyright (c) 2000-2008 OpenPKG Foundation e.V. michael@112: ## michael@112: ## Permission to use, copy, modify, and distribute this software for michael@112: ## any purpose with or without fee is hereby granted, provided that michael@112: ## the above copyright notice and this permission notice appear in all michael@112: ## copies. michael@112: ## michael@112: ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED michael@112: ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF michael@112: ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. michael@112: ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR michael@112: ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, michael@112: ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT michael@112: ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF michael@112: ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND michael@112: ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, michael@112: ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT michael@112: ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF michael@112: ## SUCH DAMAGE. michael@112: ## michael@112: michael@112: # package version michael@112: %define V_release 2.02 michael@113: %define V_snapshot 20090130 michael@112: michael@112: # package information michael@112: Name: haxe michael@112: Summary: Haxe Programming Language michael@112: URL: http://haxe.org/ michael@112: Vendor: Nicolas Cannasse, Motion Twin michael@112: Packager: OpenPKG Foundation e.V. michael@112: Distribution: OpenPKG Community michael@112: Class: EVAL michael@112: Group: Language michael@112: License: GPL/BSD michael@112: Version: %{V_release}.%{V_snapshot} michael@113: Release: 20090106 michael@112: michael@112: # list of sources michael@112: Source0: ftp://ftp.openpkg.org/sources/CPY/haxe/haxe-%{V_snapshot}.tar.bz2 michael@112: Source1: haxe.sh michael@112: Source2: haxe.vim michael@112: Patch0: haxe.patch michael@112: michael@112: # build information michael@112: Prefix: %{l_prefix} michael@112: BuildRoot: %{l_buildroot} michael@114: BuildPreReq: OpenPKG, openpkg >= 20060823, zlib, ocaml michael@114: PreReq: OpenPKG, openpkg >= 20060823, zlib michael@112: AutoReq: no michael@112: AutoReqProv: no michael@112: michael@112: %description michael@112: haXe (pronounced as hex) is a multi-platform programming language, michael@112: which can be compiled to Javascript, Flash, NekoVM and PHP. michael@112: michael@112: %track michael@112: prog haxe = { michael@112: version = %{V_release} michael@112: url = http://haxe.org/download michael@112: regex = haxe-(__VER__)-linux\.tar\.gz michael@112: } michael@112: michael@112: %prep michael@112: %setup -q -n haxe michael@112: %patch -p0 michael@112: michael@112: %build michael@112: %{l_shtool} subst \ michael@112: -e 's%"/usr/lib/libz.dylib".*"/lib/libz.so.1"%"%{l_prefix}/lib/libz.a"%' \ michael@112: haxe/doc/install.ml michael@113: %{l_shtool} subst \ michael@113: -e "s;\(let c_opts = .*-ccopt\);\1 -I %{l_prefix}/include;" \ michael@113: -e "s;\(let c_opts = .* else \"\);\1 -I %{l_prefix}/include;" \ michael@113: haxe/doc/install.ml michael@128: michael@128: %{l_shtool} subst \ michael@128: -e 's;haxe.exe;haxe;g' \ michael@128: haxe/doc/release.neko \ michael@128: haxe/doc/setup.cpp \ michael@128: haxe/haxe.vcproj \ michael@128: haxe/main.ml michael@128: michael@112: %{l_prefix}/bin/ocaml haxe/doc/install.ml michael@112: michael@112: %install michael@112: rm -rf $RPM_BUILD_ROOT michael@112: %{l_shtool} mkdir -f -p -m 755 \ michael@112: $RPM_BUILD_ROOT%{l_prefix}/bin \ michael@112: $RPM_BUILD_ROOT%{l_prefix}/libexec/haxe \ michael@112: $RPM_BUILD_ROOT%{l_prefix}/lib/haxe \ michael@112: $RPM_BUILD_ROOT%{l_prefix}/share/vim/syntax michael@112: %{l_shtool} install -c -m 755 %{l_value -s -a} \ michael@112: %{SOURCE haxe.sh} $RPM_BUILD_ROOT%{l_prefix}/bin/haxe michael@112: %{l_shtool} install -c -s -m 755 \ michael@112: bin/haxe $RPM_BUILD_ROOT%{l_prefix}/libexec/haxe/ michael@112: find haxe/std -name CVS -type d -print | xargs rm -rf michael@112: cp -rp haxe/std/* $RPM_BUILD_ROOT%{l_prefix}/lib/haxe/ michael@112: %{l_shtool} install -c -m 644 \ michael@112: %{SOURCE haxe.vim} $RPM_BUILD_ROOT%{l_prefix}/share/vim/syntax/ michael@112: %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std} michael@112: michael@112: %files -f files michael@112: michael@112: %clean michael@112: rm -rf $RPM_BUILD_ROOT michael@112: