Makefile.inc 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. # $OpenBSD: Makefile.inc,v 1.14 2014/07/16 20:08:25 okan Exp $
  2. # $NetBSD: Makefile.inc,v 1.5 1996/09/30 16:01:18 ws Exp $
  3. #
  4. # NOTE: $S must correspond to the top of the 'sys' tree
  5. SADIR= $S/lib/libsa
  6. SADST?= lib/sa
  7. SAREL?= ../../
  8. SALIB?= ${SADST}/libsa.a
  9. SAMAKE= \
  10. cd ${SADST} && ${MAKE} -f ${SAREL}${SADIR}/Makefile \
  11. CC="${CC}" XCFLAGS="${CFLAGS}" \
  12. AS='${AS}' XAFLAGS='${AFLAGS}' \
  13. LD='${LD}' \
  14. SAREL="${SAREL}" \
  15. SADIR="${SADIR}" \
  16. EXTRACFLAGS="${EXTRACFLAGS}"
  17. .if defined(NO_NET)
  18. SAMAKE+= NO_NET=""
  19. .endif
  20. .if defined(SA_ZLIB)
  21. SAMAKE+= SA_ZLIB=""
  22. .endif
  23. .if defined(USE_LOADFILE)
  24. SAMAKE+= USE_LOADFILE=""
  25. .endif
  26. ${SALIB}: .NOTMAIN __always_make_salib
  27. @echo making sure the stand-alone library is up to date...
  28. @${SAMAKE} libsa.a
  29. clean:: .NOTMAIN __always_make_salib
  30. @echo cleaning the stand-alone library objects
  31. @${SAMAKE} clean
  32. -rmdir -p ${SADST}
  33. depend:: .NOTMAIN __always_make_salib
  34. @echo depending the standalone library objects
  35. @${SAMAKE} depend
  36. __always_make_salib: .NOTMAIN
  37. -mkdir -p ${SADST}