You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
671 B

26 years ago
  1. # Warning - first line left blank for sh/csh/ksh compatibility. Do not
  2. # remove it. fnf@Unisoft
  3. # mklintlib --- make a lint library, under either System V or 4.2 BSD
  4. #
  5. # usage: mklintlib <infile> <outfile>
  6. #
  7. if test $# -ne 2
  8. then
  9. echo "usage: mklintlib <infile> <outfile>"
  10. exit 1
  11. fi
  12. if grep SIGTSTP /usr/include/signal.h >/dev/null
  13. then # BSD
  14. if test -r /usr/include/whoami.h # 4.1
  15. then
  16. /lib/cpp -C -Dlint $1 >hlint
  17. (/usr/lib/lint/lint1 <hlint >$2) 2>&1 | grep -v warning
  18. else # 4.2
  19. lint -Cxxxx $1
  20. mv llib-lxxxx.ln $2
  21. fi
  22. else # USG
  23. cc -E -C -Dlint $1 | /usr/lib/lint1 -vx -Hhlint >$2
  24. rm -f hlint
  25. fi
  26. exit 0 # don't kill make