ocaml-camlp5-vl.spec 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153
  1. %global opt %(test -x %{_bindir}/ocamlopt && echo 1 || echo 0)
  2. %if !%{opt}
  3. %global debug_package %{nil}
  4. %endif
  5. Name: ocaml-camlp5
  6. Summary: Classical version of camlp4 OCaml preprocessor
  7. Summary(ja): Camlp4 OCaml プリプロセッサの古典的な実装
  8. Version: 6.12
  9. Release: 1%{?_dist_release}
  10. License: BSD
  11. Group: Development/Languages
  12. URL: http://camlp5.gforge.inria.fr/
  13. Source0: http://camlp5.gforge.inria.fr/distrib/src/camlp5-%{version}.tgz
  14. # Kill -warn-error A
  15. Patch0: camlp5-6.11-kill-warn-error.patch
  16. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  17. BuildRequires: ocaml
  18. Vendor: Project Vine
  19. Distribution: Vine Linux
  20. Packager: inagaki
  21. %global __ocaml_requires_opts -i Asttypes -i Parsetree -i Pa_extend
  22. %global __ocaml_provides_opts -i Dynlink -i Dynlinkaux -i Pa_extend
  23. %description
  24. Camlp5 is a preprocessor-pretty-printer of OCaml.
  25. It is the continuation of the classical camlp4 with new features.
  26. OCaml 3.10 and above have an official camlp4 which is incompatible
  27. with classical (<= 3.09) versions. You can find that in the
  28. ocaml-camlp4 package.
  29. %package devel
  30. Summary: Development files for %{name}
  31. Summary(ja): %{name} の開発用ファイル
  32. Group: Development/Libraries
  33. Requires: %{name} = %{version}-%{release}
  34. %description devel
  35. The %{name}-devel package contains libraries and signature files for
  36. developing applications that use %{name}.
  37. %prep
  38. %setup -q -n camlp5-%{version}
  39. %patch0 -p1
  40. # Build with debug information
  41. sed -i 's,WARNERR="",WARNERR="-g",' configure
  42. sed -i 's,-linkall,& -g,g' top/Makefile
  43. for fil in compile/compile.sh $(find . -name Makefile); do
  44. sed -i 's,\$[({]OCAMLN[})]c,& -g,;s,\$[({]OCAMLN[})]opt,& -g,;s,LINKFLAGS=,&-g ,' $fil
  45. done
  46. %build
  47. ./configure
  48. %if %opt
  49. # For ppc64 we need a larger stack than default to compile some files
  50. # because the stages in the OCaml compiler are not mutually tail
  51. # recursive.
  52. %ifarch ppc64 ppc64le
  53. ulimit -a
  54. ulimit -Hs 65536
  55. ulimit -Ss 65536
  56. %endif
  57. make world.opt
  58. %else
  59. make world
  60. %endif
  61. make -C doc/htmlp
  62. %install
  63. if [ -d $RPM_BUILD_ROOT ]; then rm -rf $RPM_BUILD_ROOT; fi
  64. mkdir -p $RPM_BUILD_ROOT%{_libdir}/ocaml
  65. mkdir -p $RPM_BUILD_ROOT%{_bindir}
  66. mkdir -p $RPM_BUILD_ROOT%{_mandir}
  67. make install \
  68. LIBDIR=$RPM_BUILD_ROOT%{_libdir}/ocaml \
  69. OLIBDIR=$RPM_BUILD_ROOT%{_libdir}/ocaml \
  70. BINDIR=$RPM_BUILD_ROOT%{_bindir} \
  71. MANDIR=$RPM_BUILD_ROOT%{_mandir}
  72. cp -p etc/META $RPM_BUILD_ROOT%{_libdir}/ocaml/camlp5
  73. rm -f doc/html/.cvsignore doc/htmlp/{.cvsignore,*.sh,Makefile,html2*}
  74. %clean
  75. if [ -d $RPM_BUILD_ROOT ]; then %{__rm} -rf $RPM_BUILD_ROOT; fi
  76. %files
  77. %defattr (-,root,root)
  78. %doc README LICENSE
  79. %{_libdir}/ocaml/camlp5
  80. %if %opt
  81. %exclude %{_libdir}/ocaml/camlp5/*.a
  82. %exclude %{_libdir}/ocaml/camlp5/*.cmxa
  83. %exclude %{_libdir}/ocaml/camlp5/*.cmx
  84. %endif
  85. %exclude %{_libdir}/ocaml/camlp5/*.mli
  86. %files devel
  87. %doc CHANGES ICHANGES DEVEL UPGRADING doc/html
  88. %if %opt
  89. %{_libdir}/ocaml/camlp5/*.a
  90. %{_libdir}/ocaml/camlp5/*.cmxa
  91. %{_libdir}/ocaml/camlp5/*.cmx
  92. %endif
  93. %{_libdir}/ocaml/camlp5/*.mli
  94. %{_bindir}/camlp5*
  95. %{_bindir}/mkcamlp5*
  96. %{_bindir}/ocpp5
  97. %{_mandir}/man1/*
  98. %changelog
  99. * Mon Jan 26 2015 Ryoichi INAGAKI <ryo1@toki.waseda.jp> - 6.12-1
  100. - changed package name
  101. - updated to 6.12
  102. - built with ocaml 4.02.1
  103. - split development files into devel subpackage
  104. * Thu Dec 26 2013 Yoji TOYODA <bsyamato@sea.plala.or.jp> - 6.11-1
  105. - new upstream release
  106. * Fri Apr 16 2010 Shu KONNO <owa@bg.wakwak.com> - 5.11-2
  107. - rebuilt with new tool chain and ocaml 3.11.0-2
  108. * Sat May 9 2009 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 5.11-1
  109. - new upstream release
  110. - built with ocaml 3.11.0
  111. - added Packager tag
  112. * Sun Aug 3 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 5.08-1
  113. - new upstream release
  114. - built with ocaml 3.10.2
  115. * Wed Feb 6 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 5.07-0vl2
  116. - rebuilt for VineSeed
  117. * Wed Feb 6 2008 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 5.07-0vl1
  118. - new upstream release
  119. - rebuilt with Ocaml 3.10.1
  120. * Sun Dec 30 2007 Shu KONNO <owa@bg.wakwak.com> - 5.00-0vl2
  121. - added option libdir to configure
  122. * Sun Sep 30 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 5.00-0vl1
  123. - initial package for Vine Linux