Ver código fonte

new package: mono 0.91 (Unix .NET Development Framework)

Ralf S. Engelschall 21 anos atrás
pai
commit
0f3267c23e
2 arquivos alterados com 168 adições e 0 exclusões
  1. 38 0
      mono/mono.patch
  2. 130 0
      mono/mono.spec

+ 38 - 0
mono/mono.patch

@@ -0,0 +1,38 @@
+Crual hack to get Mono packaged, at least partly. As of Mono 0.91, the
+"make install" fails in runtime/net_*/ dirs with the error "Unhandled
+Exception: System.DllNotFoundException: libc". The following patch just
+skips this install step -- as a side-effect some essential parts of the
+package might be missing.
+
+Index: runtime/net_1_1/Makefile.in
+--- runtime/net_1_1/Makefile.in.orig	2004-05-04 23:51:12.000000000 +0200
++++ runtime/net_1_1/Makefile.in	2004-05-07 11:36:45.000000000 +0200
+@@ -354,12 +354,6 @@
+ all-local: $(gac_assemblies)
+ 
+ install-data-local:
+-	@if test -n '$(gac_assemblies)'; then \
+-	  for i in ''$(gac_assemblies); do \
+-	    echo "MONO_PATH=$(srcdir) $(mono_runtime) --config ../../data/config $(gacutil) /i $(srcdir)/$$i /f /package 1.0 /root $(DESTDIR)$(libdir)" ; \
+-	    MONO_PATH=$(srcdir) \
+-	      $(LIBTOOL) --mode=execute $(mono_runtime) --config ../../data/config $(gacutil) /i $(srcdir)/$$i /f /package 1.0 /root $(DESTDIR)$(libdir) || exit 1 ; \
+-	  done; fi
+ 
+ uninstall-local:
+ 	@if test -n '$(gac_assemblies_list)'; then \
+Index: runtime/net_2_0/Makefile.in
+--- runtime/net_2_0/Makefile.in.orig	2004-05-04 23:51:13.000000000 +0200
++++ runtime/net_2_0/Makefile.in	2004-05-07 11:36:56.000000000 +0200
+@@ -355,12 +355,6 @@
+ all-local: $(gac_assemblies)
+ 
+ install-data-local:
+-	@if test -n '$(gac_assemblies)'; then \
+-	  for i in ''$(gac_assemblies); do \
+-	    echo "MONO_PATH=$(srcdir)/../net_1_1 $(mono_runtime) --config ../../data/config $(gacutil) /i $(srcdir)/$$i /f /package 2.0 /root $(DESTDIR)$(libdir)" ; \
+-	    MONO_PATH=$(srcdir)/../net_1_1 \
+-	      $(LIBTOOL) --mode=execute $(mono_runtime)  --config ../../data/config  $(gacutil) /i $(srcdir)/$$i /f /package 2.0 /root $(DESTDIR)$(libdir) || exit 1 ; \
+-	  done; fi
+ 
+ uninstall-local:
+ 	@if test -n '$(gac_assemblies_list)'; then \

+ 130 - 0
mono/mono.spec

@@ -0,0 +1,130 @@
+##
+##  mono.spec -- OpenPKG RPM Specification
+##  Copyright (c) 2000-2004 The OpenPKG Project <http://www.openpkg.org/>
+##  Copyright (c) 2000-2004 Ralf S. Engelschall <rse@engelschall.com>
+##  Copyright (c) 2000-2004 Cable & Wireless <http://www.cw.com/>
+##
+##  Permission to use, copy, modify, and distribute this software for
+##  any purpose with or without fee is hereby granted, provided that
+##  the above copyright notice and this permission notice appear in all
+##  copies.
+##
+##  THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
+##  WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+##  MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+##  IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
+##  CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+##  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+##  LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
+##  USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+##  ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+##  OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
+##  OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+##  SUCH DAMAGE.
+##
+
+#   package information
+Name:         mono
+Summary:      Unix .NET Development Framework
+URL:          http://www.go-mono.com/
+Vendor:       The Mono Project
+Packager:     The OpenPKG Project
+Distribution: OpenPKG
+Class:        JUNK
+Group:        Language
+License:      GPL
+Version:      0.91
+Release:      20040507
+
+#   list of sources
+Source0:      http://www.go-mono.com/archive/beta1/mono-%{version}.tar.gz
+Patch0:       mono.patch
+
+#   build information
+Prefix:       %{l_prefix}
+BuildRoot:    %{l_buildroot}
+BuildPreReq:  OpenPKG, openpkg >= 20040130, pkgconfig
+PreReq:       OpenPKG, openpkg >= 20040130
+BuildPreReq:  glib2, glib2::with_threads = yes
+PreReq:       glib2, glib2::with_threads = yes
+AutoReq:      no
+AutoReqProv:  no
+
+%description
+     The Mono project is an open source effort to create a free
+     implementation of the .NET Development Framework. Mono includes
+     a compiler for the C# language, a Common Language Runtime (CLR)
+     for the Common Language Infrastructure (CLI) and a set of class
+     libraries. The runtime can be embedded into your application. It
+     implements both ADO.NET and ASP.NET.
+
+%track
+    prog mono = {
+        version   = %{version}
+        url       = http://www.go-mono.com/download.html
+        regex     = mono-(__VER__)\.tar\.gz
+    }
+
+%prep
+    %setup -q
+    %patch -p0
+
+%build
+    #   trick configure to not use truncl(3)
+    #   because this is not available everywhere,
+    #   although sometimes defined in <math.h>
+    ( echo "ac_cv_header_aio_h=no"
+      echo "ac_cv_func_truncl=no"
+      echo "ac_cv_truncl=no"
+      echo "ac_cv_lib_sunmath_aintl=no"
+    ) >config.cache
+    %{l_shtool} subst \
+        -e 's;truncl(0\.0);notexisting();' \
+        configure
+
+    #   configure program
+    CC="%{l_cc}" \
+    CFLAGS="%{l_cflags -O}" \
+    CPPFLAGS="%{l_cppflags}" \
+    LDFLAGS="%{l_ldflags}" \
+    ./configure \
+        --cache-file=./config.cache \
+        --prefix=%{l_prefix} \
+        --bindir=%{l_prefix}/libexec/mono \
+        --with-gc=included \
+        --with-jit=yes \
+        --disable-shared
+
+    #   build program
+    %{l_make} %{l_mflags -O}
+
+%install
+    #   install program
+    rm -rf $RPM_BUILD_ROOT
+    %{l_make} %{l_mflags} install AM_MAKEFLAGS="DESTDIR=$RPM_BUILD_ROOT"
+
+    #   activate executables
+    %{l_shtool} mkdir -f -p -m 755 \
+        $RPM_BUILD_ROOT%{l_prefix}/bin
+    for bin in `cd $RPM_BUILD_ROOT%{l_prefix}/libexec/mono && echo *`; do
+        case $bin in
+            *.exe ) continue ;;
+        esac
+        ln  $RPM_BUILD_ROOT%{l_prefix}/libexec/mono/$bin \
+            $RPM_BUILD_ROOT%{l_prefix}/bin/$bin
+    done
+
+    #   strip down installation
+    strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true
+
+    #   determine installation files
+    %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
+        %{l_files_std} \
+        '%config %{l_prefix}/etc/mono/*' \
+        '%not %dir %{l_prefix}/lib/pkgconfig'
+
+%files -f files
+
+%clean
+    rm -rf $RPM_BUILD_ROOT
+