perl-Path-Tiny-vl.spec 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445
  1. # Run optional test
  2. %bcond_with perl_Path_Tiny_enables_optional_test
  3. Name: perl-Path-Tiny
  4. Version: 0.108
  5. Release: 3%{?_dist_release}
  6. Summary: File path utility
  7. License: ASL 2.0
  8. URL: https://metacpan.org/release/Path-Tiny
  9. Source0: https://cpan.metacpan.org/authors/id/D/DA/DAGOLDEN/Path-Tiny-%{version}.tar.gz
  10. Vendor: Project Vine
  11. Distribution: Vine Linux
  12. BuildArch: noarch
  13. # Module Build
  14. BuildRequires: coreutils
  15. BuildRequires: findutils
  16. BuildRequires: make
  17. BuildRequires: perl >= 2:5.26.2
  18. BuildRequires: perl(ExtUtils::MakeMaker)
  19. # Module Runtime
  20. BuildRequires: perl(Carp)
  21. BuildRequires: perl(Config)
  22. BuildRequires: perl(constant)
  23. BuildRequires: perl(Cwd)
  24. BuildRequires: perl(Digest)
  25. BuildRequires: perl(Digest::MD5)
  26. BuildRequires: perl(Digest::SHA)
  27. BuildRequires: perl(Encode)
  28. BuildRequires: perl(Exporter)
  29. BuildRequires: perl(Fcntl)
  30. BuildRequires: perl(File::Copy)
  31. BuildRequires: perl(File::Glob)
  32. BuildRequires: perl(File::Path)
  33. BuildRequires: perl(File::Spec)
  34. BuildRequires: perl(File::stat)
  35. BuildRequires: perl(File::Temp)
  36. BuildRequires: perl(overload)
  37. BuildRequires: perl(strict)
  38. BuildRequires: perl(threads)
  39. BuildRequires: perl(warnings)
  40. BuildRequires: perl(warnings::register)
  41. # Test Suite
  42. BuildRequires: perl(blib)
  43. BuildRequires: perl(File::Basename)
  44. BuildRequires: perl(File::Spec::Functions)
  45. BuildRequires: perl(File::Spec::Unix)
  46. BuildRequires: perl(File::Temp)
  47. BuildRequires: perl(lib)
  48. BuildRequires: perl(open)
  49. BuildRequires: perl(Test::More)
  50. %if %{with perl_Path_Tiny_enables_optional_test}
  51. # Optional Tests
  52. BuildRequires: perl(CPAN::Meta)
  53. BuildRequires: perl(CPAN::Meta::Prereqs)
  54. BuildRequires: perl(Test::FailWarnings)
  55. BuildRequires: perl(Test::MockRandom)
  56. %endif
  57. # Runtime
  58. Requires: perl(:MODULE_COMPAT_%(eval "`perl -V:version`"; echo $version))
  59. Requires: perl(Cwd)
  60. Requires: perl(Digest)
  61. Requires: perl(Digest::MD5)
  62. Requires: perl(Digest::SHA)
  63. Requires: perl(Encode)
  64. Requires: perl(Fcntl)
  65. Requires: perl(File::Copy)
  66. Requires: perl(File::Glob)
  67. Requires: perl(File::Path)
  68. Requires: perl(File::stat)
  69. Requires: perl(File::Temp)
  70. Requires: perl(threads)
  71. Requires: perl(warnings::register)
  72. # For performance and consistency
  73. %if !(0%{?rhel})
  74. BuildRequires: perl(PerlIO::utf8_strict)
  75. Requires: perl(PerlIO::utf8_strict)
  76. %endif
  77. #BuildRequires: perl(Unicode::UTF8)
  78. #Requires: perl(Unicode::UTF8)
  79. %description
  80. This module attempts to provide a small, fast utility for working with file
  81. paths. It is friendlier to use than File::Spec and provides easy access to
  82. functions from several other core file handling modules.
  83. It doesn't attempt to be as full-featured as IO::All or Path::Class, nor does
  84. it try to work for anything except Unix-like and Win32 platforms. Even then, it
  85. might break if you try something particularly obscure or tortuous.
  86. All paths are forced to have Unix-style forward slashes. Stringifying the
  87. object gives you back the path (after some clean up).
  88. File input/output methods flock handles before reading or writing, as
  89. appropriate.
  90. The *_utf8 methods (slurp_utf8, lines_utf8, etc.) operate in raw mode without
  91. CRLF translation.
  92. %prep
  93. %setup -q -n Path-Tiny-%{version}
  94. %build
  95. perl Makefile.PL INSTALLDIRS=vendor
  96. make %{?_smp_mflags}
  97. %install
  98. make pure_install DESTDIR=%{buildroot}
  99. find %{buildroot} -type f -name .packlist -delete
  100. %{_fixperms} -c %{buildroot}
  101. %check
  102. make test
  103. %files
  104. %license LICENSE
  105. %doc Changes CONTRIBUTING.mkdn README
  106. %{perl_vendorlib}/Path/
  107. %{_mandir}/man3/Path::Tiny.3*
  108. %changelog
  109. * Sun May 19 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 0.108-3
  110. - initial build for Vine Linux.
  111. * Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.108-2
  112. - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
  113. * Wed Aug 1 2018 Paul Howarth <paul@city-fan.org> - 0.108-1
  114. - Update to 0.108
  115. - Fixed a bug where failure to load optional modules would trigger an
  116. external $SIG{__DIE__} handler
  117. * Mon Jul 16 2018 Paul Howarth <paul@city-fan.org> - 0.106-1
  118. - Update to 0.106
  119. - The PERL_PATH_TINY_NO_FLOCK environment variable has been added to allow
  120. users to disable file locking (and any associated warnings)
  121. - Detection of unsupported 'flock' is no longer BSD-specific; this allows
  122. detecting and warning, for example, with the Luster filesystem on Linux
  123. - Improve reliability and diagnostics of tests run via 'do'
  124. * Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.104-7
  125. - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
  126. * Fri Jun 29 2018 Jitka Plesnikova <jplesnik@redhat.com> - 0.104-6
  127. - Perl 5.28 rebuild
  128. * Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.104-5
  129. - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
  130. * Fri Dec 08 2017 Petr Pisar <ppisar@redhat.com> - 0.104-4
  131. - Enable Test::MockRandom test
  132. * Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.104-3
  133. - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
  134. * Tue Jun 06 2017 Jitka Plesnikova <jplesnik@redhat.com> - 0.104-2
  135. - Perl 5.26 rebuild
  136. * Sat Feb 18 2017 Paul Howarth <paul@city-fan.org> - 0.104-1
  137. - Update to 0.104
  138. - The 'absolute' method now always returns an absolute path, even if a user
  139. provided a relative path for the base path; the old, odd behavior was
  140. documented, but people often don't read docs so the new behavior avoids
  141. surprises
  142. - Added 'cached_temp' method
  143. * Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 0.100-2
  144. - Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
  145. * Sun Jan 15 2017 Paul Howarth <paul@city-fan.org> - 0.100-1
  146. - Update to 0.100
  147. - Fixed tests for eventual removal of '.' from @INC in Perl
  148. - Fixed filehandle mode doc typo
  149. - Fixed doc typo in relative() that mentioned rel2abs instead of abs2rel
  150. * Mon Oct 10 2016 Paul Howarth <paul@city-fan.org> - 0.098-1
  151. - Update to 0.098
  152. - Added 'realpath' option for 'tempfile' and 'tempdir' for situations where
  153. an absolute temporary path just isn't enough
  154. * Sun Jul 3 2016 Paul Howarth <paul@city-fan.org> - 0.096-1
  155. - Update to 0.096
  156. - Improved method for hiding some modules during tests
  157. - BR: perl-generators unconditionally
  158. * Mon May 23 2016 Paul Howarth <paul@city-fan.org> - 0.094-1
  159. - Update to 0.094
  160. - Path::Tiny will prefer PerlIO::utf8_strict over encoding(UTF-8) if
  161. available and Unicode::UTF8 is not installed
  162. - The 'touch' method can now set the current time on files that aren't owned,
  163. as long as they are writeable
  164. - Improved consistency of symlink support inspection; now always looks at
  165. $Config{d_symlink}
  166. - Skips impossible test on 'msys' platform.
  167. - BR: perl-generators where possible
  168. - Drop redundant Group: tag
  169. * Mon May 16 2016 Jitka Plesnikova <jplesnik@redhat.com> - 0.090-2
  170. - Perl 5.24 rebuild
  171. * Tue May 3 2016 Paul Howarth <paul@city-fan.org> - 0.090-1
  172. - Update to 0.090
  173. - Fix spew_utf8 to allow array references as input
  174. * Mon Apr 18 2016 Paul Howarth <paul@city-fan.org> - 0.088-1
  175. - Update to 0.088
  176. - Fixed bugs in relative symlink resolution for realpath, spew and edit_lines
  177. - Symlink resolution will detect circular loops and throw an error
  178. * Mon Apr 4 2016 Paul Howarth <paul@city-fan.org> - 0.086-1
  179. - Update to 0.086
  180. - Improved documentation of copy and move
  181. - Simplify find command using -delete
  182. * Fri Mar 4 2016 Paul Howarth <paul@city-fan.org> - 0.084-1
  183. - Update to 0.084
  184. - Fixed relative() for the case with regex metacharacters in the path
  185. * Wed Mar 2 2016 Paul Howarth <paul@city-fan.org> - 0.082-1
  186. - Update to 0.082
  187. - The relative() method no longer uses File::Spec's buggy rel2abs method;
  188. the new Path::Tiny algorithm should be comparable and passes File::Spec
  189. rel2abs test cases, except that it correctly accounts for symlinks
  190. - Added 'edit' and 'edit_lines' plus _utf8 and _raw variants; this is
  191. similar to perl's -i flag (though without backups)
  192. - Fixed lines_utf8() with chomping for repeated empty lines
  193. - Fixed lines_utf8+chomp and relative() bugs on Windows
  194. - Documented that subclassing is not supported
  195. * Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 0.076-2
  196. - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
  197. * Mon Nov 16 2015 Paul Howarth <paul@city-fan.org> - 0.076-1
  198. - Update to 0.076
  199. - Tilde expansion on Windows was resulting in backslashes; now they are
  200. correctly normalized to forward slashes
  201. - Typos fixed
  202. - Fixed spewing to a symlink that crosses a filesystem boundary
  203. - Add Test::MockRandom to META as a recommended test prerequisite
  204. * Tue Jul 21 2015 Paul Howarth <paul@city-fan.org> - 0.072-1
  205. - Update to 0.072
  206. - Fixed incorrect error argument for File::Path functions (mkpath and
  207. remove_tree)
  208. * Mon Jul 20 2015 Paul Howarth <paul@city-fan.org> - 0.070-2
  209. - Fixed incorrect error argument for File::Path functions (mkpath and
  210. remove_tree) (GH#144)
  211. * Mon Jun 29 2015 Paul Howarth <paul@city-fan.org> - 0.070-1
  212. - Update to 0.070
  213. - The 'copy' method now returns the object for the copied file
  214. - The 'visit' method only dereferences the callback return value for scalar
  215. refs, avoiding some common bugs
  216. * Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.068-3
  217. - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
  218. * Sat Jun 06 2015 Jitka Plesnikova <jplesnik@redhat.com> - 0.068-2
  219. - Perl 5.22 rebuild
  220. * Tue Mar 24 2015 Paul Howarth <paul@city-fan.org> - 0.068-1
  221. - Update to 0.068
  222. - Added exclusive locking option to filehandle opens; spew now exclusively
  223. locks tempfile used for atomic writes
  224. * Fri Mar 6 2015 Paul Howarth <paul@city-fan.org> - 0.065-1
  225. - Update to 0.065
  226. - Added 'assert' method
  227. - Added 'visit' method
  228. - Added support for a negative count for 'lines' to get the last lines of a
  229. file
  230. - Fixed tilde expansion if path has spaces
  231. - Make realpath non-fatal if the parent path exists and only the final path
  232. component does not (was fatal on Windows and some Unixes)
  233. - Removed redundant locking on tempfile use for spewing
  234. - Work around File::Temp bugs on older ActiveState Windows Perls
  235. https://bugs.activestate.com/show_bug.cgi?id=104767
  236. - Fixed SYNOPSIS example
  237. * Fri Nov 14 2014 Paul Howarth <paul@city-fan.org> - 0.061-1
  238. - Update to 0.061
  239. - Fixed append_utf8 and append_raw with 'truncate' option
  240. * Thu Nov 6 2014 Paul Howarth <paul@city-fan.org> - 0.060-1
  241. - Update to 0.060
  242. - Added 'truncate' option to append for in-place replacement of file contents
  243. * Tue Oct 14 2014 Paul Howarth <paul@city-fan.org> - 0.059-1
  244. - Update to 0.059
  245. - Fixed precedence bug in the check for Unicode::UTF8
  246. * Thu Sep 25 2014 Paul Howarth <paul@city-fan.org> - 0.058-1
  247. - Update to 0.058
  248. - Added a 'sibling' method as a more efficient form of calling
  249. $path->parent->child(...).
  250. - Documentation for every method annotated with the version number of the
  251. last API change
  252. * Tue Sep 23 2014 Paul Howarth <paul@city-fan.org> - 0.057-1
  253. - Update to 0.057
  254. - On AIX, reads that default to locking would fail without write permissions,
  255. because locking needs write permissions; the fix is only to lock reads if
  256. write permissions exist, otherwise locking is skipped
  257. * Fri Aug 29 2014 Jitka Plesnikova <jplesnik@redhat.com> - 0.056-2
  258. - Perl 5.20 rebuild
  259. * Thu Aug 14 2014 Paul Howarth <paul@city-fan.org> - 0.056-1
  260. - Update to 0.056
  261. - Fixed problem throwing errors from 'remove'
  262. - The 'digest' method now takes a 'chunk_size' option to avoid slurping files
  263. entirely into memory
  264. - The 'dirname' method is deprecated due to exposing File::Spec
  265. inconsistencies
  266. - Use %%license
  267. * Tue Jul 1 2014 Paul Howarth <paul@city-fan.org> - 0.055-1
  268. - Update to 0.055
  269. - tempfile/tempdir won't warn if used as functions without arguments
  270. * Sat Jun 7 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.054-2
  271. - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
  272. * Tue May 6 2014 Paul Howarth <paul@city-fan.org> - 0.054-1
  273. - Update to 0.054
  274. - The 'is_file' method now does -e && ! -d and not -f because -f is often
  275. more restrictive than people intend or expect
  276. - Added 'chmod' method with symbolic chmod support ("a=r,u+rx")
  277. - The 'basename' method now takes a list of suffixes to remove before
  278. returning the name
  279. - Added FREEZE/THAW/TO_JSON serialization helpers
  280. - When constructing a Path::Tiny object from another, the original is
  281. returned unless it's a temp dir/file, which significantly speeds up calling
  282. path($path) if $path is already a Path::Tiny object
  283. - Constructing any path - e.g. with child() - with undef or zero-length
  284. parts throws an error instead of constructing an invalid path
  285. * Wed Jan 15 2014 Paul Howarth <paul@city-fan.org> - 0.052-1
  286. - Update to 0.052
  287. - Backslash-to-slash conversion now only happens on Windows (since backslash
  288. is legal on Unix, we must allow it)
  289. * Sat Dec 21 2013 Paul Howarth <paul@city-fan.org> - 0.051-1
  290. - Update to 0.051
  291. - Recursive iteration won't throw an exception if a directory is removed or
  292. unreadable during iteration
  293. * Thu Dec 12 2013 Paul Howarth <paul@city-fan.org> - 0.049-1
  294. - Update to 0.049
  295. - Added 'subsumes' method
  296. - The 'chomp' option for 'lines' will remove any end-of-line sequences fully
  297. instead of just chomping the last character
  298. - Fixed locking test on AIX
  299. - Revised locking tests for portability again: locks are now tested from a
  300. separate process
  301. - The 'flock' package will no longer indexed by PAUSE
  302. - Hides warnings and fixes possible fatal errors from pure-perl Cwd,
  303. particularly on MSWin32
  304. - Generates filename for atomic writes independent of thread-ID, which fixes
  305. crashing bug on Win32 when fork() is called
  306. * Fri Oct 18 2013 Paul Howarth <paul@city-fan.org> - 0.044-1
  307. - Update to 0.044
  308. - Fixed child path construction against the root path
  309. - Fixed path construction when a relative volume is provided as the first
  310. argument on Windows; e.g. path("C:", "lib") must be like path("C:lib"),
  311. not path("C:/lib")
  312. - On AIX, shared locking is replaced by exclusive locking on a R/W
  313. filehandle, as locking read handles is not supported
  314. * Mon Oct 14 2013 Paul Howarth <paul@city-fan.org> - 0.043-1
  315. - Update to 0.043
  316. - Calling 'absolute' on Windows will add the volume if it is missing (e.g.
  317. "/foo" will become "C:/foo"); this matches the behavior of
  318. File::Spec->rel2abs
  319. - Fixed t/00-report-prereqs.t for use with older versions of
  320. CPAN::Meta::Requirements
  321. * Sun Oct 13 2013 Paul Howarth <paul@city-fan.org> - 0.042-1
  322. - Update to 0.042
  323. - When 'realpath' can't be resolved (because intermediate directories don't
  324. exist), the exception now explains the error clearly instead of complaining
  325. about path() needing a defined, positive-length argument
  326. - On Windows, fixed resolution of relative paths with a volume, e.g. "C:foo"
  327. is now correctly translated into getdcwd on "C:" plus "foo"
  328. * Fri Oct 11 2013 Paul Howarth <paul@city-fan.org> - 0.041-1
  329. - Update to 0.041
  330. - Remove duplicate test dependency on File::Spec that triggers a CPAN.pm bug
  331. * Wed Oct 9 2013 Paul Howarth <paul@city-fan.org> - 0.040-1
  332. - Update to 0.040
  333. - The 'filehandle' method now offers an option to return locked handles
  334. based on the file mode
  335. - The 'filehandle' method now respects default encoding set by the caller's
  336. open pragma
  337. * Wed Oct 2 2013 Paul Howarth <paul@city-fan.org> - 0.038-1
  338. - Update to 0.038
  339. - Added 'is_rootdir' method to simplify testing if a path is the root
  340. directory
  341. * Thu Sep 26 2013 Paul Howarth <paul@city-fan.org> - 0.037-1
  342. - Update to 0.037
  343. - No longer lists 'threads' as a prerequisite; if you have a threaded perl,
  344. you have it and if you've not, Path::Tiny doesn't care
  345. - Fixed for v5.8
  346. * Tue Sep 24 2013 Paul Howarth <paul@city-fan.org> - 0.035-1
  347. - Update to 0.035
  348. - Fixed flock warning on BSD that was broken with the autodie removal; now
  349. also applies to all BSD flavors
  350. * Tue Sep 24 2013 Paul Howarth <paul@city-fan.org> - 0.034-1
  351. - Update to 0.034
  352. - Exceptions are now Path::Tiny::Error objects, not autodie exceptions; this
  353. removes the last dependency on autodie, which allows us to support Perls as
  354. far back as v5.8.1
  355. - BSD/NFS flock fix was not backwards compatible before v5.14; this fixes it
  356. harder
  357. - Lowered ExtUtils::MakeMaker configure_requires version to 6.17
  358. * Thu Sep 12 2013 Paul Howarth <paul@city-fan.org> - 0.033-1
  359. - Update to 0.033
  360. - Perl on BSD may not support locking on an NFS filesystem: if this is
  361. detected, Path::Tiny warns and continues in an unsafe mode (the 'flock'
  362. warning category may be fatalized to die instead)
  363. - Added 'iterator' example showing defaults
  364. * Fri Sep 6 2013 Paul Howarth <paul@city-fan.org> - 0.032-1
  365. - Update to 0.032
  366. - Removed several test dependencies; Path::Tiny now only needs core modules,
  367. though some must be upgraded on old Perls
  368. * Tue Sep 3 2013 Paul Howarth <paul@city-fan.org> - 0.031-3
  369. - BR: perl(Config) for the test suite (#1003660)
  370. * Mon Sep 2 2013 Paul Howarth <paul@city-fan.org> - 0.031-2
  371. - Sanitize for Fedora submission
  372. * Mon Sep 2 2013 Paul Howarth <paul@city-fan.org> - 0.031-1
  373. - Initial RPM version