From a0711bdb1af5a0099d9c98bc40dcd66fda5cb9fe Mon Sep 17 00:00:00 2001
From: Marcin Krol <hawk@tld-linux.org>
Date: Mon, 11 Jan 2021 22:06:53 +0100
Subject: [PATCH] - renamed configs, removed TLD devel, added debuginfo

---
 poldek-multilib.conf | 44 ------------------------
 poldek.conf          | 79 --------------------------------------------
 poldek.spec          | 14 +++++---
 tld-debuginfo.conf   | 52 +++++++++++++++++++++++++++++
 tld-multilib.conf    | 23 +++++++++++++
 tld.conf             | 48 +++++++++++++++++++++++++++
 6 files changed, 133 insertions(+), 127 deletions(-)
 delete mode 100644 poldek-multilib.conf
 delete mode 100644 poldek.conf
 create mode 100644 tld-debuginfo.conf
 create mode 100644 tld-multilib.conf
 create mode 100644 tld.conf

diff --git a/poldek-multilib.conf b/poldek-multilib.conf
deleted file mode 100644
index 6c31e72..0000000
--- a/poldek-multilib.conf
+++ /dev/null
@@ -1,44 +0,0 @@
-# TLD Linux -  http://www.tld-linux.org/
-
-_arch   = %ARCH%
-_prefix = ftp://ftp.tld-linux.org/TLD
-
-############################################################
-
-###
-# TLD Linux Stable
-[source]
-type   = pndir
-name   = ti-%{_arch}
-path   = %{_prefix}/stable/main/%{_arch}/RPMS/
-auto   = no
-autoup = no
-
-###
-# TLD Linux Stable, test packages
-[source]
-type   = pndir
-name   = ti-test-%{_arch}
-path   = %{_prefix}/stable/test/%{_arch}/RPMS/
-auto   = no
-autoup = no
-
-############################################################
-
-###
-# TLD Linux Devel
-[source]
-type   = pndir
-name   = ti-dev-%{_arch}
-path   = %{_prefix}/devel/main/%{_arch}/RPMS/
-auto   = no
-autoup = no
-
-###
-# TLD Linux Devel, test packages
-[source]
-type   = pndir
-name   = ti-dev-test-%{_arch}
-path   = %{_prefix}/devel/test/%{_arch}/RPMS/
-auto   = no
-autoup = no
diff --git a/poldek.conf b/poldek.conf
deleted file mode 100644
index ebbe65c..0000000
--- a/poldek.conf
+++ /dev/null
@@ -1,79 +0,0 @@
-# TLD Linux - https://tld-linux.org/
-
-_arch   = %ARCH%
-_prefix = ftp://ftp.tld-linux.org/TLD
-
-############################################################
-
-# TLD Linux Stable
-[source]
-type   = pndir
-name   = ti
-path   = %{_prefix}/stable/main/%{_arch}/RPMS/
-
-[source]
-type   = pndir
-name   = ti
-path   = %{_prefix}/stable/main/noarch/RPMS/
-
-# TLD Linux Stable, test packages
-[source]
-type   = pndir
-name   = ti-test
-path   = %{_prefix}/stable/test/%{_arch}/RPMS/
-auto   = no
-autoup = no
-
-[source]
-type   = pndir
-name   = ti-test
-path   = %{_prefix}/stable/test/noarch/RPMS/
-auto   = no
-autoup = no
-
-# TLD Linux Stable, archived packages
-[source]
-type   = pndir
-name   = ti-archive
-path   = %{_prefix}/stable/archive/%{_arch}/RPMS/
-auto   = no
-autoup = no
-
-[source]
-type   = pndir
-name   = ti-archive
-path   = %{_prefix}/stable/archive/noarch/RPMS/
-auto   = no
-autoup = no
-
-############################################################
-
-# TLD Linux Devel
-[source]
-type   = pndir
-name   = ti-dev
-path   = %{_prefix}/devel/main/%{_arch}/RPMS/
-auto   = no
-autoup = no
-
-[source]
-type   = pndir
-name   = ti-dev
-path   = %{_prefix}/devel/main/noarch/RPMS/
-auto   = no
-autoup = no
-
-# TLD Linux Devel, test packages
-[source]
-type   = pndir
-name   = ti-dev-test
-path   = %{_prefix}/devel/test/%{_arch}/RPMS/
-auto   = no
-autoup = no
-
-[source]
-type   = pndir
-name   = ti-dev-test
-path   = %{_prefix}/devel/test/noarch/RPMS/
-auto   = no
-autoup = no
diff --git a/poldek.spec b/poldek.spec
index 74bac3f..eb93caf 100644
--- a/poldek.spec
+++ b/poldek.spec
@@ -25,9 +25,10 @@ Group:		Applications/System
 #Source0:	http://poldek.pld-linux.org/download/snapshots/%{name}-%{version}-cvs%{snap}.tar.bz2
 Source0:	https://github.com/poldek-pm/poldek/releases/download/v%{version}/%{name}-%{version}.tar.xz
 # Source0-md5:	2759fe45bc50efb6084d5338d725411a
-Source1:	%{name}.conf
-Source2:	%{name}-multilib.conf
-Source3:	%{name}-config.sh
+Source1:	tld.conf
+Source2:	tld-multilib.conf
+Source3:	tld-debuginfo.conf
+Source4:	%{name}-config.sh
 Source5:	%{name}-aliases.conf
 Source6:	%{name}.desktop
 Source7:	%{name}.png
@@ -286,7 +287,7 @@ install -d $RPM_BUILD_ROOT/var/cache/%{name}
 %{__make} install \
 	DESTDIR=$RPM_BUILD_ROOT
 
