+ln -s alpine $RPM_BUILD_ROOT%{_bindir}/pine
+
+$RPM_BUILD_ROOT%{_bindir}/alpine -conf > $RPM_BUILD_ROOT%{alpineconfdir}/alpine.conf
+cat <<EOF > $RPM_BUILD_ROOT%{alpineconfdir}/alpine.conf.fixed
+#
+# Alpine system-wide enforced configuration file - customize as needed
+#
+# This file holds the system-wide enforced values for alpine configuration
+# settings. Any values set in it will override values set in the
+# system-wide default configuration file (%{alpineconfdir}/alpine.conf) and
+# the user's own configuration file (~/.pinerc).
+# For more information on the format of this file, read the
+# comments at the top of %{alpineconfdir}/alpine.conf
+
+EOF
+
+%post
+if [ -f "%{alpineconfdir}/alpine.conf" -a -f "%{alpineconfdir}/alpine.conf.rpmnew" ]; then
+ mv %{alpineconfdir}/alpine.conf %{alpineconfdir}/alpine.conf.backup
+ alpine -P %{alpineconfdir}/alpine.conf.backup -conf > /etc/alpine/alpine.conf || exit 0
+fi