summaryrefslogtreecommitdiff
path: root/graphics/libfpx/files/Makefile.bsd
blob: 2c7828924181868a3513b4e32bf8ba891f8f5143 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
LIB	=	fpx
INCS	=	fpxlib.h
SHLIB_MAJOR=	2
SHLIB_MINOR=	7
WARNS=	3

LIBDIR	=	${PREFIX}/lib
INCSDIR	=	${PREFIX}/include
INCDIR	=	${INCSDIR}		# for pre-bsd.incs.mk API

NO_PROFILE=	Don't want it
NOPROFILE=	${NO_PROFILE}
HAVES=		-DHAVE_WCHAR_H -DHAVE_DLFCN_H \
		-DHAVE_SYS_TIME_H \
		-DHAVE_SYS_PARAM_H -DHAVE_SYS_MOUNT_H
CFLAGS+=	${HAVES} -Dregister=

CPPS	!=	find ${.CURDIR} -name \*.cpp -print
# Some of the .cxx files are #include-ed into others, so can't use `find' here:
OLESS	:=	ascii.cxx cdocfile.cxx chinst.cxx dffuncs.cxx dfiter.cxx \
		dfstream.cxx difat.cxx dir.cxx dirp.cxx docfile.cxx entry.cxx \
		expdf.cxx expiter.cxx expst.cxx fat.cxx funcs.cxx header.cxx \
		iter.cxx mem.cxx msf.cxx msfiter.cxx mstream.cxx page.cxx \
		refilb.cxx rexpdf.cxx sstream.cxx storage.cxx time.cxx \
		vect.cxx wchar.c
JPGS	!=	find ${.CURDIR}/jpeg -name \*.c -not -name dllmain.c

CPPS	+=	${OLESS:S/^/${.CURDIR}\/oless\//} ${JPGS}

SRCS	=	${CPPS:T:Nejpeg.c}

CXXFLAGS+=	-fno-rtti -fno-exceptions -fno-strict-aliasing ${HAVES}
LDADD	+=	-L${LOCALBASE}/lib -lm -lstdc++

.PATH: ${CPPS:H}

.for d in oless/h jpeg ole basics ri_image oless fpx .
CXXFLAGS+=	-I${.CURDIR}/$d
.endfor

CXXFLAGS+=	-I${LOCALBASE}/include -D_UNIX

.include <bsd.lib.mk>

# Work-around the bug in g++4.2's system header:
# /usr/include/c++/4.2/bits/basic_ios.h:156: warning: empty body in an if-statement
CXXFLAGS:=	${CXXFLAGS:N-Wsystem-headers}