]> git.pld-linux.org Git - packages/ocaml-pxp.git/blob - ocaml-pxp.spec
- release 2 (by relup.sh)
[packages/ocaml-pxp.git] / ocaml-pxp.spec
1 #
2 # Conditional build:
3 %bcond_without  ocaml_opt       # skip building native optimized binaries (bytecode is always built)
4
5 # not yet available on x32 (ocaml 4.02.1), remove when upstream will support it
6 %ifnarch %{ix86} %{x8664} arm aarch64 ppc sparc sparcv9
7 %undefine       with_ocaml_opt
8 %endif
9
10 Summary:        Polimorphic XML Parser for OCaml
11 Summary(pl.UTF-8):      Polimorficzny analizator składniowy XML-a dla OCamla
12 Name:           ocaml-pxp
13 Version:        1.2.9
14 Release:        2
15 License:        distributable
16 Group:          Libraries
17 Source0:        http://download.camlcity.org/download/pxp-%{version}.tar.gz
18 # Source0-md5:  8002253eade813b8355500f4c59f8da8
19 URL:            http://projects.camlcity.org/projects/pxp.html
20 BuildRequires:  ocaml >= 1:3.09.2
21 BuildRequires:  ocaml-camlp4
22 BuildRequires:  ocaml-findlib
23 BuildRequires:  ocaml-ocamldoc-devel
24 BuildRequires:  ocaml-net-netstring-devel >= 3.6-2
25 BuildRequires:  ocaml-net-netsys-devel >= 3.6-2
26 BuildRequires:  ocaml-net-netunidata-devel
27 BuildRequires:  ocaml-ulex
28 BuildRequires:  sed >= 4.0
29 BuildConflicts: ocaml-wlex-devel
30 %requires_eq    ocaml-ulex
31 %requires_eq    ocaml-runtime
32 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33
34 %description
35 PXP is a validating parser for XML 1.0 which has been written entirely
36 in Objective Caml.
37
38 PXP means "Polymorphic XML Parser" and emphasizes its most useful
39 property: that the API is polymorphic and can be configured such that
40 different objects are used to store different types of elements.
41
42 %description -l pl.UTF-8
43 PXP jest walidującym analizatorem składniowym XML-a 1.0, napisanym w
44 całości w OCamlu.
45
46 PXP oznacza "Polymorphic XML Parser" (polimorficzny analizator
47 składniowy XML-a), co podkreśla jego najbardziej użyteczną własność:
48 API jest polimorficzne i może być skonfigurowane tak, że różne obiekty
49 są używane do przechowywania różnych typów elementów.
50
51 %package devel
52 Summary:        Polimorphic XML Parser for OCaml - development part
53 Summary(pl.UTF-8):      Polimorficzny analizator składniowy XML-a dla OCamla - cześć programistyczna
54 Group:          Development/Libraries
55 %requires_eq    ocaml
56 %requires_eq    ocaml-net-netstring-devel
57
58 %description devel
59 PXP is a validating parser for XML 1.0 which has been written entirely
60 in Objective Caml.
61
62 PXP means "Polymorphic XML parser" and emphasizes its most useful
63 property: that the API is polymorphic and can be configured such that
64 different objects are used to store different types of elements.
65
66 This package contains files needed to develop OCaml programs using the
67 PXP library.
68
69 %description devel -l pl.UTF-8
70 PXP jest walidującym analizatorem składniowym XML-a 1.0, napisanym w
71 całości w OCamlu.
72
73 PXP oznacza "Polymorphic XML Parser" (polimorficzny analizator
74 składniowy XML-a), co podkreśla jego najbardziej użyteczną własność:
75 API jest polimorficzne i może być skonfigurowane tak, że różne obiekty
76 są używane do przechowywania różnych typów elementów.
77
78 Pakiet ten zawiera pliki niezbędne do tworzenia programów używających
79 biblioteki PXP.
80
81 %prep
82 %setup -q -n pxp-%{version}
83
84 %build
85 ./configure \
86         -with-lex \
87         -with-ulex \
88         -without-wlex \
89         -with-pp
90
91 sed -i -e 's/-g//' Makefile.rules
92 %{__make} -j1 \
93         all %{?with_ocaml_opt:opt}
94
95 %install
96 rm -rf $RPM_BUILD_ROOT
97
98 install -d $RPM_BUILD_ROOT%{_libdir}/ocaml/{site-lib,pxp}
99 OCAMLFIND_DESTDIR=$RPM_BUILD_ROOT%{_libdir}/ocaml/site-lib %{__make} install
100 dir=`pwd`
101 cd $RPM_BUILD_ROOT%{_libdir}/ocaml/site-lib
102 for f in * ; do
103         echo 'directory = "+pxp"' >> $f/META
104         if [ "`echo $f/*.*`" != "$f/*.*" ]; then
105                 mv $f/*.* $RPM_BUILD_ROOT%{_libdir}/ocaml/pxp
106         fi
107 done
108 cd $dir
109
110 install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
111 cp -r examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
112
113 %clean
114 rm -rf $RPM_BUILD_ROOT
115
116 %files devel
117 %defattr(644,root,root,755)
118 %doc doc/README doc/SPEC
119 %doc doc/design.txt doc/manual/html
120 %dir %{_libdir}/ocaml/pxp
121 %{_libdir}/ocaml/pxp/*.cm[xi]
122 %{_libdir}/ocaml/pxp/*.cma
123 %{_libdir}/ocaml/pxp/*.cmo
124 %{_libdir}/ocaml/pxp/*.mli
125 %if %{with ocaml_opt}
126 %{_libdir}/ocaml/pxp/*.[ao]
127 %{_libdir}/ocaml/pxp/*.cmxa
128 %endif
129 %{_examplesdir}/%{name}-%{version}
130 %{_libdir}/ocaml/site-lib/*
This page took 0.119756 seconds and 3 git commands to generate.