summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitignore3
-rw-r--r--Build.PL23
-rw-r--r--Makefile23
-rwxr-xr-xt/01-compile-pl.t8
-rwxr-xr-xt/10-pod.t8
5 files changed, 42 insertions, 23 deletions
diff --git a/.gitignore b/.gitignore
index 84c048a..e6992f5 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,4 @@
+/Build
/build/
+/_build/
+/blib/
diff --git a/Build.PL b/Build.PL
new file mode 100644
index 0000000..16da3c1
--- /dev/null
+++ b/Build.PL
@@ -0,0 +1,23 @@
+#!/usr/bin/env perl
+
+use strict;
+use warnings;
+use Module::Build;
+
+my $build = Module::Build->new(
+ build_requires => {
+ 'Test::More' => 0,
+ 'Test::Compile' => 0,
+ 'Test::Pod' => 0,
+ },
+ dist_name => 'gen-xhtml-thumbnails',
+ dist_version_from => 'bin/gen-xhtml-thumbnails',
+ license => 'unrestricted',
+ requires => {
+ 'perl' => '5.10.0',
+ 'Archive::Tar' => 0,
+ 'Image::Imlib2' => 0,
+ },
+ script_files => 'bin/',
+);
+$build->create_build_script();
diff --git a/Makefile b/Makefile
deleted file mode 100644
index 1e04745..0000000
--- a/Makefile
+++ /dev/null
@@ -1,23 +0,0 @@
-prefix = /usr/local
-
-default: build/gen-xhtml-thumbnails.1
-
-build/%.1: bin/%
- mkdir -p build
- pod2man $< > $@
-
-install: build/gen-xhtml-thumbnails.1
- mkdir -p $(prefix)/bin $(prefix)/share/man/man1
- cp bin/gen-xhtml-thumbnails $(prefix)/bin/gen-xhtml-thumbnails
- cp build/gen-xhtml-thumbnails.1 $(prefix)/share/man/man1/gen-xhtml-thumbnails.1
- chmod 755 $(prefix)/bin/gen-xhtml-thumbnails
- chmod 644 $(prefix)/share/man/man1/gen-xhtml-thumbnails.1
-
-uninstall:
- rm -f $(prefix)/bin/gen-xhtml-thumbnails
- rm -f $(prefix)/share/man/man1/gen-xhtml-thumbnails.1
-
-clean:
- rm -rf build
-
-.PHONY: install uninstall clean
diff --git a/t/01-compile-pl.t b/t/01-compile-pl.t
new file mode 100755
index 0000000..f130ac4
--- /dev/null
+++ b/t/01-compile-pl.t
@@ -0,0 +1,8 @@
+#!/usr/bin/env perl
+use strict;
+use warnings;
+use 5.010;
+use Test::More;
+use Test::Compile;
+
+all_pl_files_ok();
diff --git a/t/10-pod.t b/t/10-pod.t
new file mode 100755
index 0000000..5fe4faa
--- /dev/null
+++ b/t/10-pod.t
@@ -0,0 +1,8 @@
+#!/usr/bin/env perl
+use strict;
+use warnings;
+use 5.010;
+use Test::More;
+use Test::Pod;
+
+all_pod_files_ok();