]> gitweb @ CieloNegro.org - pci-nopaste.git/commitdiff
Makefile.PL for rc.d master
authorPHO <pho@cielonegro.org>
Fri, 16 Nov 2012 06:07:06 +0000 (15:07 +0900)
committerPHO <pho@cielonegro.org>
Fri, 16 Nov 2012 06:07:06 +0000 (15:07 +0900)
po/ja.po
rc.d/Makefile.PL [new file with mode: 0644]
rc.d/linux/Makefile.PL [new file with mode: 0644]

index 4de948c47d5db315b16fe50c49be58be2f100841..747e54db95b8e38aa3e7d63f94e7b9d1b767369a 100644 (file)
--- a/po/ja.po
+++ b/po/ja.po
@@ -7,7 +7,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: pci-nopaste #0\n"
 "Report-Msgid-Bugs-To: phonohawk <phonohawk@ps.sakura.ne.jp>\n"
-"POT-Creation-Date: 2012-11-06 14:27+0900\n"
+"POT-Creation-Date: 2012-11-16 15:01+0900\n"
 "PO-Revision-Date: 2005-09-24 17:57+0900\n"
 "Last-Translator: phonohawk <phonohawk@ps.sakura.ne.jp>\n"
 "Language-Team: Japanese <phonohawk@ps.sakura.ne.jp>\n"
diff --git a/rc.d/Makefile.PL b/rc.d/Makefile.PL
new file mode 100644 (file)
index 0000000..9ba39ce
--- /dev/null
@@ -0,0 +1,5 @@
+use ExtUtils::MakeMaker;
+
+WriteMakefile(
+    NAME => 'rc.d'
+   );
diff --git a/rc.d/linux/Makefile.PL b/rc.d/linux/Makefile.PL
new file mode 100644 (file)
index 0000000..34a49c6
--- /dev/null
@@ -0,0 +1,27 @@
+use strict;
+use warnings;
+use Config qw(%Config);
+use ExtUtils::MakeMaker;
+use File::Slurp qw(read_file write_file);
+
+# FIXME: Stop hard-coding these variables.
+my %vars = (
+    DAEMON        => '/usr/local/sbin/daemon',
+    bindir        => $Config{installbin},
+    localstatedir => '/usr/local/var',
+    sysconfdir    => '/usr/local/etc'
+   );
+
+my $script = read_file('pci-nopaste.in');
+
+while (my ($var, $subst) = each %vars) {
+    $script =~ s/\@\Q$var\E\@/$subst/g;
+}
+
+print "Writing pci-nopaste\n";
+write_file('pci-nopaste', $script);
+chmod 0755, 'pci-nopaste';
+
+WriteMakefile(
+    NAME => 'linux'
+   );