Skip to content

Commit 672a586

Browse files
committed
oops / cache dir
1 parent fd3e33f commit 672a586

File tree

1 file changed

+32
-32
lines changed

1 file changed

+32
-32
lines changed

packages/tdnf/SPECS/tdnf.spec

Lines changed: 32 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -136,11 +136,11 @@ cd build && make %{?_smp_mflags} check
136136
%install
137137
cd build && make DESTDIR=%{buildroot} install
138138
find %{buildroot} -name '*.a' -delete
139-
mkdir -p %{buildroot}/var/cache/tdnf
139+
mkdir -p %{buildroot}%{_prefix}/var/cache/tdnf
140140
mkdir -p %{buildroot}/%{_libdir}/systemd/system/
141141
ln -sf %{_bindir}/tdnf %{buildroot}%{_bindir}/tyum
142142
ln -sf %{_bindir}/tdnf %{buildroot}%{_bindir}/yum
143-
mv %{buildroot}/usr/lib/pkgconfig/tdnfcli.pc %{buildroot}/usr/lib/pkgconfig/tdnf-cli-libs.pc
143+
mv %{buildroot}%{_libdir}/pkgconfig/tdnfcli.pc %{buildroot}%{_libdir}/pkgconfig/tdnf-cli-libs.pc
144144
mkdir -p %{buildroot}/%{_tdnfpluginsdir}/tdnfrepogpgcheck
145145
mv %{buildroot}/%{_tdnfpluginsdir}/libtdnfrepogpgcheck.so %{buildroot}/%{_tdnfpluginsdir}/tdnfrepogpgcheck/libtdnfrepogpgcheck.so
146146
mv %{buildroot}/lib/systemd/system/ %{buildroot}/%{_libdir}/systemd/
@@ -150,43 +150,43 @@ python3 setup.py install --skip-build --prefix=%{_prefix} --root=%{buildroot}
150150
popd
151151
find %{buildroot} -name '*.pyc' -delete
152152

153-
# Pre-install
154-
%pre
153+
# # Pre-install
154+
# %pre
155155

156-
# First argument is 1 => New Installation
157-
# First argument is 2 => Upgrade
156+
# # First argument is 1 => New Installation
157+
# # First argument is 2 => Upgrade
158158

159-
# Post-install
160-
%post
159+
# # Post-install
160+
# %post
161161

162-
# First argument is 1 => New Installation
163-
# First argument is 2 => Upgrade
162+
# # First argument is 1 => New Installation
163+
# # First argument is 2 => Upgrade
164164

165-
/sbin/ldconfig
165+
# /sbin/ldconfig
166166

167-
%triggerin -- motd
168-
[ $2 -eq 1 ] || exit 0
169-
if [ $1 -eq 1 ]; then
170-
echo "detected install of tdnf/motd, enabling tdnf-cache-updateinfo.timer" >&2
171-
systemctl enable tdnf-cache-updateinfo.timer >/dev/null 2>&1 || :
172-
systemctl start tdnf-cache-updateinfo.timer >/dev/null 2>&1 || :
173-
elif [ $1 -eq 2 ]; then
174-
echo "detected upgrade of tdnf, daemon-reload" >&2
175-
systemctl daemon-reload >/dev/null 2>&1 || :
176-
fi
167+
# %triggerin -- motd
168+
# [ $2 -eq 1 ] || exit 0
169+
# if [ $1 -eq 1 ]; then
170+
# echo "detected install of tdnf/motd, enabling tdnf-cache-updateinfo.timer" >&2
171+
# systemctl enable tdnf-cache-updateinfo.timer >/dev/null 2>&1 || :
172+
# systemctl start tdnf-cache-updateinfo.timer >/dev/null 2>&1 || :
173+
# elif [ $1 -eq 2 ]; then
174+
# echo "detected upgrade of tdnf, daemon-reload" >&2
175+
# systemctl daemon-reload >/dev/null 2>&1 || :
176+
# fi
177177

178-
# Pre-uninstall
179-
%preun
178+
# # Pre-uninstall
179+
# %preun
180180

181-
# First argument is 0 => Uninstall
182-
# First argument is 1 => Upgrade
181+
# # First argument is 0 => Uninstall
182+
# # First argument is 1 => Upgrade
183183

184-
%triggerun -- motd
185-
[ $1 -eq 1 ] && [ $2 -eq 1 ] && exit 0
186-
echo "detected uninstall of tdnf/motd, disabling tdnf-cache-updateinfo.timer" >&2
187-
systemctl --no-reload disable tdnf-cache-updateinfo.timer >/dev/null 2>&1 || :
188-
systemctl stop tdnf-cache-updateinfo.timer >/dev/null 2>&1 || :
189-
rm -rf /var/cache/tdnf/cached-updateinfo.txt
184+
# %triggerun -- motd
185+
# [ $1 -eq 1 ] && [ $2 -eq 1 ] && exit 0
186+
# echo "detected uninstall of tdnf/motd, disabling tdnf-cache-updateinfo.timer" >&2
187+
# systemctl --no-reload disable tdnf-cache-updateinfo.timer >/dev/null 2>&1 || :
188+
# systemctl stop tdnf-cache-updateinfo.timer >/dev/null 2>&1 || :
189+
# rm -rf /var/cache/tdnf/cached-updateinfo.txt
190190

191191
# Post-uninstall
192192
# %postun
@@ -241,7 +241,7 @@ rm -rf /var/cache/tdnf/cached-updateinfo.txt
241241
%config %{_libdir}/systemd/system/tdnf-cache-updateinfo.service
242242
%config(noreplace) %{_libdir}/systemd/system/tdnf-cache-updateinfo.timer
243243
%config %{_sysconfdir}/motdgen.d/02-tdnf-updateinfo.sh
244-
%dir /var/cache/tdnf
244+
%dir %{_prefix}/var/cache/tdnf
245245
%{_datadir}/bash-completion/completions/tdnf
246246

247247
%files devel

0 commit comments

Comments
 (0)