1 # $NetBSD: Makefile.xf86-driver,v 1.19 2010/11/23 08:22:29 mrg Exp $
4 SHLIB_MAJOR= ${PACKAGE_MAJOR}
10 LIBDIR= ${X11USRLIBDIR}/modules/drivers
12 # Extract version from configure script if not set in makefile.
14 .if defined(DRIVER_VERSION)
15 PACKAGE_VERSION= ${DRIVER_VERSION}
17 PRINT_PACKAGE_VERSION= ${TOOL_AWK} '/^PACKAGE_VERSION=/ { \
18 match($$1, "[0-9]+\\.[0-9]+\\.[0-9]+"); \
19 version = substr($$1, RSTART, RLENGTH); \
20 } END { print version }' \
21 ${X11SRCDIR.${DRIVER}}/configure
23 PACKAGE_VERSION!= ${PRINT_PACKAGE_VERSION}
26 PACKAGE_MAJOR= ${PACKAGE_VERSION:R:R}
27 PACKAGE_MINOR= ${PACKAGE_VERSION:R:E}
28 PACKAGE_PATCH= ${PACKAGE_VERSION:E}
30 CPPFLAGS+= -I${DESTDIR}${X11INCDIR}/X11 \
31 -I${DESTDIR}${X11INCDIR}/X11/dri \
32 -I${DESTDIR}${X11INCDIR}/xorg \
33 -I${DESTDIR}${X11INCDIR}/pixman-1 \
34 -I${X11SRCDIR.xorg-server}/../include \
35 ${X11FLAGS.EXTENSION} \
37 -DHAVE_XORG_SERVER_1_1_0 \
39 -DXSERVER_LIBPCIACCESS \
43 CPPFLAGS+= -DPACKAGE_VERSION_MAJOR=${PACKAGE_MAJOR}
44 CPPFLAGS+= -DPACKAGE_VERSION_MINOR=${PACKAGE_MINOR}
45 CPPFLAGS+= -DPACKAGE_VERSION_PATCHLEVEL=${PACKAGE_PATCH}
46 CPPFLAGS+= -DXORG_VERSION_CURRENT=${XORG_VERSION_CURRENT}
48 .PATH: ${X11SRCDIR.${DRIVER}}/src
49 .PATH: ${X11SRCDIR.${DRIVER}}/man