use
5.026;
WriteMakefile(
NAME
=>
'App::MediaPi'
,
DISTNAME
=>
'App-MediaPi'
,
AUTHOR
=>
q{Mathias Kende <mathias@cpan.org>}
,
VERSION_FROM
=>
'lib/App/MediaPi.pm'
,
ABSTRACT
=>
q{Media Player for Raspberry Pi or other devices with very small screen.}
,
LICENSE
=>
'mit'
,
EXE_FILES
=> [
'script/mediapi'
,],
MIN_PERL_VERSION
=>
'5.026'
,
MAN3PODS
=> {},
DIR
=> [],
NO_MYMETA
=> 1,
META_MERGE
=> {
'meta-spec'
=> {
version
=> 2 },
dynamic_config
=> 0,
no_index
=> {
directory
=> [
'local'
,
'vendor'
,
't'
],
},
keywords
=> [
'raspberry'
,
'pi'
,
'media'
,
'player'
,
'vlc'
,
'audio'
,],
resources
=> {
repository
=> {
type
=>
'git'
,
url
=>
'git@github.com:mkende/mediapi.git'
,
},
bugtracker
=> {
},
},
},
dist
=> {
COMPRESS
=>
'gzip -9f'
,
SUFFIX
=>
'.gz'
, },
clean
=> {
FILES
=>
'App-MediaPi-*'
},
);
sub
supported_platform {
return
$^O =~ m/^(?:linux|cygwin|MSWin32)$/;
}
sub
MY::postamble {
my
(
$self
) =
@_
;
my
@postamble
;
push
@postamble
, ::postamble()
if
*::postamble{CODE};
push
@postamble
,
<<"MAKE_FRAGMENT" if supported_platform();
ALL_PM := \$(shell find lib -name "*.pm")
ALL_EXE := script/mediapi
.PHONY: distupload cover critic rawcritic tidy spelling alltest clean clean_coverdb pod2html exe
distupload: distcheck disttest
\t\$(MAKE) tardist
\tcpan-upload --directory Dist-Setup \$(DISTVNAME).tar\$(SUFFIX)
cover:
\tcover -test
critic: export EXTENDED_TESTING = 1
critic: all
\tperl -Ilib t/001-perlcritic.t 2>&1 | less
rawcritic:
\tperlcritic lib script
tidy:
\tperltidy -b -bext='/' \$(ALL_PM) \$(ALL_EXE)
spelling: export EXTENDED_TESTING = 1
spelling:
\t\$(PERLRUN) t/001-spelling.t --interactive
alltest: export EXTENDED_TESTING = 1
alltest: test
clean:: clean_coverdb clean_build clean_pod2html
clean_coverdb:
\trm -fr cover_db
clean_build:
\trm -fr build
clean_pod2html:
\trm -fr pod2html
PM_HTML := \$(patsubst %.pm, pod2html/%.html, \$(ALL_PM))
EXE_HTML := \$(patsubst %, pod2html/%.html, \$(ALL_EXE))
pod2html: \$(PM_HTML) \$(EXE_HTML)
\$(PM_HTML): pod2html/%.html: %.pm
\tmkdir -p \$(shell dirname \$@)
\tpod2html --infile \$< --outfile \$@
\$(EXE_HTML): pod2html/%.html: %
\tmkdir -p \$(shell dirname \$@)
\tpod2html --infile \$< --outfile \$@
EXE_EXE := \$(patsubst %, build/%\$(EXE_EXT), \$(ALL_EXE))
exe: export PAR_VERBATIM=1
exe: build \$(EXE_EXE)
build:
\tmkdir -p build
\$(EXE_EXE): build/%\$(EXE_EXT): %
\tpp -o \$@ -cd build/pp.cache -I lib -F "PodStrip=.*\\bApp/MediaPi\\b(*COMMIT)(*FAIL)|.*" \$<
MAKE_FRAGMENT
return
join
"\n"
,
@postamble
;
}