## Do several path fixups, removing unneeded @prefix@s and changing
## binaries install location from sbin to bin, to comply with the FHS
Index: stunnel4/tools/stunnel.conf-sample.in
===================================================================
--- stunnel4.orig/tools/stunnel.conf-sample.in
+++ stunnel4/tools/stunnel.conf-sample.in
@@ -4,15 +4,15 @@
 ; please read the manual and make sure you understand them
 
 ; certificate/key is needed in server mode and optional in client mode
-cert = @prefix@/etc/stunnel/mail.pem
-;key = @prefix@/etc/stunnel/mail.pem
+cert = /etc/ssl/certs/stunnel.pem
+;key = /etc/ssl/certs/stunnel.pem
 
 ; protocol version (all, SSLv2, SSLv3, TLSv1)
 sslVersion = SSLv3
 
 ; security enhancements for UNIX systems - comment them out on Win32
 ; for chroot a copy of some devices and files is needed within the jail
-chroot = @prefix@/var/lib/stunnel/
+chroot = @localstatedir@/lib/stunnel/
 setuid = nobody
 setgid = @DEFAULT_GROUP@
 ; PID is created inside the chroot jail
@@ -33,16 +33,16 @@
 ; CApath is located inside chroot jail
 ;CApath = /certs
 ; it's often easier to use CAfile
-;CAfile = @prefix@/etc/stunnel/certs.pem
+;CAfile = @sysconfdir@/stunnel/certs.pem
 ; don't forget to c_rehash CRLpath
 ; CRLpath is located inside chroot jail
 ;CRLpath = /crls
 ; alternatively CRLfile can be used
-;CRLfile = @prefix@/etc/stunnel/crls.pem
+;CRLfile = @sysconfdir@/stunnel/crls.pem
 
 ; debugging stuff (may useful for troubleshooting)
 ;debug = 7
-;output = stunnel.log
+;output = @localstatedir@/log/stunnel/stunnel.log
 
 ; SSL client mode
 ;client = yes
Index: stunnel4/tools/script.sh
===================================================================
--- stunnel4.orig/tools/script.sh
+++ stunnel4/tools/script.sh
@@ -2,7 +2,7 @@
 
 REMOTE_HOST="www.mirt.net:443"
 echo "client script connecting $REMOTE_HOST"
-/usr/local/bin/stunnel -fd 10 \
+/usr/bin/stunnel -fd 10 \
     11<&0 <<EOT 10<&0 0<&11 11<&-
 client=yes
 connect=$REMOTE_HOST
