]> git.pld-linux.org Git - packages/ocaml-fuse.git/blobdiff - ocaml-fuse.spec
- typo
[packages/ocaml-fuse.git] / ocaml-fuse.spec
index 9f571c5c65365e4bb7eaed6a0105520c9c9b2f75..5bbe3c671f8913aa360586ed4e2bef23e962a791 100644 (file)
 #
 # Conditional build:
-%bcond_without opt             # build opt
+%bcond_without ocaml_opt       # native optimized binaries (bytecode is always built)
 
-%define                modname Fuse
-Summary:       %{modname} binding for OCaml
-Summary(pl.UTF-8):     Wiązania %{modname} dla OCamla
+# not yet available on x32 (ocaml 4.02.1), remove when upstream will support it
+%ifnarch %{ix86} %{x8664} %{arm} aarch64 ppc sparc sparcv9
+%undefine      with_ocaml_opt
+%endif
+
+%define                module  ocamlfuse
+Summary:       Fuse binding for OCaml
+Summary(pl.UTF-8):     Wiązania Fuse dla OCamla
 Name:          ocaml-fuse
-Version:       2.7
-Release:       1
+Version:       2.7.1
+Release:       5
 License:       GPL v2
 Group:         Libraries
-Source0:       http://downloads.sourceforge.net/ocamlfuse/ocamlfuse-%{version}-1.tar.gz
-# Source0-md5: cb9cbe4fafb36ead1b78faaacc26f3e3
-URL:           http://sourceforge.net/apps/mediawiki/ocamlfuse/
-BuildRequires: libfuse-devel
-BuildRequires: ocaml >= 3.08
+#Source0Download: https://github.com/astrada/ocamlfuse/releases
+Source0:       https://github.com/astrada/ocamlfuse/archive/v%{version}_cvs7/ocamlfuse-%{version}-7.tar.gz
+# Source0-md5: a5da871a0983b6723c6b9b735898fe34
+Patch0:                no-wrapped.patch
+URL:           https://github.com/astrada/ocamlfuse
+BuildRequires: libfuse-devel >= 2.7
+BuildRequires: ocaml >= 1:4.02.3
+BuildRequires: ocaml-dune >= 1.6
 BuildRequires: ocaml-findlib >= 1.4
 BuildRequires: ocaml-idl-devel >= 1.0.5
+BuildRequires: pkgconfig
 %requires_eq   ocaml-runtime
+Requires:      libfuse >= 2.7
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %define                debug_package   %{nil}
 
 %description
 OcamlFuse is a binding to the high-level part of the fuse library,
-allowing you to implement linux filesystems in OCaml. Other operating
-systems are not supported, if you think you can help we will be glad
-to hear.
+allowing you to implement Linux filesystems in OCaml.
 
 The main features of ocamlfuse are:
 - Multithreading: each callback runs in a separate ocaml thread, so
   that a slow call can't block the filesystem
 - Efficiency: read and write operations use the bigarray library
-  achieving very high troughput _ Ease of use: the fusexmp filesystem
-  (mimicking bindfs) is 73 lines of code, including in-memory extended
-  attributes using a hash table. The hello example is 42 lines of code.
+  achieving very high troughput
+- Ease of use: the fusexmp filesystem (mimicking bindfs) is 73 lines
+  of code, including in-memory extended attributes using a hash table.
+  The hello example is 42 lines of code.
 
 %description -l pl.UTF-8
-Pakiet ten zawiera binaria potrzebne do uruchamiania programów
-używających tej biblioteki.
+OcamlFuse to wiązania do wysokopoziomowej części biblioteki fuse,
+pozwalające implementować linuksowe systemy plików w OCamlu.
+
+Główne cechy ocamlfuse to:
+- wielowątkowość: każde wywołanie zwrotne działa w osobnym wątku
+  OCamla, więc powolne wywołanie nie zablokuje systemu plików
+- wydajność: operacje odczytu i zapisu wykorzystują bibliotekę
+  bigarray, osiągając dużą przepustowość
+- łatwość użycia: system plików fusexmp (naśladujący bindfs) ma
+  jedynie 73 linie kodu, włącznie z rozszerzonymi atrybutami w
+  pamięci, wykorzystującymi tablicę haszującą; przykład "hello
+  world" ma 42 linie kodu.
 
 %package devel
 Summary:       ocamlfuse binding for OCaml - development part
