Home | History | Annotate | Line # | Download | only in libsa
Makefile revision 1.67
      1 #	$NetBSD: Makefile,v 1.67 2008/08/29 00:02:24 gmcgarry Exp $
      2 
      3 LIB=	sa
      4 NOPIC=	# defined
      5 NOPROFILE=# defined
      6 
      7 SA_USE_CREAD?= no		# Read compressed kernels
      8 SA_INCLUDE_NET?= yes		# Netboot via TFTP, NFS
      9 SA_USE_LOADFILE?= no		# Generic executable loading support
     10 
     11 #DEBUGCPPFLAGS= -DBOOTP_DEBUG -DNETIF_DEBUG -DETHER_DEBUG -DNFS_DEBUG -DRPC_DEBUG -DRARP_DEBUG -DARP_DEBUG -DNET_DEBUG -DDEBUG -DPARANOID
     12 CPPFLAGS=	-I${SADIR} ${SACPPFLAGS} ${SAMISCCPPFLAGS} \
     13 		-DCOMPAT_UFS ${DEBUGCPPFLAGS}
     14 
     15 #COPTS+= -ansi -pedantic -Wall
     16 
     17 .PATH.c: ${SADIR} ${.PARSEDIR}/../../../common/lib/libc/string
     18 
     19 # stand routines
     20 SRCS+=	alloc.c errno.c exit.c exec.c files.c \
     21 	getfile.c gets.c globals.c \
     22 	panic.c printf.c qsort.c snprintf.c sprintf.c strerror.c \
     23 	subr_prf.c twiddle.c vsprintf.c checkpasswd.c
     24 
     25 # string routines
     26 SRCS+=	memcmp.c memcpy.c memmove.c memset.c strchr.c
     27 SRCS+=	bcopy.c bzero.c	# Remove me eventually.
     28 
     29 # io routines
     30 SRCS+=	closeall.c dev.c disklabel.c dkcksum.c ioctl.c nullfs.c stat.c fstat.c
     31 SRCS+=	close.c lseek.c open.c read.c write.c
     32 .if (${SA_USE_CREAD} == "yes")
     33 CPPFLAGS+= -D__INTERNAL_LIBSA_CREAD
     34 SRCS+=	cread.c
     35 .endif
     36 
     37 .if (${SA_USE_LOADFILE} == "yes")
     38 SRCS+=	loadfile.c loadfile_aout.c loadfile_ecoff.c loadfile_elf32.c \
     39 	loadfile_elf64.c
     40 .endif
     41 
     42 .if (${SA_INCLUDE_NET} == "yes")
     43 # network routines
     44 SRCS+=	arp.c ether.c ether_sprintf.c ip_cksum.c net.c netif.c rpc.c udp.c
     45 
     46 # network info services:
     47 SRCS+=	bootp.c rarp.c bootparam.c
     48 
     49 # boot filesystems
     50 SRCS+=	nfs.c tftp.c
     51 .endif
     52 
     53 SRCS+=	ffsv1.c ffsv2.c ufs_ls.c
     54 SRCS+=	lfsv1.c lfsv2.c
     55 SRCS+=	cd9660.c
     56 SRCS+=	ustarfs.c
     57 SRCS+=	dosfs.c
     58 SRCS+=	ext2fs.c
     59 # for historic compatibility ufs == ffsv1
     60 SRCS+=	ufs.c
     61 
     62 # only needed during build
     63 libinstall::
     64 
     65 .undef DESTDIR
     66 .include <bsd.lib.mk>
     67 
     68 lib${LIB}.o:: ${OBJS}
     69 	@echo building standard ${LIB} library
     70 	@rm -f lib${LIB}.o
     71 	@${LD} -r -o lib${LIB}.o `lorder ${OBJS} | tsort`
     72 
     73 .if (defined(HAVE_GCC) && ${HAVE_GCC} == 4) || defined(HAVE_PCC)
     74 CPPFLAGS+=	-Wno-pointer-sign
     75 .endif
     76