summaryrefslogtreecommitdiff
path: root/Makefile.PL
blob: f3daaed2fe51ab07cb578f7e9ddb5c5694e68f49 (plain)
  1. #!/usr/bin/perl
  2. use warnings;
  3. use strict;
  4. use ExtUtils::MakeMaker;
  5. # Add a few more targets.
  6. sub MY::postamble {
  7. q{
  8. all:: extra_build
  9. clean:: extra_clean
  10. install:: extra_install
  11. pure_install:: extra_install
  12. extra_build:
  13. ./ikiwiki doc html --templatedir=templates --underlaydir=basewiki \
  14. --wikiname="ikiwiki" --verbose --nosvn --exclude=/discussion
  15. ./mdwn2man doc/usage.mdwn > ikiwiki.man
  16. extra_clean:
  17. rm -rf html doc/.ikiwiki
  18. rm -f ikiwiki.man
  19. extra_install:
  20. install -d $(PREFIX)/share/ikiwiki/templates
  21. cp templates/* $(PREFIX)/share/ikiwiki/templates
  22. install -d $(PREFIX)/share/ikiwiki/basewiki
  23. cp -a basewiki/* $(PREFIX)/share/ikiwiki/basewiki
  24. }
  25. }
  26. WriteMakefile(
  27. 'NAME' => 'IkiWiki',
  28. 'PM_FILTER' => 'grep -v "removed by Makefile"',
  29. 'EXE_FILES' => ['ikiwiki'],
  30. );