SPECS: xmlto.spec - current mktemp already respects $TMPDIR - avoi...

glen glen at pld-linux.org
Tue Dec 25 23:51:56 CET 2007


Author: glen                         Date: Tue Dec 25 22:51:56 2007 GMT
Module: SPECS                         Tag: HEAD
---- Log message:
- current mktemp already respects $TMPDIR
- avoid race in /tmp
- rel 2

---- Files affected:
SPECS:
   xmlto.spec (1.17 -> 1.18) 

---- Diffs:

================================================================
Index: SPECS/xmlto.spec
diff -u SPECS/xmlto.spec:1.17 SPECS/xmlto.spec:1.18
--- SPECS/xmlto.spec:1.17	Tue Dec 25 23:45:48 2007
+++ SPECS/xmlto.spec	Tue Dec 25 23:51:51 2007
@@ -3,7 +3,7 @@
 Summary(pl.UTF-8):	Narzędzie do konwersji plików XML do różnych formatów
 Name:		xmlto
 Version:	0.0.19
-Release:	1
+Release:	2
 Epoch:		0
 License:	GPL v2
 Group:		Applications/System
@@ -19,6 +19,7 @@
 Requires:	docbook-dtd42-xml
 Requires:	docbook-style-xsl >= 1.56.0
 Requires:	libxslt-progs
+Requires:	mktemp >= 1.5-19
 Requires:	passivetex >= 1.20
 # for getopt
 Requires:	util-linux
@@ -45,10 +46,8 @@
 
 cat > refentry2man <<'EOF'
 #!/bin/sh
-XMLTO_TMPFILE=${TMPDIR:-/tmp}/$(mktemp xmltoXXXXXX)
-XMLTO_TMPDIR=${TMPDIR:-/tmp}/$(mktemp xmltodirXXXXXX)
-rm -rf $XMLTO_TMPDIR
-mkdir -p $XMLTO_TMPDIR
+XMLTO_TMPFILE=$(mktemp xmltoXXXXXX)
+XMLTO_TMPDIR=$(mktemp -d xmltodirXXXXXX)
 cat - > $XMLTO_TMPFILE
 xmlto -o $XMLTO_TMPDIR man $XMLTO_TMPFILE >/dev/null
 cat $XMLTO_TMPDIR/*
@@ -57,7 +56,7 @@
 EOF
 
 %install
-rm -rf $RPM_BUILD_ROOT%{_bindir}
+rm -rf $RPM_BUILD_ROOT
 
 %{__make} install \
 	DESTDIR=$RPM_BUILD_ROOT
@@ -80,6 +79,11 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.18  2007-12-25 22:51:51  glen
+- current mktemp already respects $TMPDIR
+- avoid race in /tmp
+- rel 2
+
 Revision 1.17  2007-12-25 22:45:48  glen
 - heredoc that doesn't get expanded in shell
 
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SPECS/xmlto.spec?r1=1.17&r2=1.18&f=u



More information about the pld-cvs-commit mailing list