Buildscr.cv 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. # -*- sh -*-
  2. # Build script to scan PuTTY with the downloadable Coverity scanner
  3. # and generate a tar file to upload to their open-source scanning
  4. # service.
  5. module putty
  6. # Preparations.
  7. in putty do ./mkfiles.pl
  8. in putty do ./mkauto.sh
  9. in putty/doc do make
  10. # Scan the Unix build, on a 64-bit system to differentiate as much as
  11. # possible from the other scan of the cross-platform files.
  12. delegate covscan64
  13. in putty do ./configure
  14. in putty do cov-build --dir cov-int make
  15. in putty do tar czvf cov-int.tar.gz cov-int
  16. return putty/cov-int.tar.gz
  17. enddelegate
  18. # Scan the Windows build, by means of building with Winelib (since as
  19. # of 2013-07-22, the Coverity Scan website doesn't offer a 32-bit
  20. # Windows scanner for download).
  21. delegate covscan32wine
  22. in putty do tar xzvf cov-int.tar.gz
  23. in putty/windows do cov-build --dir ../cov-int make -f Makefile.mgw CC=winegcc RC=wrc XFLAGS=-DCOVERITY
  24. in putty do tar czvf cov-int.tar.gz cov-int
  25. return putty/cov-int.tar.gz
  26. enddelegate
  27. # Provide the revision number as one of the build outputs, to make it
  28. # easy to construct a curl upload command which will annotate it
  29. # appropriately when uploaded.
  30. in putty do echo $(vcsfullid) > revision.txt
  31. deliver putty/revision.txt $@
  32. deliver putty/cov-int.tar.gz $@