summaryrefslogtreecommitdiffstats
path: root/t/data/SPECS/file-conflicts/p-2.spec
blob: 461e7ae7733cb867b97108a27b30eabfb415d1dc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
Summary: x
Name: p
Version: 2
Release: 1
License: x
BuildArch: noarch

%description
x

%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/etc/foo
mkdir -p $RPM_BUILD_ROOT/var
echo bar > $RPM_BUILD_ROOT/etc/foo/bar
echo boo > $RPM_BUILD_ROOT/etc/foo/boo
ln -s ../etc/foo $RPM_BUILD_ROOT/var/foo

%clean
rm -rf $RPM_BUILD_ROOT

%pretrans
if [ ! -L /var/foo ]; then
   echo "handling by hand /var/foo migration"
   mv /var/foo/* /etc/foo/
   rmdir /var/foo
   ln -s ../etc/foo /var/foo
fi

%files
/etc/foo
/var/foo