--- pmk-0.10.4.orig/debian/control +++ pmk-0.10.4/debian/control @@ -0,0 +1,21 @@ +Source: pmk +Section: devel +Priority: optional +Maintainer: Magnus Holmgren +Build-Depends: debhelper (>> 4.0.0), dpatch +Standards-Version: 3.7.3 +Vcs-Svn: svn://svn.kibibyte.se/pmk/trunk +Vcs-Browser: http://svn.kibibyte.se/pmk +Homepage: http://pmk.sourceforge.net + +Package: pmk +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, ucf (>= 0.8), gcc | c-compiler +Suggests: binutils, g++ +Description: utility to configure software sources + PMK is a utility which, like the popular GNU Autoconf, serves the + purpose of configuring the software sources on a variety of platforms. + Configuring consists of checking the environment for presence of libraries, + header files, programs, functions etc. Based on a simple config file, pmk + generates output files (e.g. config.h, Makefile etc.) using a set of + templates provided by the programmer. --- pmk-0.10.4.orig/debian/rules +++ pmk-0.10.4/debian/rules @@ -0,0 +1,84 @@ +#!/usr/bin/make -f +# Sample debian/rules that uses debhelper. +# GNU copyright 1997 to 1999 by Joey Hess. + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +include /usr/share/dpatch/dpatch.make + +CFLAGS = -pipe -Wall -g -DTMPDIR=\"\\\"/tmp\\\"\" + +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) + CFLAGS += -O0 + LDFLAGS = -s +else + CFLAGS += -O2 +endif +ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS))) + INSTALL_PROGRAM += -s +endif + +# Overrides for the PMK Makefile stuff +CC=gcc +DESTDIR=$(CURDIR)/debian/pmk + +export CFLAGS LDFLAGS CC + +configure: configure-stamp +configure-stamp: + dh_testdir + ./pmkcfg.sh -p /usr + touch configure-stamp + +build: build-stamp +build-stamp: patch configure-stamp + dh_testdir + + # Add here commands to compile the package. + $(MAKE) PREMAKE=pmk + touch build-stamp + +clean: clean-patched unpatch +clean-patched: + dh_testdir + dh_testroot + rm -f build-stamp + + # Add here commands to clean up after the build process. + [ ! -f Makefile ] || $(MAKE) distclean + rm -f configure-stamp + dh_clean + +install: build-stamp + dh_testdir + dh_testroot + dh_clean -k + dh_installdirs + + # Add here commands to install the package into debian/pmk. + $(MAKE) install DESTDIR=$(DESTDIR) MANDIR=/usr/share/man PREMAKE=pmk + +binary-indep: install + +# Build architecture-dependent files here. +binary-arch: install + dh_testdir + dh_testroot + dh_installchangelogs Changelog + dh_installdocs + dh_installexamples + dh_installman + dh_link + dh_strip + dh_compress + dh_fixperms + chmod -x $(DESTDIR)/usr/share/doc/pmk/examples/tests/plang_test.c + dh_installdeb + dh_shlibdeps + dh_gencontrol + dh_md5sums + dh_builddeb + +binary: binary-indep binary-arch +.PHONY: build clean binary-indep binary-arch binary install --- pmk-0.10.4.orig/debian/watch +++ pmk-0.10.4/debian/watch @@ -0,0 +1,3 @@ +version=3 + +http://sf.net/pmk/pmk-(\d+(?:\.\d+)+)\.tar\.gz debian uupdate --- pmk-0.10.4.orig/debian/pmk.postinst +++ pmk-0.10.4/debian/pmk.postinst @@ -0,0 +1,57 @@ +#! /bin/sh +# postinst script for pmk +# +# see: dh_installdeb(1) + +conffile=/etc/pmk/pmk.conf + +set -e +test $DEBIAN_SCRIPT_DEBUG && set -v -x + +if [ -e /usr/share/debconf/confmodule ]; then + . /usr/share/debconf/confmodule +fi + +case "$1" in + configure|reconfigure) + # Note that -s and -g are added by 25_pmksetup.dpatch; + # they are not documented in pmksetup(8). + tempfile=`mktemp -t pmksetup.XXXXXXXXXX` + settings="-u PREFIX=\"/usr\" \ + -u BIN_CC=\"/usr/bin/gcc\" \ + -u BIN_CXX=\"/usr/bin/g++\" \ + -u PATH_BIN=\"/usr/local/bin:/usr/bin:/bin\" \ + -u OS_ARCH=\"`dpkg --print-architecture`\"" + + if { if test $DEBIAN_SCRIPT_DEBUG; then pmksetup -V -s -g $settings; + else pmksetup -s -g $settings 2> /dev/null; fi } > $tempfile + then + ucf --three-way --debconf-ok $tempfile $conffile + rm -f $tempfile + ucfr pmk $conffile + else + rm -f $tempfile + exit 1 + fi + + # Clean out any remains of this package from the Debconf database + if [ -e /usr/share/debconf/confmodule ]; then + db_purge + fi + ;; + + abort-upgrade|abort-remove|abort-deconfigure) + ;; + + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 --- pmk-0.10.4.orig/debian/pmk.manpages +++ pmk-0.10.4/debian/pmk.manpages @@ -0,0 +1 @@ +man/* --- pmk-0.10.4.orig/debian/changelog +++ pmk-0.10.4/debian/changelog @@ -0,0 +1,190 @@ +pmk (0.10.4-1) unstable; urgency=low + + * New upstream release. + * debian/control: Add Homepage and Vcs-* fields. + * Drop 20_build_fixes.dpatch; GEN_FILES was fixed upstream and + I'll just pass PREMAKE=pmk to make for now. + * New maintainer email address. + * debian/copyright: Update copyright, license, authors, homepage, + current Debian maintainer. + * Bump Standards-Version to 3.7.3. No changes needed. + * Don't ignore potential "make distclean" errors. + + -- Magnus Holmgren Sat, 03 May 2008 19:58:21 +0200 + +pmk (0.10.2-2) unstable; urgency=low + + * Obey $DEBIAN_SCRIPT_DEBUG to facilitate postinst script debugging. + * Fix 25_pmksetup.dpatch so that pmksetup doesn't try to unlink "" on + error when writing to standard out. + * Depend on gcc | c-compiler, because pmksetup demands it (Closes: + #431948). + + -- Magnus Holmgren Sun, 05 Aug 2007 17:41:41 +0200 + +pmk (0.10.2-1) unstable; urgency=low + + * New upstream version. + · Drop 20_manpages.dpatch; incorporated upstream. + * debian/watch: Only match stable versions. + + -- Magnus Holmgren Mon, 16 Apr 2007 11:21:11 +0200 + +pmk (0.10.1-1) unstable; urgency=low + + * New maintainer (Closes: #411686). + * New upstream release. + + Fixes segfault in pmksetup (Closes: #328362). + * Fix manpage errors. + * Use ucf to manage pmk.conf - debconf no longer needed to ask whether + to replace pmk.conf (see README.Debian for details); get rid of + dependencies, templates and everything, but call db_purge in postinst. + * Remove dependency on pkg-config; pmk has built-in support nowadays. + * Remove /usr/bin/X11 from PATH_BIN setting; it's just a symlink to + /usr/bin nowadays. + * Properly escape quotes around values in the call to pmksetup in + postinst. + * Remove unnecessary and non-working variable assignments in the call + to pmksetup; in particular, setting OS_NAME to Debian/Linux makes + pmk fail to find its Linux OS information. + * Use dpatch to handle Debian patches. + * debian/rules: binary-* targets should depend on install, which should + depend on build-stamp, not build. + * General debian/rules cleanup. Add configure target. + * General postinst and postrm cleanup. Things only need to be done in + configure and purge. + + -- Magnus Holmgren Thu, 15 Mar 2007 19:19:32 +0100 + +pmk (0.9.3s2-3) unstable; urgency=low + + * QA upload. + * Set maintainer to QA Group; Orphaned: #411686 + * Add updated german debconf translation (Closes: #410319) + * Add updated Spanish debconf translation (Closes: #413239) + * Remove Build-Depends vor gcc. + * Conforms with latest Standards Version 3.7.2 + + -- Michael Ablassmeier Thu, 8 Mar 2007 13:05:05 +0100 + +pmk (0.9.3s2-2.1) unstable; urgency=low + + * Non-maintainer upload to fix an RC bug (and l10n...:-)) + * Fix control and makefile to avoid failure in the postinst script + Thanks to Alex de Oliveira Silva for the patch + Closes: #328362 + * Add a binary-indep build target. Closes: #395736 + * Debconf translation updates: + - Vietnamese. Closes: #316871 + + -- Christian Perrier Tue, 5 Dec 2006 20:35:28 +0100 + +pmk (0.9.3s2-2) unstable; urgency=low + + * pmk depends on debconf without | debconf-2.0 alternate; blocks + cdebconf transition (Closes: #332070) + + -- Marek Habersack Wed, 5 Oct 2005 07:48:04 +0200 + +pmk (0.9.3s2-1) unstable; urgency=low + + * [INTL:sv] Swedish debconf templates translation (Closes: #331577) + Translation submitted by Daniel Nylander , + thanks a lot + * The latest upstream snapshot + + -- Marek Habersack Tue, 4 Oct 2005 08:01:23 +0200 + +pmk (0.9.3-1) unstable; urgency=low + + * Closes: #309232: [l10n] Initial Czech translation of pmk debconf + messages, contributed by Miroslav Kure , + thanks a lot. + + -- Marek Habersack Tue, 14 Jun 2005 12:32:39 +0200 + +pmk (0.9.2-1) unstable; urgency=high + + * The latest upstream release + * Fixes the usage of --compare-versions in pmk.postinst (closes: Bug#292806) + * The OS_VERSION variable is defined as Debian/`uname -s` now to encompass + non-Linux Debian incarnations. + + -- Marek Habersack Mon, 7 Feb 2005 01:14:33 +0100 + +pmk (0.9.0-1) unstable; urgency=low + + * The latest upstream release + * The most important upstream changes: + - x86 and amd64 CPUs detection + - rewritten parser engine + - pmkcfg.sh script enhancements to let it detect POSIX shells + * Added the Japanese debconf translation, from Hideki Yamane, thanks + a lot! (closes: Bug#288026) + + -- Marek Habersack Sat, 1 Jan 2005 04:30:55 +0100 + +pmk (0.8.1-6+s8) unstable; urgency=low + + * The latest upstream snapshot + + -- Marek Habersack Sun, 14 Nov 2004 04:28:53 +0100 + +pmk (0.8.1-5+s6) unstable; urgency=high + + * added the French translation of the debconf messages, contributed by + Clément Stenac , thanks. + (closes: Bug#270671, closes: Bug#270670, closes: Bug#270664) + * Generate /etc/pmk.conf if it doesn't exist + + -- Marek Habersack Wed, 8 Sep 2004 21:07:10 +0200 + +pmk (0.8.1-4+s6) unstable; urgency=high + + * The latest upstream snapshot. + * Fixes a serious parser bug introduced in the previous snapshot. + + -- Marek Habersack Sun, 29 Aug 2004 02:14:47 +0200 + +pmk (0.8.1-3+s5) unstable; urgency=medium + + * The latest development snapshot - 0.8.1-s4 + CVS + * Don't ship the default config file. The file is generated in + postinst with pmksetup. + * When upgrading from any previous version, pmk.conf is moved out + of the way in /etc/pmk so that pmksetup works from fresh base. + * Uses debconf now + + -- Marek Habersack Fri, 27 Aug 2004 20:51:32 +0200 + +pmk (0.8.1-2+s3) unstable; urgency=medium + + * The latest released development snapshot - 0.8.1-s3 + + -- Marek Habersack Tue, 3 Aug 2004 22:46:18 +0200 + +pmk (0.8.1-1) unstable; urgency=low + + * The latest upstream version + * Updated the standards version. No changes. + + -- Marek Habersack Tue, 4 May 2004 16:04:13 +0200 + +pmk (0.8-1) unstable; urgency=low + + * The latest upstream release + + -- Marek Habersack Mon, 16 Feb 2004 02:28:03 +0100 + +pmk (0.7-1+cvs9) unstable; urgency=low + + * The latest CVS snapshot + + -- Marek Habersack Tue, 6 Jan 2004 17:55:54 +0100 + +pmk (0.5-1) unstable; urgency=low + + * Initial Release. + + -- Marek Habersack Tue, 24 Jun 2003 22:08:41 +0200 + --- pmk-0.10.4.orig/debian/pmk.files +++ pmk-0.10.4/debian/pmk.files @@ -0,0 +1 @@ +usr/share/pmk/* --- pmk-0.10.4.orig/debian/compat +++ pmk-0.10.4/debian/compat @@ -0,0 +1 @@ +4 --- pmk-0.10.4.orig/debian/README.Debian +++ pmk-0.10.4/debian/README.Debian @@ -0,0 +1,18 @@ +Running pmksetup +================ + +For pmk to work and configure software builds correctly, pmksetup must +be run (as root) to construct /etc/pmk/pmk.conf, which pmk uses to +find most system information instead of detecting it each time. +pmksetup is run automatically whenever pmk is installed or +upgraded. You should accept any changes presented to you, especially +if you are upgrading from an old version (before 0.8.1-3+s5, to be +exact). The configuration is maintained with ucf, which should make it +easier to merge + +pmksetup needs to be run again whenever a tool that pmksetup needs to +detect is installed. To get certain Debian-specific defaults right, +this should be done by running `dpkg-reconfigure pmk'. This is a bit +of a bug, but it can be worked around by providing an override file +(see pmk(1)) with any Debian package using pmk, or by overriding +variables when calling make. --- pmk-0.10.4.orig/debian/pmk.examples +++ pmk-0.10.4/debian/pmk.examples @@ -0,0 +1,2 @@ +samples/ +tests/ --- pmk-0.10.4.orig/debian/pmk.postrm +++ pmk-0.10.4/debian/pmk.postrm @@ -0,0 +1,37 @@ +#!/bin/sh +# postrm script for pmk +# +# see: dh_installdeb(1) + +conffile=/etc/pmk/pmk.conf + +set -e + +case "$1" in + purge) + rm -f $conffile $conffile~ $conffile.bak \#$conffile\# \ + $conffile.ucf-new $conffile.ucf-old $conffile.ucf-dist + if which ucf >/dev/null; then + ucf --purge /etc/pmk.conf + fi + if which ucfr >/dev/null; then + ucfr --purge pmk /etc/pmk.conf + fi + ;; + + remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + ;; + + *) + echo "postrm called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0 + --- pmk-0.10.4.orig/debian/copyright +++ pmk-0.10.4/debian/copyright @@ -0,0 +1,47 @@ +This package was debianized by Marek Habersack on +Tue, 24 Jun 2003 22:08:41 +0200. + +Current maintainer is Magnus Holmgren . + +It was downloaded from http://pmk.sf.net/ + +Upstream Author: Damien Couderc , and +to some extent Xavier Santolaria and Martin +Reindl . + +Copyright: + + This program is distributed under the terms of a BSD-like license: + + Copyright © 2003-2005 Damien Couderc + All rights reserved. + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + - Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + - Redistributions in binary form must reproduce the above + copyright notice, this list of conditions and the following + disclaimer in the documentation and/or other materials provided + with the distribution. + - Neither the name of the copyright holder(s) nor the names of its + contributors may be used to endorse or promote products derived + from this software without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. + +Some files also claim + Copyright © 2003-2004 Xavier Santolaria --- pmk-0.10.4.orig/debian/pmk.dirs +++ pmk-0.10.4/debian/pmk.dirs @@ -0,0 +1 @@ +etc/pmk --- pmk-0.10.4.orig/debian/pmk.docs +++ pmk-0.10.4/debian/pmk.docs @@ -0,0 +1,7 @@ +BUGS +BONUS +README +TODO +STATUS +CREDITS +doc/*.txt --- pmk-0.10.4.orig/debian/patches/25_pmksetup.dpatch +++ pmk-0.10.4/debian/patches/25_pmksetup.dpatch @@ -0,0 +1,238 @@ +#! /bin/sh /usr/share/dpatch/dpatch-run +## 25_pmksetup.dpatch by Magnus Holmgren +## +## DP: Adds -s parameter to pmksetup, which outputs config to standard +## DP: output, as well as -g, which forces data gathering to take place +## DP: immediately. + +@DPATCH@ +diff -urNad trunk~/pmksetup.c trunk/pmksetup.c +--- trunk~/pmksetup.c 2006-10-15 00:31:11.000000000 +0200 ++++ trunk/pmksetup.c 2007-08-05 15:17:25.000000000 +0200 +@@ -66,6 +66,7 @@ + extern int optind; + + FILE *sfp; /* scratch file pointer */ ++bool tostdout = false; + char sfn[MAXPATHLEN]; /* scratch file name */ + + htable *ht; +@@ -154,7 +155,7 @@ + ***********************************************************************/ + + bool gather_data(htable *pht) { +- printf("==> Looking for default parameters...\n"); ++ fprintf(stderr, "==> Looking for default parameters...\n"); + + /* gather env variables */ + if (get_env_vars(pht) == false) { +@@ -850,7 +851,7 @@ + vsnprintf(buf, sizeof(buf), fmt, plst); + va_end(plst); + +- printf("%s\n", buf); ++ fprintf(stderr, "%s\n", buf); + } + } + +@@ -883,6 +884,13 @@ + optind = 1; + while ((ch = getopt(argc, argv, PMKSTP_OPT_STR)) != -1) { + switch(ch) { ++ case 'g' : ++ if (gather_data(ht) == false) ++ return(false); ++ ++ process_clopts = true; ++ break; ++ + case 'r' : + /* mark to be deleted in hash */ + if (record_data(ht, optarg, PMKSTP_REC_REMV, NULL) == false) { +@@ -932,6 +940,7 @@ + process_clopts = true; + break; + ++ case 's' : + case 'v' : + case 'V' : + /* +@@ -949,11 +958,11 @@ + argc -= optind; + argv += optind; + +- printf("PMKSETUP version %s", PREMAKE_VERSION); ++ fprintf(stderr, "PMKSETUP version %s", PREMAKE_VERSION); + #ifdef DEBUG +- printf(" [SUB #%s] [SNAP #%s]", PREMAKE_SUBVER_PMKSETUP, PREMAKE_SNAP); ++ fprintf(stderr, " [SUB #%s] [SNAP #%s]", PREMAKE_SUBVER_PMKSETUP, PREMAKE_SNAP); + #endif /* DEBUG */ +- printf("\n\n"); ++ fprintf(stderr, "\n\n"); + + if (process_clopts == false) { + /* standard behavior, gathering data */ +@@ -967,7 +976,7 @@ + /* switch backup flag */ + cfg_backup = true; + +- printf("==> Configuration file found: %s\n", ++ fprintf(stderr, "==> Configuration file found: %s\n", + PREMAKE_CONFIG_PATH); + if (parse_pmkconf(config, ht, PRS_PMKCONF_SEP, + check_opt) == false) { +@@ -978,10 +987,10 @@ + fclose(config); + } + } else { +- printf("==> Configuration file not found.\n"); ++ fprintf(stderr, "==> Configuration file not found.\n"); + } + +- printf("==> Merging remaining data...\n"); ++ fprintf(stderr, "==> Merging remaining data...\n"); + /* writing the remaining data stored in the hash */ + if (write_new_data(ht) == false) + return(false); +@@ -1099,6 +1108,9 @@ + /* if child status is ok, writing changes */ + if (status == 0) { + #endif ++ if (tostdout) { ++ return; ++ } + /* + * check if pmk.conf already exists + * NOTE: no race condition here for access(), BUT +@@ -1106,7 +1118,7 @@ + */ + if (access(PREMAKE_CONFIG_PATH, F_OK) == 0) { /* see above */ + /* backup configuration file */ +- printf("==> Backing up configuration file: %s\n", ++ fprintf(stderr, "==> Backing up configuration file: %s\n", + PREMAKE_CONFIG_PATH_BAK); + + if (rename(PREMAKE_CONFIG_PATH, +@@ -1118,7 +1130,7 @@ + } + + /* copying the temporary config to the system one */ +- printf("==> Saving configuration file: %s\n", ++ fprintf(stderr, "==> Saving configuration file: %s\n", + PREMAKE_CONFIG_PATH); + if (fcopy(sfn, PREMAKE_CONFIG_PATH, + PREMAKE_CONFIG_MODE) == false) { +@@ -1129,15 +1141,17 @@ + } + #endif + ++ if (!tostdout) { + #ifdef PMKSETUP_DEBUG +- debugf("%s has not been deleted!", sfn); ++ debugf("%s has not been deleted!", sfn); + #else +- if (unlink(sfn) == -1) { +- errorf("cannot remove temporary file: '%s' : %s.", +- sfn, strerror(errno)); +- error = true; +- } ++ if (unlink(sfn) == -1) { ++ errorf("cannot remove temporary file: '%s' : %s.", ++ sfn, strerror(errno)); ++ error = true; ++ } + #endif /* PMKSETUP_DEBUG */ ++ } + + #ifndef WITHOUT_FORK + if (status != 0) { +@@ -1165,7 +1179,7 @@ + ***********************************************************************/ + + void usage(void) { +- fprintf(stderr, "usage: pmksetup [-hVv] " ++ fprintf(stderr, "usage: pmksetup [-hsVv] " + "[-r variable] [-u variable=value]\n"); + exit(EXIT_FAILURE); + } +@@ -1188,6 +1202,7 @@ + optind = 1; + while ((ch = getopt(argc, argv, PMKSTP_OPT_STR)) != -1) { + switch(ch) { ++ case 'g' : + case 'r' : + case 'u' : + /* +@@ -1206,6 +1221,10 @@ + verbose_flag = 1; + break; + ++ case 's': ++ tostdout = true; ++ break; ++ + case '?' : + default : + usage(); +@@ -1213,7 +1232,6 @@ + } + } + +- + if (getuid() == 0) { + #ifdef PMKSETUP_DEBUG + debugf("PRIVSEP_USER = '%s'", PRIVSEP_USER); +@@ -1227,22 +1245,27 @@ + gid = pw->pw_gid; + } + +- /* check if syconfdir exists */ +- if (access(CONFDIR, F_OK) != 0) { /* no race condition, just mkdir() */ +- verbosef("==> Creating '%s' directory.", CONFDIR); +- if (mkdir(CONFDIR, S_IRWXU | S_IRGRP | S_IXGRP | +- S_IROTH | S_IXOTH) != 0) { +- errorf("cannot create '%s' directory : %s.", +- CONFDIR, strerror(errno)); +- exit(EXIT_FAILURE); +- } ++ if (tostdout) { ++ sfp = stdout; + } ++ else { ++ /* check if syconfdir exists */ ++ if (access(CONFDIR, F_OK) != 0) { /* no race condition, just mkdir() */ ++ verbosef("==> Creating '%s' directory.", CONFDIR); ++ if (mkdir(CONFDIR, S_IRWXU | S_IRGRP | S_IXGRP | ++ S_IROTH | S_IXOTH) != 0) { ++ errorf("cannot create '%s' directory : %s.", ++ CONFDIR, strerror(errno)); ++ exit(EXIT_FAILURE); ++ } ++ } + +- sfp = tmp_open(PREMAKE_CONFIG_TMP, "w", sfn, sizeof(sfn)); +- if (sfp == NULL) { +- errorf("cannot open temporary file '%s' : %s.", +- sfn, strerror(errno)); +- exit(EXIT_FAILURE); ++ sfp = tmp_open(PREMAKE_CONFIG_TMP, "w", sfn, sizeof(sfn)); ++ if (sfp == NULL) { ++ errorf("cannot open temporary file '%s' : %s.", ++ sfn, strerror(errno)); ++ exit(EXIT_FAILURE); ++ } + } + + #ifndef WITHOUT_FORK +diff -urNad trunk~/pmksetup.h trunk/pmksetup.h +--- trunk~/pmksetup.h 2005-05-14 13:37:38.000000000 +0200 ++++ trunk/pmksetup.h 2007-08-05 15:09:51.000000000 +0200 +@@ -85,7 +85,7 @@ + #define ECHO_NL "\\n" + #define ECHO_HT "\\t" + +-#define PMKSTP_OPT_STR "hr:u:vV" /* "a:hr:u:vV" */ ++#define PMKSTP_OPT_STR "ghr:su:vV" /* "a:hr:u:vV" */ + + #define EMSG_PRIV_FMT "Failed to change privilege (%s)" + --- pmk-0.10.4.orig/debian/patches/00list +++ pmk-0.10.4/debian/patches/00list @@ -0,0 +1 @@ +25_pmksetup