2 # Copyright (C) 2013-2018 all contributors <meta@public-inbox.org>
3 # License: AGPL-3.0+ <https://www.gnu.org/licenses/agpl-3.0.txt>
5 use ExtUtils::MakeMaker;
6 open my $m, '<', 'MANIFEST' or die "open(MANIFEST): $!\n";
7 chomp(my @manifest = (<$m>));
8 my @EXE_FILES = grep(m!^script/!, @manifest);
9 my $PM_FILES = join(' ', grep(m!^lib/.*\.pm$!, @manifest));
12 NAME => 'PublicInbox',
13 VERSION => '1.1.0-pre1',
14 AUTHOR => 'Eric Wong <e@80x24.org>',
15 ABSTRACT => 'public-inbox server infrastructure',
16 EXE_FILES => \@EXE_FILES,
18 # note: we use spamc(1), NOT the Perl modules
19 # We also depend on git.
20 # Keep this sorted and synced to the INSTALL document
23 'Email::MIME::ContentType' => 0,
25 'Encode::MIME::Header' => 0,
28 # We have more test dependencies, but do not force
29 # users to install them
35 # support using eatmydata to speed up tests (apt-get install eatmydata):
36 # https://www.flamingspork.com/projects/libeatmydata/
39 -include Documentation/include.mk
40 N ?= \$(shell echo \$\$(( \$\$(nproc 2>/dev/null || echo 2) + 1)))
41 SCRIPTS := scripts/ssoma-replay
42 my_syntax := \$(addsuffix .syntax, $PM_FILES \$(EXE_FILES) \$(SCRIPTS))
46 @\$(PERL) -I lib -c \$(subst .syntax,,\$@)
48 syntax:: \$(my_syntax)
50 check-manifest :: MANIFEST
51 if git ls-files >\$<.gen 2>&1; then diff -u \$< \$<.gen; fi
53 check:: pure_all check-manifest
54 \$(EATMYDATA) prove -lv -j\$(N)