generated from smedev/Template-for-SMEServer-Core-Perl
* Tue Feb 19 2013 Remi Collet <remi@fedoraproject.org> - 1.0.0-6
- fix metadata location
This commit is contained in:
parent
d682bb6ff8
commit
9b71bd5796
BIN
File_CSV-1.0.0.tgz
(Stored with Git LFS)
Normal file
BIN
File_CSV-1.0.0.tgz
(Stored with Git LFS)
Normal file
Binary file not shown.
2
Makefile
2
Makefile
@ -1,4 +1,4 @@
|
||||
NAME := ${REPO_NAME}
|
||||
NAME := php-pear-File-CSV
|
||||
SPECFILE = $(firstword $(wildcard *.spec))
|
||||
|
||||
define find-makefile-common
|
||||
|
18
README.md
18
README.md
@ -1,16 +1,22 @@
|
||||
# <img src="https://www.koozali.org/images/koozali/Logo/Png/Koozali_logo_2016.png" width="25%" vertical="auto" style="vertical-align:bottom"> ${REPO_NAME}
|
||||
# <img src="https://www.koozali.org/images/koozali/Logo/Png/Koozali_logo_2016.png" width="25%" vertical="auto" style="vertical-align:bottom"> php-pear-File-CSV
|
||||
|
||||
SMEServer Koozali local git repo for ${REPO_NAME}
|
||||
SMEServer Koozali local git repo for php-pear-File-CSV
|
||||
|
||||
## Documentation
|
||||
<br />https://metacpan.org/pod/${REPO_NAME}
|
||||
<br />https://pear.php.net/package/File_CSV
|
||||
|
||||
## Bugzilla
|
||||
CPAN bug report are [here](https://rt.cpan.org/Public/Dist/Display.html?Name=${REPO_NAME})
|
||||
CPAN bug report are [here](https://pear.php.net/bugs/search.php?search_for=&boolean=0&limit=10&order_by=&direction=ASC&cmd=display&status=Open&bug_type=All&package_name%5B%5D=File_CSV&php_os=&packagever=&phpver=&assign=&maintain=&author_email=&bug_age=0&bug_updated=0)
|
||||
|
||||
Show list of Koozali outstanding bugs: [here](https://bugs.koozali.org/buglist.cgi?component=${REPO_NAME}&product=SME%20Server%2011.X&query_format=advanced&limit=0&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&bug_status=CONFIRMED)
|
||||
Show list of Koozali outstanding bugs: [here](https://bugs.koozali.org/buglist.cgi?component=php-pear-File-CSV&product=SME%20Server%2011.X&query_format=advanced&limit=0&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&bug_status=CONFIRMED)
|
||||
|
||||
## Description
|
||||
|
||||
${REPO_DESCRIPTION}
|
||||
Read and write of CSV files as well as discovering the format the CSV file
|
||||
is in.
|
||||
|
||||
Supports headers and is excel compatible, i.e. ="0004" outputs as 0004
|
||||
(only read wise)
|
||||
|
||||
For more information on CSV: http://rfc.net/rfc4180.html
|
||||
|
||||
|
@ -1,55 +0,0 @@
|
||||
%define name ${REPO_NAME}
|
||||
%define version 1.0
|
||||
%define release 1
|
||||
Summary: This is what ${REPO_NAME} does.
|
||||
Name: %{name}
|
||||
Version: %{version}
|
||||
Release: %{release}%{?dist}
|
||||
Source: %{name}-%{version}.tar.gz
|
||||
License: GNU GPL version 2
|
||||
Group: SMEserver/addon
|
||||
BuildRoot: %{_tmppath}/%{name}-buildroot
|
||||
Prefix: %{_prefix}
|
||||
BuildArchitectures: noarch
|
||||
BuildRequires: e-smith-devtools
|
||||
Requires: e-smith-release >= 10.0
|
||||
AutoReqProv: no
|
||||
|
||||
%description
|
||||
${REPO_DESCRIPTION}
|
||||
|
||||
%changelog
|
||||
* Day MMMM DD YYYY <brianr@koozali.org> 1.0-1.sme
|
||||
- Initial code - create RPM [SME:99999]
|
||||
|
||||
%prep
|
||||
|
||||
%setup -q
|
||||
|
||||
%build
|
||||
perl createlinks
|
||||
|
||||
%install
|
||||
rm -rf $$RPM_BUILD_ROOT
|
||||
(cd root ; find . -depth -print | cpio -dump $$RPM_BUILD_ROOT)
|
||||
rm -f %{name}-%{version}-filelist
|
||||
/sbin/e-smith/genfilelist $$RPM_BUILD_ROOT \
|
||||
> %{name}-%{version}-filelist
|
||||
#echo "%doc COPYING" >> %{name}-%{version}-filelist
|
||||
#--dir <dir> 'attr(755,user,grp)' \
|
||||
#--file <file> 'attr(755,root,root)' \
|
||||
|
||||
%clean
|
||||
cd ..
|
||||
rm -rf %{name}-%{version}
|
||||
|
||||
%pre
|
||||
|
||||
%preun
|
||||
|
||||
%post
|
||||
|
||||
%postun
|
||||
#uninstall
|
||||
%files -f %{name}-%{version}-filelist
|
||||
%defattr(-,root,root)
|
70
file-csv-test.patch
Normal file
70
file-csv-test.patch
Normal file
@ -0,0 +1,70 @@
|
||||
--- File_CSV-1.0.0/tests/CSV/bug13332.phpt.orig 2012-01-29 20:07:14.000000000 +0100
|
||||
+++ File_CSV-1.0.0/tests/CSV/bug13332.phpt 2012-01-29 20:07:19.000000000 +0100
|
||||
@@ -19,34 +19,27 @@
|
||||
$csv[] = $tmp;
|
||||
}
|
||||
|
||||
-var_dump($csv);
|
||||
+print_r($csv);
|
||||
?>
|
||||
--EXPECT--
|
||||
-array(2) {
|
||||
- [0]=>
|
||||
- array(5) {
|
||||
- [0]=>
|
||||
- string(1) "1"
|
||||
- [1]=>
|
||||
- string(1) "2"
|
||||
- [2]=>
|
||||
- string(6) "Twenty"
|
||||
- [3]=>
|
||||
- string(35) "This is a test of a "quoted" value."
|
||||
- [4]=>
|
||||
- string(15) "There is no cow"
|
||||
- }
|
||||
- [1]=>
|
||||
- array(5) {
|
||||
- [0]=>
|
||||
- string(1) "2"
|
||||
- [1]=>
|
||||
- string(1) "4"
|
||||
- [2]=>
|
||||
- string(5) "Forty"
|
||||
- [3]=>
|
||||
- string(37) "Another "quoted value", with a comma."
|
||||
- [4]=>
|
||||
- string(14) "There is a cow"
|
||||
- }
|
||||
-}
|
||||
+Array
|
||||
+(
|
||||
+ [0] => Array
|
||||
+ (
|
||||
+ [0] => 1
|
||||
+ [1] => 2
|
||||
+ [2] => Twenty
|
||||
+ [3] => This is a test of a "quoted" value.
|
||||
+ [4] => There is no cow
|
||||
+ )
|
||||
+
|
||||
+ [1] => Array
|
||||
+ (
|
||||
+ [0] => 2
|
||||
+ [1] => 4
|
||||
+ [2] => Forty
|
||||
+ [3] => Another "quoted value", with a comma.
|
||||
+ [4] => There is a cow
|
||||
+ )
|
||||
+
|
||||
+)
|
||||
--- package.xml.orig 2012-01-29 20:08:48.000000000 +0100
|
||||
+++ package.xml 2012-01-29 20:09:06.000000000 +0100
|
||||
@@ -127,7 +127,7 @@
|
||||
<file md5sum="ecd67fa789344b9b1713fc8df8e8f2b0" name="tests/CSV/bug11526.csv" role="test" />
|
||||
<file md5sum="64e72728d716678a8483b9183811b84d" name="tests/CSV/bug11526.phpt" role="test" />
|
||||
<file md5sum="a23bce7b80e20b698e72ea9dae379f60" name="tests/CSV/bug13332.csv" role="test" />
|
||||
- <file md5sum="2982eb5ecfa4ce5eef2457dcd4bfd598" name="tests/CSV/bug13332.phpt" role="test" />
|
||||
+ <file name="tests/CSV/bug13332.phpt" role="test" />
|
||||
<file md5sum="3e9295c06548af5707cb9ae99b38632f" name="tests/CSV/bug14030.phpt" role="test" />
|
||||
<file md5sum="0c2da2f5898cbc86591862de8c349c90" name="tests/CSV/bug14118.csv" role="test" />
|
||||
<file md5sum="9830a96ef8dbcb4dbf785fcb1e6b0be1" name="tests/CSV/bug14118.phpt" role="test" />
|
132
php-pear-File-CSV.spec
Normal file
132
php-pear-File-CSV.spec
Normal file
@ -0,0 +1,132 @@
|
||||
%{!?pear_metadir: %global pear_metadir %{pear_phpdir}}
|
||||
%{!?__pear: %{expand: %%global __pear %{_bindir}/pear}}
|
||||
%global pear_name File_CSV
|
||||
|
||||
# Tests are only run with rpmbuild --with tests
|
||||
# Can't be run in mock because of circular dependencies
|
||||
%global with_tests %{?_with_tests:1}%{!?_with_tests:0}
|
||||
|
||||
Name: php-pear-File-CSV
|
||||
Version: 1.0.0
|
||||
Release: 6%{?dist}
|
||||
Summary: Read and write of CSV files
|
||||
|
||||
Group: Development/Libraries
|
||||
License: BSD
|
||||
URL: http://pear.php.net/package/File_CSV
|
||||
Source0: http://pear.php.net/get/%{pear_name}-%{version}.tgz
|
||||
|
||||
# https://pear.php.net/bugs/19255 patch fails with php 5.4
|
||||
Patch0: file-csv-test.patch
|
||||
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
BuildArch: noarch
|
||||
BuildRequires: php-pear(PEAR) >= 1.7.0
|
||||
%if %{with_tests}
|
||||
BuildRequires: php-pear(File) >= 1.4.0
|
||||
%endif
|
||||
|
||||
Requires(post): %{__pear}
|
||||
Requires(postun): %{__pear}
|
||||
Requires: php-pear(PEAR) >= 1.7.0
|
||||
Requires: php-pear(File) >= 1.4.0
|
||||
Provides: php-pear(%{pear_name}) = %{version}
|
||||
|
||||
|
||||
%description
|
||||
Read and write of CSV files as well as discovering the format the CSV file
|
||||
is in.
|
||||
|
||||
Supports headers and is excel compatible, i.e. ="0004" outputs as 0004
|
||||
(only read wise)
|
||||
|
||||
For more information on CSV: http://rfc.net/rfc4180.html
|
||||
|
||||
|
||||
%prep
|
||||
%setup -q -c
|
||||
|
||||
%patch0 -p0 -b .tests
|
||||
|
||||
cd %{pear_name}-%{version}
|
||||
# Package is V2
|
||||
mv ../package.xml %{name}.xml
|
||||
|
||||
|
||||
%build
|
||||
cd %{pear_name}-%{version}
|
||||
# Empty build section, most likely nothing required.
|
||||
|
||||
|
||||
%install
|
||||
cd %{pear_name}-%{version}
|
||||
rm -rf %{buildroot}
|
||||
%{__pear} install --nodeps --packagingroot %{buildroot} %{name}.xml
|
||||
|
||||
# Clean up unnecessary files
|
||||
rm -rf %{buildroot}%{pear_metadir}/.??*
|
||||
|
||||
# Install XML package description
|
||||
mkdir -p %{buildroot}%{pear_xmldir}
|
||||
install -pm 644 %{name}.xml %{buildroot}%{pear_xmldir}
|
||||
|
||||
|
||||
%check
|
||||
cd %{pear_name}-%{version}
|
||||
%if %{with_tests}
|
||||
%{__pear} \
|
||||
run-tests \
|
||||
--recur \
|
||||
--ini "-d include_path=%{buildroot}%{pear_phpdir}:%{pear_phpdir}" \
|
||||
tests | tee ../tests.log
|
||||
grep "FAILED TESTS" ../tests.log && exit 1
|
||||
%else
|
||||
echo 'Test suite disabled (missing "--with test" option)'
|
||||
%endif
|
||||
|
||||
|
||||
%clean
|
||||
rm -rf %{buildroot}
|
||||
|
||||
|
||||
%post
|
||||
%{__pear} install --nodeps --soft --force --register-only \
|
||||
%{pear_xmldir}/%{name}.xml >/dev/null || :
|
||||
|
||||
|
||||
%postun
|
||||
if [ $1 -eq 0 ] ; then
|
||||
%{__pear} uninstall --nodeps --ignore-errors --register-only \
|
||||
pear.php.net/%{pear_name} >/dev/null || :
|
||||
fi
|
||||
|
||||
|
||||
%files
|
||||
%defattr(-,root,root,-)
|
||||
%doc %{pear_docdir}/%{pear_name}
|
||||
%{pear_xmldir}/%{name}.xml
|
||||
%{pear_phpdir}/File/CSV.php
|
||||
%{pear_testdir}/%{pear_name}
|
||||
|
||||
|
||||
%changelog
|
||||
* Tue Feb 19 2013 Remi Collet <remi@fedoraproject.org> - 1.0.0-6
|
||||
- fix metadata location
|
||||
|
||||
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.0-5
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
|
||||
|
||||
* Tue Aug 14 2012 Remi Collet <remi@fedoraproject.org> - 1.0.0-4
|
||||
- rebuilt for new pear_testdir
|
||||
|
||||
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.0-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
|
||||
|
||||
* Mon Mar 05 2012 Remi Collet <remi@fedoraproject.org> - 1.0.0-2
|
||||
- spec cleanups
|
||||
- patch for test which fails with php 5.4
|
||||
https://pear.php.net/bugs/19255
|
||||
|
||||
* Sat Mar 19 2011 Remi Collet <Fedora@FamilleCollet.com> - 1.0.0-1
|
||||
- initial package
|
||||
|
Loading…
Reference in New Issue
Block a user