summaryrefslogtreecommitdiff
path: root/Makefile.PL
blob: 91ba6c50df975ade5547554455f9a1c86985dc35 (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 \
  15. --exclude=/discussion --plugin=brokenlinks \
  16. --plugin=pagecount --plugin=orphans
  17. ./mdwn2man doc/usage.mdwn > ikiwiki.man
  18. extra_clean:
  19. rm -rf html doc/.ikiwiki
  20. rm -f ikiwiki.man
  21. extra_install:
  22. install -d $(PREFIX)/share/ikiwiki/templates
  23. cp templates/* $(PREFIX)/share/ikiwiki/templates
  24. install -d $(PREFIX)/share/ikiwiki/basewiki
  25. cp -a basewiki/* $(PREFIX)/share/ikiwiki/basewiki
  26. install -d $(PREFIX)/share/man/man1
  27. install ikiwiki.man $(PREFIX)/share/man/man1/ikiwiki.1
  28. }
  29. }
  30. WriteMakefile(
  31. 'NAME' => 'IkiWiki',
  32. 'PM_FILTER' => 'grep -v "removed by Makefile"',
  33. 'EXE_FILES' => ['ikiwiki'],
  34. );