-install -p %{SOURCE3} $RPM_BUILD_ROOT%{_bindir}/poldek-config
+install -p %{SOURCE4} $RPM_BUILD_ROOT%{_bindir}/poldek-config
 
 %if %{with python}
 %{__make} -C python install \
@@ -310,12 +311,16 @@ install -p %{SOURCE3} $RPM_BUILD_ROOT%{_bindir}/poldek-config
 	%define	tld_multilib_conf %{SOURCE2}
 %endif
 
+%define	tld_debuginfo_conf %{SOURCE3}
+
 %{__sed} -e 's|%%ARCH%%|%{ftp_arch}|g' < %{tld_conf} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/tld.conf
 
 %if 0%{?tld_multilib_conf:1}
 	%{__sed} 's|%%ARCH%%|%{ftp_alt_arch}|g' < %{tld_multilib_conf} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/tld-multilib.conf
 %endif
 
+%{__sed} -e 's|%%ARCH%%|%{ftp_arch}|g' < %{tld_debuginfo_conf} > $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/repos.d/tld-debuginfo.conf
+
 cp -p %{SOURCE5} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/cli.conf
 
 %if %{with imode}
@@ -418,6 +423,7 @@ fi
 %if 0%{?tld_multilib_conf:1}
 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/repos.d/tld-multilib.conf
 %endif
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/repos.d/tld-debuginfo.conf
 %attr(755,root,root) %{_bindir}/ipoldek
 %attr(755,root,root) %{_bindir}/poldek
 %attr(755,root,root) %{_bindir}/poldek-config
diff --git a/tld-debuginfo.conf b/tld-debuginfo.conf
new file mode 100644
index 0000000..9c4e385
--- /dev/null
+++ b/tld-debuginfo.conf
@@ -0,0 +1,52 @@
+# TLD Linux - https://tld-linux.org/
+
+_arch   = %ARCH%
+_prefix = ftp://ftp.tld-linux.org/TLD
+_branch = stable
+
+############################################################
+
+# TLD Linux, debuginfo
+[source]
+type   = pndir
+name   = ti
+path   = %{_prefix}/%{_branch}/main/%{_arch}/debuginfo/
+auto   = no
+autoup = no
+
+[source]
+type   = pndir
+name   = ti
+path   = %{_prefix}/%{_branch}/main/noarch/debuginfo/
+auto   = no
+autoup = no
+
+# TLD Linux, test packages, debuginfo
+[source]
+type   = pndir
+name   = ti-test
+path   = %{_prefix}/%{_branch}/test/%{_arch}/debuginfo/
+auto   = no
+autoup = no
+
+[source]
+type   = pndir
+name   = ti-test
+path   = %{_prefix}/%{_branch}/test/noarch/debuginfo/
+auto   = no
+autoup = no
+
+# TLD Linux, archived packages, debuginfo
+[source]
+type   = pndir
+name   = ti-archive
+path   = %{_prefix}/%{_branch}/archive/%{_arch}/debuginfo/
+auto   = no
+autoup = no
+
+[source]
+type   = pndir
+name   = ti-archive
+path   = %{_prefix}/%{_branch}/archive/noarch/debuginfo/
+auto   = no
+autoup = no
diff --git a/tld-multilib.conf b/tld-multilib.conf
new file mode 100644
index 0000000..810a4cd
--- /dev/null
+++ b/tld-multilib.conf
@@ -0,0 +1,23 @@
+# TLD Linux -  http://www.tld-linux.org/
+
+_arch   = %ARCH%
+_prefix = ftp://ftp.tld-linux.org/TLD
+_branch = stable
+
+############################################################
+
+# TLD Linux
+[source]
+type   = pndir
+name   = ti-%{_arch}
+path   = %{_prefix}/%{_branch}/main/%{_arch}/RPMS/
+auto   = no
+autoup = no
+
+# TLD Linux, test packages
+[source]
+type   = pndir
+name   = ti-test-%{_arch}
+path   = %{_prefix}/%{_branch}/test/%{_arch}/RPMS/
+auto   = no
+autoup = no
diff --git a/tld.conf b/tld.conf
new file mode 100644
index 0000000..1663d7f
--- /dev/null
+++ b/tld.conf
@@ -0,0 +1,48 @@
+# TLD Linux - https://tld-linux.org/
+
+_arch   = %ARCH%
+_prefix = ftp://ftp.tld-linux.org/TLD
+_branch = stable
+
+############################################################
+
+# TLD Linux
+[source]
+type   = pndir
+name   = ti
+path   = %{_prefix}/%{_branch}/main/%{_arch}/RPMS/
+
+[source]
+type   = pndir
+name   = ti
+path   = %{_prefix}/%{_branch}/main/noarch/RPMS/
+
+# TLD Linux, test packages
+[source]
+type   = pndir
+name   = ti-test
+path   = %{_prefix}/%{_branch}/test/%{_arch}/RPMS/
+auto   = no
+autoup = no
+
+[source]
+type   = pndir
+name   = ti-test
+path   = %{_prefix}/%{_branch}/test/noarch/RPMS/
+auto   = no
+autoup = no
+
+# TLD Linux, archived packages
+[source]
+type   = pndir
+name   = ti-archive
+path   = %{_prefix}/%{_branch}/archive/%{_arch}/RPMS/
+auto   = no
+autoup = no
+
+[source]
+type   = pndir
+name   = ti-archive
+path   = %{_prefix}/%{_branch}/archive/noarch/RPMS/
+auto   = no
+autoup = no
-- 
2.49.0