svnnotify.spec 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. ##
  2. ## svnnotify.spec -- OpenPKG RPM Package Specification
  3. ## Copyright (c) 2000-2008 OpenPKG Foundation e.V. <http://openpkg.net/>
  4. ##
  5. ## Permission to use, copy, modify, and distribute this software for
  6. ## any purpose with or without fee is hereby granted, provided that
  7. ## the above copyright notice and this permission notice appear in all
  8. ## copies.
  9. ##
  10. ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  11. ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  12. ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  13. ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
  14. ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  15. ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  16. ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  17. ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  18. ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  19. ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  20. ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  21. ## SUCH DAMAGE.
  22. ##
  23. # package version
  24. %define V_svn_notify 2.70
  25. %define V_svn_notify_config 0.0907
  26. # package information
  27. Name: svnnotify
  28. Summary: Subversion Repository Notification
  29. URL: http://www.cpan.org/modules/by-module/SVN/
  30. Vendor: David Wheeler et al.
  31. Packager: OpenPKG Foundation e.V.
  32. Distribution: OpenPKG Community
  33. Class: EVAL
  34. Group: SCM
  35. License: GPL/Artistic
  36. Version: %{V_svn_notify}
  37. Release: 20080301
  38. # package options
  39. %option with_config yes
  40. # list of sources
  41. Source0: http://www.cpan.org/modules/by-module/SVN/SVN-Notify-%{V_svn_notify}.tar.gz
  42. Source1: http://www.cpan.org/modules/by-module/SVN/SVN-Notify-Config-%{V_svn_notify_config}.tar.gz
  43. Patch0: svnnotify.patch
  44. # build information
  45. Prefix: %{l_prefix}
  46. BuildRoot: %{l_buildroot}
  47. BuildPreReq: OpenPKG, openpkg >= 20060823, perl-openpkg
  48. PreReq: OpenPKG, openpkg >= 20060823, subversion
  49. BuildPreReq: perl, perl-net, perl-xml, perl-module
  50. PreReq: perl, perl-net, perl-xml, perl-module
  51. %if "%{with_config}" == "yes"
  52. BuildPreReq: yaml, yaml::with_perl = yes
  53. PreReq: yaml, yaml::with_perl = yes
  54. %endif
  55. AutoReq: no
  56. AutoReqProv: no
  57. %description
  58. svnnotify(1) and the underlying Perl module SVN::Notify may be used
  59. for sending Email messages for Subversion repository activity. There
  60. are a number of different modes supported, and SVN::Notify is fully
  61. sub-classable to easily add new functionality. By default, A list of
  62. all the files affected by the commit will be assembled and listed in
  63. a single message. An additional option allows diffs to be calculated
  64. for the changes and either appended to the message or added as an
  65. attachment.
  66. %track
  67. prog svnnotify:SVN-Notify = {
  68. version = %{V_svn_notify}
  69. url = http://www.cpan.org/modules/by-module/SVN/
  70. regex = SVN-Notify-(__VER__)\.tar\.gz
  71. }
  72. prog svnnotify:SVN-Notify-Config = {
  73. version = %{V_svn_notify_config}
  74. url = http://www.cpan.org/modules/by-module/SVN/
  75. regex = SVN-Notify-Config-(__VER__)\.tar\.gz
  76. }
  77. %prep
  78. %setup -q -c
  79. %if "%{with_config}" == "yes"
  80. %setup -q -D -T -a 1
  81. %endif
  82. %{l_sed} <%{PATCH0} -e 's;@l_prefix@;%{l_prefix};g' | %{l_patch} -p0 -b
  83. %build
  84. %{l_prefix}/bin/perl-openpkg prepare
  85. %{l_prefix}/bin/perl-openpkg -d %{SOURCE0} configure build
  86. %if "%{with_config}" == "yes"
  87. %{l_prefix}/bin/perl-openpkg -d %{SOURCE1} configure build
  88. %endif
  89. %install
  90. rm -rf $RPM_BUILD_ROOT
  91. %{l_prefix}/bin/perl-openpkg -d %{SOURCE0} install
  92. %if "%{with_config}" == "yes"
  93. %{l_prefix}/bin/perl-openpkg -d %{SOURCE1} install
  94. %endif
  95. %{l_prefix}/bin/perl-openpkg -F perl-openpkg-files fixate cleanup
  96. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
  97. %{l_files_std} `cat perl-openpkg-files`
  98. %files -f files
  99. %clean
  100. rm -rf $RPM_BUILD_ROOT