-Summary(pl.UTF-8):     Wiązania ocamlfuse dla OCamla - cześć programistyczna
+Summary(pl.UTF-8):     Wiązania ocamlfuse dla OCamla - część programistyczna
 Group:         Development/Libraries
 Requires:      %{name} = %{version}-%{release}
 %requires_eq   ocaml
+Requires:      libfuse-devel >= 2.7
+Requires:      ocaml-idl-devel >= 1.0.5
 
 %description devel
 This package contains files needed to develop OCaml programs using
-this library.
+Fuse library.
 
 %description devel -l pl.UTF-8
-Pakiet ten zawiera pliki niezbędne do tworzenia programów używających
-tej biblioteki.
+Pakiet ten zawiera pliki niezbędne do tworzenia programów w OCamlu,
+używających biblioteki Fuse.
 
 %prep
-%setup -qc
-mv ocamlfuse/* .
+%setup -q -n ocamlfuse-2.7.1_cvs7
+%patch0 -p1
 
 %build
-%{__make} -j1 all -C lib \
-       CC="%{__cc} %{rpmcflags} -fPIC"
+%{__make}
 
 %install
 rm -rf $RPM_BUILD_ROOT
-cd lib
-
-install -d $RPM_BUILD_ROOT%{_libdir}/ocaml/{%{modname},stublibs}
-install -p *.cm[ixa]* *.a dll*.so $RPM_BUILD_ROOT%{_libdir}/ocaml/%{modname}
-install -p dll*.so $RPM_BUILD_ROOT%{_libdir}/ocaml/stublibs
-
-install -d $RPM_BUILD_ROOT%{_libdir}/ocaml/site-lib/%{modname}
-cat > $RPM_BUILD_ROOT%{_libdir}/ocaml/site-lib/%{modname}/META <<EOF
-requires = ""
-version = "%{version}"
-directory = "+%{modname}"
-archive(byte) = "%{modname}.cma"
-archive(native) = "%{modname}.cmxa"
-linkopts = ""
-EOF
+
+%{__make} install \
+       DESTDIR=$RPM_BUILD_ROOT
+
+# sources
+%{__rm} $RPM_BUILD_ROOT%{_libdir}/ocaml/%{module}/*.ml
+# LICENSE is generic GPLv2 text, README.md packaged as %doc
+%{__rm} -r $RPM_BUILD_ROOT%{_prefix}/doc/%{module}
 
 %clean
 rm -rf $RPM_BUILD_ROOT
 
 %files
 %defattr(644,root,root,755)
-%attr(755,root,root) %{_libdir}/ocaml/stublibs/*.so
-%dir %{_libdir}/ocaml/%{modname}
-%attr(755,root,root) %{_libdir}/ocaml/%{modname}/dll*_stubs.so
+%doc README.md
+%dir %{_libdir}/ocaml/%{module}
+%{_libdir}/ocaml/%{module}/META
+%{_libdir}/ocaml/%{module}/*.cma
+%if %{with ocaml_opt}
+%attr(755,root,root) %{_libdir}/ocaml/%{module}/*.cmxs
+%endif
+%attr(755,root,root) %{_libdir}/ocaml/stublibs/dllfuse_stubs.so
 
 %files devel
 %defattr(644,root,root,755)
-%doc LICENSE lib/*.mli
-%dir %{_libdir}/ocaml/%{modname}
-%{_libdir}/ocaml/%{modname}/*.cm[ixa]*
-%{_libdir}/ocaml/%{modname}/*.a
-%{_libdir}/ocaml/site-lib/%{modname}
+%{_libdir}/ocaml/%{module}/dune-package
+%{_libdir}/ocaml/%{module}/opam
+%{_libdir}/ocaml/%{module}/*.cmi
+%{_libdir}/ocaml/%{module}/*.cmt
+%{_libdir}/ocaml/%{module}/*.cmti
+%{_libdir}/ocaml/%{module}/*.a
+%{_libdir}/ocaml/%{module}/*.mli
+%if %{with ocaml_opt}
+%{_libdir}/ocaml/%{module}/*.cmx
+%{_libdir}/ocaml/%{module}/*.cmxa
+%endif
This page took 0.07082 seconds and 4 git commands to generate.