diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000000000000000000000000000000000000..d87f5613ec4234f82f8eaeebc563711f587fdf88 --- /dev/null +++ b/.gitattributes @@ -0,0 +1 @@ +*.xz filter=lfs diff=lfs merge=lfs -text diff --git a/.lfsconfig b/.lfsconfig new file mode 100644 index 0000000000000000000000000000000000000000..461b79f45d1a9f22edd786c779f1e7ad6517ca46 --- /dev/null +++ b/.lfsconfig @@ -0,0 +1,2 @@ +[lfs] + url = https://artlfs.openeuler.openatom.cn/src-openEuler/foomatic-db diff --git a/foomatic-db-4.0-20200414.tar.gz b/foomatic-db-4.0-20200414.tar.gz deleted file mode 100644 index 2a7c096ecbd9f15870da3e2bf6169acfc65c9101..0000000000000000000000000000000000000000 Binary files a/foomatic-db-4.0-20200414.tar.gz and /dev/null differ diff --git a/foomatic-db-4.0-20250116.tar.xz b/foomatic-db-4.0-20250116.tar.xz new file mode 100644 index 0000000000000000000000000000000000000000..662b5295b0084666ef73146edaeb52b2374be3c5 --- /dev/null +++ b/foomatic-db-4.0-20250116.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:485d7316678b66131d80c3bba7c092a0ffaed3e9713bbfb9b7c235ff7d8250eb +size 7920796 diff --git a/foomatic-db.spec b/foomatic-db.spec index 89cafabaaa04964957e5d1b66a9385a3c40175bb..39fbf7fb17a30b56ab5e396d62afa7c425ba88a0 100644 --- a/foomatic-db.spec +++ b/foomatic-db.spec @@ -1,10 +1,13 @@ +%global dbver_rel 4.0 +%global dbver_snap 20250116 + Name: foomatic-db -Version: 4.0 -Release: 64.20220428 +Version: %{dbver_rel}.%{dbver_snap} +Release: 1 Summary: Database of printers and printer drivers License: GPL-2.0-or-later and MIT -Url: http://www.openprinting.org -Source0: http://www.openprinting.org/download/foomatic/foomatic-db-%{version}-20200414.tar.gz +Url: https://www.openprinting.org +Source0: https://www.openprinting.org/download/foomatic/foomatic-db-%{dbver_rel}-%{dbver_snap}.tar.xz Patch0000: foomatic-db-device-ids.patch Patch0001: foomatic-db-invalid.patch BuildArch: noarch @@ -29,42 +32,45 @@ Requires: cups sed foomatic-db-filesystem = %{version}-%{release} PPDs from printer manufacturers. %prep -%autosetup -n foomatic-db-20200414 -p1 -find -type d | xargs chmod g-s +%autosetup -n foomatic-db-%{dbver_snap} -p1 -cd db/source +pushd db/source for i in printer/*.xml do perl -pi -e 's,>gutenprint<,>gutenprint-ijs-simplified.5.2<,' $i done -find printer -name '*.xml' |xargs grep -l "splix"|xargs rm -vf +find printer -name '*.xml' |xargs -d '\n' grep -l "splix"|xargs -d '\n' rm -vf rm -f driver/splix.xml for x in zjs zjs-z1 zjs-z2 zjs-z3 oak oak-z1 hp qpdl lava kyo xqx slx hiperc hiperc-z1 hbpl2 do - find printer -name '*.xml' |xargs grep -l "foo2${x}"|xargs rm -vf + find printer -name '*.xml' |xargs -d '\n' grep -l "foo2${x}"|xargs -d '\n' rm -vf rm -f driver/foo2${x}.xml opt/foo2${x}-* done -for x in drv_x125 ml85p pbm2lwxl pbmtozjs bjc800j m2300w m2400w lm1100 pentaxpj pbm2l2030 \ - pbm2l7k lex5700 lex7000 c2050 c2070 cjet +for x in lm1100 pentaxpj pbm2l2030 pbm2l7k lex5700 lex7000 c2050 c2070 cjet do - find printer -name '*.xml' |xargs grep -l "${x}"|xargs rm -vf + find printer -name '*.xml' |xargs -d '\n' grep -l "${x}"|xargs -d '\n' rm -vf rm -vf driver/${x}.xml opt/${x}-* done -find printer -name '*.xml' |grep -E 'Samsung-CLP-610|Samsung-CLP-620'|xargs rm -vf -find printer -name '*.xml' |grep -E 'KONICA_MINOLTA-magicolor_2430_DL'|xargs rm -vf +for x in drv_x125 ml85p pbm2lwxl pbmtozjs bjc800j m2300w m2400w +do + find printer -name '*.xml' |xargs -d '\n' grep -l "${x}"|xargs -d '\n' rm -vf + rm -vf driver/${x}.xml opt/${x}-* +done + +find printer -name '*.xml' |grep -E 'Samsung-CLP-610|Samsung-CLP-620'|xargs -d '\n' rm -vf + +find printer -name '*.xml' |grep -E 'KONICA_MINOLTA-magicolor_2430_DL'|xargs -d '\n' rm -vf + rm -vf driver/ptouch.xml +rm -vf printer/Brother-PT-*.xml +rm -vf printer/Brother-QL-*.xml +rm -vf opt/Brother-Ptouch-*.xml +popd -for PRT in `ls printer/*.xml opt/*.xml`; do - nf=${PRT%.*} - if [[ $nf == "printer/Brother-PT-"* ]]||[[ $nf == "printer/Brother-QL-"* ]]||[[ $nf == "opt/Brother-Ptouch-"* ]];then - rm $PRT - fi -done -cd ../.. find db/source/PPD -type f -name '*.ppd' -exec sed -i 's,perl -p,sed,g' {} + %build @@ -73,8 +79,18 @@ find db/source/PPD -type f -name '*.ppd' -exec sed -i 's,perl -p,sed,g' {} + %install %make_install -find %{buildroot}%{_datadir}/foomatic/db/source/ -type f | xargs chmod 0644 -install -d %{buildroot}%{_datadir}/foomatic/db/source/PPD/Custom + +rm -f %{buildroot}%{_datadir}/foomatic/db/source/driver/{bjc6000a1,PM760p,PM820p,s400a1,sharp,Stc670pl,Stc670p,Stc680p,Stc760p,Stc777p,Stp720p,Stp870p}.upp.xml + +find %{buildroot}%{_datadir}/foomatic/db/source/ -type f | xargs -d '\n' chmod 0644 + +mkdir %{buildroot}%{_datadir}/foomatic/db/source/PPD/Custom + +rm -f %{buildroot}%{_datadir}/foomatic/db/source/PPD/Kyocera/*.htm \ + %{buildroot}%{_datadir}/cups/model/3-distribution + +# Convert absolute symlink to relative. +rm -f %{buildroot}%{_datadir}/cups/model/foomatic-db-ppds ln -sf ../../foomatic/db/source/PPD %{buildroot}%{_datadir}/cups/model/foomatic-db-ppds %files filesystem @@ -90,12 +106,10 @@ ln -sf ../../foomatic/db/source/PPD %{buildroot}%{_datadir}/cups/model/foomatic- %doc db/source/PPD/Kyocera/*.htm %doc README %{_datadir}/foomatic/db/oldprinterids -%{_datadir}/foomatic/db/source/{printer,driver,opt}/* +%{_datadir}/foomatic/db/source/printer/* +%{_datadir}/foomatic/db/source/driver/* +%{_datadir}/foomatic/db/source/opt/* %{_datadir}/foomatic/xmlschema -%exclude %{_datadir}/foomatic/db/source/driver/{bjc6000a1,PM760p,PM820p,s400a1,sharp,Stc670pl}.upp.xml -%exclude %{_datadir}/foomatic/db/source/driver/{Stc670p,Stc680p,Stc760p,Stc777p,Stp720p,Stp870p}.upp.xml -%exclude %{_datadir}/foomatic/db/source/PPD/Kyocera/*.htm -%exclude %{_datadir}/cups/model/{3-distribution,foomatic-db-ppds} %files ppds %doc COPYING @@ -103,6 +117,9 @@ ln -sf ../../foomatic/db/source/PPD %{buildroot}%{_datadir}/cups/model/foomatic- %{_datadir}/cups/model/foomatic-db-ppds %changelog +* Fri Jan 17 2025 Funda Wang - 4.0.20250116-1 +- 4.0-20250116 + * Thu Apr 28 2022 wangyueliang - 4.0-64.20220428 - Improve the project according to the requirements of compliance improvement. diff --git a/foomatic-db.yaml b/foomatic-db.yaml index caf4227ddbfa0dd4d131f554e078af213a76c12f..43eba0bc70e000736de09a9942f9e36c8f2e131a 100644 --- a/foomatic-db.yaml +++ b/foomatic-db.yaml @@ -1,4 +1,4 @@ -version-control: NA -src_repo: NA -tag_prefix: NA -seperator: NA +version-control: github +src_repo: OpenPrinting/foomatic-db +tag_prefix: +seperator: