xref: /minix3/external/bsd/libc++/lib/Makefile (revision 0a6a1f1d05b60e214de2f05a7310ddd1f0e590e7)
1*0a6a1f1dSLionel Sambuc#	$NetBSD: Makefile,v 1.7 2014/08/20 15:19:39 joerg Exp $
24684ddb6SLionel Sambuc
34684ddb6SLionel SambucLIB=		c++
44684ddb6SLionel SambucWARNS=		4
54684ddb6SLionel SambucNOLINT=		# defined
64684ddb6SLionel Sambuc
74684ddb6SLionel Sambuc.include <bsd.init.mk>
84684ddb6SLionel Sambuc
94684ddb6SLionel Sambuc.PATH: ${LIBCXX_SRCDIR}/src
104684ddb6SLionel Sambuc
11*0a6a1f1dSLionel Sambuc#__MINIX: Unsupported for now: shared_mutex.cpp
124684ddb6SLionel SambucSRCS=	algorithm.cpp bind.cpp chrono.cpp condition_variable.cpp debug.cpp \
134684ddb6SLionel Sambuc	exception.cpp future.cpp hash.cpp ios.cpp iostream.cpp locale.cpp \
144684ddb6SLionel Sambuc	memory.cpp mutex.cpp new.cpp optional.cpp random.cpp regex.cpp \
15*0a6a1f1dSLionel Sambuc	stdexcept.cpp \
164684ddb6SLionel Sambuc	string.cpp strstream.cpp system_error.cpp thread.cpp \
174684ddb6SLionel Sambuc	utility.cpp valarray.cpp
184684ddb6SLionel Sambuc# typeinfo.cc: prefer libcxxrt's version
194684ddb6SLionel Sambuc
20*0a6a1f1dSLionel Sambuc#__MINIX: Unsupported for now:
214684ddb6SLionel SambucLIBCXXRT_SRCS+= \
224684ddb6SLionel Sambuc	auxhelper.cc dynamic_cast.cc exception.cc guard.cc \
234684ddb6SLionel Sambuc	stdexcept.cc terminate.cc typeinfo.cc libelftc_dem_gnu3.c
244684ddb6SLionel Sambuc# cxa_atexit.c: Solaris-only
254684ddb6SLionel Sambuc# memory.cc: already provided by libc++'s new.cpp
264684ddb6SLionel Sambuc
274684ddb6SLionel Sambuc.for src in ${LIBCXXRT_SRCS}
284684ddb6SLionel Sambucrt_${src}: ${LIBCXXRT_SRCDIR}/src/${src}
294684ddb6SLionel Sambuc	cp ${LIBCXXRT_SRCDIR}/src/${src} rt_${src}
304684ddb6SLionel Sambuc
314684ddb6SLionel SambucSRCS+=		rt_${src}
324684ddb6SLionel SambucDPSRCS+=	rt_${src}
334684ddb6SLionel SambucCLEANFILES+=	rt_${src}
344684ddb6SLionel Sambuc.endfor
354684ddb6SLionel Sambuc
364684ddb6SLionel Sambuc.include <bsd.own.mk>
374684ddb6SLionel Sambuc
384684ddb6SLionel SambucCPPFLAGS+=	-nostdinc++ -cxx-isystem ${LIBCXX_SRCDIR}/include -I${LIBCXXRT_SRCDIR}/src
394684ddb6SLionel SambucCPPFLAGS+=	-DLIBCXXRT
40*0a6a1f1dSLionel SambucCXXFLAGS+=	-std=c++11
414684ddb6SLionel Sambuc
424684ddb6SLionel SambucCWARNFLAGS.gcc+=	-Wno-error
434684ddb6SLionel Sambuc
444684ddb6SLionel SambucCWARNFLAGS.clang+=	-Wno-error=unused-variable -Wno-error=missing-noreturn
454684ddb6SLionel SambucCWARNFLAGS.clang+=	-Wno-error=missing-prototypes -Wno-error=sometimes-uninitialized
464684ddb6SLionel SambucCWARNFLAGS.clang+=	-Wno-error=missing-field-initializers -Wno-error=switch
474684ddb6SLionel SambucCWARNFLAGS.clang+=	-Wno-error=implicit-exception-spec-mismatch
484684ddb6SLionel Sambuc
494684ddb6SLionel SambucLDADD+=	-Wl,-z,defs
504684ddb6SLionel Sambuc
514684ddb6SLionel Sambuc.include <bsd.lib.mk>
52