diff options
-rw-r--r-- | ChangeLog | 12 | ||||
-rw-r--r-- | Makefile.am | 6 | ||||
-rw-r--r-- | configure.ac | 24 | ||||
-rw-r--r-- | hw/dmx/config/Makefile.am | 1 | ||||
-rw-r--r-- | hw/dmx/examples/Makefile.am | 15 | ||||
-rw-r--r-- | hw/xfree86/dri/Makefile.am | 3 | ||||
-rw-r--r-- | hw/xfree86/utils/xorgcfg/Makefile.am | 2 | ||||
-rw-r--r-- | xorg-server.m4 | 48 |
8 files changed, 99 insertions, 12 deletions
@@ -1,3 +1,15 @@ +2005-11-01 Kevin E. Martin <kem-at-freedesktop-dot-org> + + * Makefile.am: + Add xorg-server.m4 for driver dependency checking. + + * configure.ac: + * hw/dmx/config/Makefile.am: + * hw/dmx/examples/Makefile.am: + * hw/xfree86/dri/Makefile.am: + * hw/xfree86/utils/xorgcfg/Makefile.am: + Update pkgcheck depedencies to work with separate build roots. + 2005-10-28 Alan Coopersmith <alan.coopersmith@sun.com> * hw/xfree86/Makefile.am: diff --git a/Makefile.am b/Makefile.am index d9e5f497d..252d99b21 100644 --- a/Makefile.am +++ b/Makefile.am @@ -67,9 +67,13 @@ SUBDIRS = \ $(XPDDX_DIR) \ $(XPCONFIG_DIR) +aclocaldir = $(datadir)/aclocal +aclocal_DATA = xorg-server.m4 + pkgconfigdir = $(libdir)/pkgconfig pkgconfig_DATA = xorg-server.pc -EXTRA_DIST = xorg-server.pc.in + +EXTRA_DIST = xorg-server.pc.in xorg-server.m4 DIST_SUBDIRS = \ doc \ diff --git a/configure.ac b/configure.ac index bb2db007d..530d74a34 100644 --- a/configure.ac +++ b/configure.ac @@ -434,7 +434,7 @@ XEXT_INC='-I$(top_srcdir)/Xext' XEXT_LIB='$(top_builddir)/Xext/libXext.la' dnl Core modules for most extensions, et al. -REQUIRED_MODULES="randrproto renderproto fixesproto damageproto xcmiscproto xextproto xfont xproto xtrans xau xf86miscproto xf86vidmodeproto xf86bigfontproto scrnsaverproto bigreqsproto resourceproto fontenc fontsproto" +REQUIRED_MODULES="randrproto renderproto fixesproto damageproto xcmiscproto xextproto xfont xproto xtrans xau xf86miscproto xf86vidmodeproto xf86bigfontproto scrnsaverproto bigreqsproto resourceproto fontenc fontsproto inputproto xf86dgaproto" AM_CONDITIONAL(XV, [test "x$XV" = xyes]) if test "x$XV" = xyes; then @@ -445,7 +445,6 @@ fi AM_CONDITIONAL(DGA, [test "x$DGA" = xyes]) if test "x$DGA" = xyes; then AC_DEFINE(DGA, 1, [Support DGA extension]) - REQUIRED_MODULES="$REQUIRED_MODULES xf86dgaproto" fi AM_CONDITIONAL(COMPOSITE, [test "x$COMPOSITE" = xyes]) @@ -511,11 +510,10 @@ if test "x$DRI" = xyes; then AC_DEFINE(XF86DRI, 1, [Build DRI extension]) PKG_CHECK_MODULES([DRIPROTO], [xf86driproto]) PKG_CHECK_MODULES([LIBDRM], [libdrm]) - if test "x$GLX" = xyes; then - PKG_CHECK_MODULES([GL], [glproto >= 1.4.1]) - fi + PKG_CHECK_MODULES([GL], [glproto >= 1.4.1]) AC_SUBST(DRIPROTO_CFLAGS) AC_SUBST(LIBDRM_CFLAGS) + AC_SUBST(GL_CFLAGS) fi AM_CONDITIONAL(XINERAMA, [test "x$XINERAMA" = xyes]) @@ -577,6 +575,15 @@ if test "x$XF86MISC" = xyes; then AC_DEFINE(XF86MISC, 1, [Support XFree86 miscellaneous extensions]) fi +if test "x$XPRINT" = xauto; then + PKG_CHECK_MODULES([XPRINT], [printproto], [XPRINT=yes], [XPRINT=no]) +fi +AM_CONDITIONAL(XPRINT, [test "x$XPRINT" = xyes]) +if test "x$XPRINT" = xyes; then + AC_DEFINE(XPRINT, 1, [Build Print extension]) + REQUIRED_MODULES="$REQUIRED_MODULES printproto" +fi + AC_DEFINE(RENDER, 1, [Support RENDER extension]) RENDER_LIB='$(top_builddir)/render/librender.la' RENDER_INC='-I$(top_srcdir)/render' @@ -746,6 +753,7 @@ dnl Linux sources in DMX require <linux/keyboard.h> PKG_CHECK_MODULES([GL], [glproto]) fi PKG_CHECK_MODULES([XDMXCONFIG_DEP], [xaw7 xmu xt xpm x11]) + AC_SUBST(XDMXCONFIG_DEP_CFLAGS) AC_SUBST(XDMXCONFIG_DEP_LIBS) PKG_CHECK_MODULES([DMXEXAMPLES_DEP], [dmx xext x11]) AC_SUBST(DMXEXAMPLES_DEP_LIBS) @@ -989,12 +997,8 @@ AM_CONDITIONAL(AFB, [test "x$XORG" = xyes]) dnl Xprint DDX -if test "x$XPRINT" = xauto; then - PKG_CHECK_MODULES([XPRINT], [printproto x11], [XPRINT=yes], [XPRINT=no]) -fi AC_MSG_CHECKING([whether to build Xprint DDX]) AC_MSG_RESULT([$XPRINT]) -AM_CONDITIONAL(XPRINT, [test x$XPRINT = xyes]) if test "x$XPRINT" = xyes; then PKG_CHECK_MODULES([XPRINT], [printproto x11 xfont $XDMCP_MODULES xau]) @@ -1135,6 +1139,8 @@ if test x$XORGCFG = xyes ; then AC_CHECK_LIB([ncurses],[waddstr], [XORGCFG_DEP_LIBS="$XORGCFG_DEP_LIBS -lncurses" ; CURSES=yes], [CURSES=no])) + AC_SUBST(XORGCFG_DEP_CFLAGS) + AC_SUBST(XORGCFG_DEP_LIBS) fi AM_CONDITIONAL(BUILD_XORGCFG, [test x$XORGCFG = xyes]) AM_CONDITIONAL(USE_CURSES, [test x$CURSES = xyes]) diff --git a/hw/dmx/config/Makefile.am b/hw/dmx/config/Makefile.am index e7d08aaa2..838b3b834 100644 --- a/hw/dmx/config/Makefile.am +++ b/hw/dmx/config/Makefile.am @@ -37,6 +37,7 @@ xdmxconfig_SOURCES = \ Canvas.h \ CanvasP.h xdmxconfig_LDADD = -L. -ldmxconfig @XDMXCONFIG_DEP_LIBS@ +xdmxconfig_CFLAGS = $(AM_CFLAGS) @XDMXCONFIG_DEP_CFLAGS@ vdltodmx_DEPENDENCIES = libdmxconfig.a vdltodmx_SOURCES = vdltodmx.c diff --git a/hw/dmx/examples/Makefile.am b/hw/dmx/examples/Makefile.am index 9a7f19e25..d814339fc 100644 --- a/hw/dmx/examples/Makefile.am +++ b/hw/dmx/examples/Makefile.am @@ -11,45 +11,60 @@ noinst_PROGRAMS = xinput xtest evi res xled xbell $(EV_PROG) xdmx_SOURCES = xdmx.c xdmx_LDADD = @DMXEXAMPLES_DEP_LIBS@ +xdmx_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@ dmxwininfo_SOURCES = dmxwininfo.c dmxwininfo_LDADD = @DMXXMUEXAMPLES_DEP_LIBS@ +dmxwininfo_CFLAGS = @DMXXMUEXAMPLES_DEP_CFLAGS@ dmxreconfig_SOURCES = dmxreconfig.c dmxreconfig_LDADD = @DMXEXAMPLES_DEP_LIBS@ +dmxreconfig_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@ dmxresize_SOURCES = dmxresize.c dmxresize_LDADD = @DMXEXAMPLES_DEP_LIBS@ +dmxresize_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@ dmxaddscreen_SOURCES = dmxaddscreen.c dmxaddscreen_LDADD = @DMXEXAMPLES_DEP_LIBS@ +dmxaddscreen_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@ dmxrmscreen_SOURCES = dmxrmscreen.c dmxrmscreen_LDADD = @DMXEXAMPLES_DEP_LIBS@ +dmxrmscreen_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@ dmxaddinput_SOURCES = dmxaddinput.c dmxaddinput_LDADD = @DMXEXAMPLES_DEP_LIBS@ +dmxaddinput_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@ dmxrminput_SOURCES = dmxrminput.c dmxrminput_LDADD = @DMXEXAMPLES_DEP_LIBS@ +dmxrminput_CFLAGS = @DMXEXAMPLES_DEP_CFLAGS@ xinput_SOURCES = xinput.c xinput_LDADD = @DMXXIEXAMPLES_DEP_LIBS@ +xinput_CFLAGS = @DMXXIEXAMPLES_DEP_CFLAGS@ xtest_SOURCES = xtest.c xtest_LDADD = @XTSTEXAMPLES_DEP_LIBS@ +xtest_CFLAGS = @XTSTEXAMPLES_DEP_CFLAGS@ evi_SOURCES = evi.c evi_LDADD = @X11EXAMPLES_DEP_LIBS@ +evi_CFLAGS = @X11EXAMPLES_DEP_CFLAGS@ res_SOURCES = res.c res_LDADD = @XRESEXAMPLES_DEP_LIBS@ +res_CFLAGS = @XRESEXAMPLES_DEP_CFLAGS@ xled_SOURCES = xled.c xled_LDADD = @X11EXAMPLES_DEP_LIBS@ +xled_CFLAGS = @X11EXAMPLES_DEP_CFLAGS@ xbell_SOURCES = xbell.c xbell_LDADD = @X11EXAMPLES_DEP_LIBS@ +xbell_CFLAGS = @X11EXAMPLES_DEP_CFLAGS@ ev_SOURCES = ev.c ev_LDADD = +ev_CFLAGS = diff --git a/hw/xfree86/dri/Makefile.am b/hw/xfree86/dri/Makefile.am index ee665f8d7..6a3c96170 100644 --- a/hw/xfree86/dri/Makefile.am +++ b/hw/xfree86/dri/Makefile.am @@ -9,7 +9,8 @@ libdri_la_CFLAGS = -I$(top_srcdir)/hw/xfree86/common \ -DHAVE_XORG_CONFIG_H \ -DXFree86Module -DIN_MODULE \ @DRIPROTO_CFLAGS@ \ - @LIBDRM_CFLAGS@ + @LIBDRM_CFLAGS@ \ + @GL_CFLAGS@ libdri_la_LDFLAGS = -module -avoid-version libdri_ladir = $(moduledir)/extensions libdri_la_SOURCES = \ diff --git a/hw/xfree86/utils/xorgcfg/Makefile.am b/hw/xfree86/utils/xorgcfg/Makefile.am index 2c6bcaea3..3b28b17bf 100644 --- a/hw/xfree86/utils/xorgcfg/Makefile.am +++ b/hw/xfree86/utils/xorgcfg/Makefile.am @@ -31,7 +31,7 @@ bin_PROGRAMS = xorgcfg INCLUDES = $(XORG_INCS) -I$(top_srcdir)/hw/xfree86/parser -xorgcfg_CFLAGS = $(XORG_CFLAGS) $(CURSESDEFINES) +xorgcfg_CFLAGS = $(XORG_CFLAGS) $(CURSESDEFINES) $(XORGCFG_DEP_CFLAGS) xorgcfg_LDADD = $(XORGCFG_DEP_LIBS) ../../parser/libparser.a $(LOADERLIB) \ ../../os-support/libxorgos.la ../../dummylib/libdummy-nonserver.a diff --git a/xorg-server.m4 b/xorg-server.m4 new file mode 100644 index 000000000..2d16438e1 --- /dev/null +++ b/xorg-server.m4 @@ -0,0 +1,48 @@ +dnl Copyright 2005 Red Hat, Inc +dnl +dnl Permission to use, copy, modify, distribute, and sell this software and its +dnl documentation for any purpose is hereby granted without fee, provided that +dnl the above copyright notice appear in all copies and that both that +dnl copyright notice and this permission notice appear in supporting +dnl documentation. +dnl +dnl The above copyright notice and this permission notice shall be included +dnl in all copies or substantial portions of the Software. +dnl +dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +dnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +dnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +dnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR +dnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +dnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +dnl OTHER DEALINGS IN THE SOFTWARE. +dnl +dnl Except as contained in this notice, the name of the copyright holders shall +dnl not be used in advertising or otherwise to promote the sale, use or +dnl other dealings in this Software without prior written authorization +dnl from the copyright holders. +dnl + +# XORG_DRIVER_CHECK_EXT() +# -------------------------- +# Checks for the $1 define in xorg-server.h (from the sdk). If it +# is defined, then add $1 to $REQUIRED_MODULES. + +AC_DEFUN([XORG_DRIVER_CHECK_EXT],[ + SAVE_CFLAGS="$CFLAGS" + CFLAGS="$CFLAGS -I`pkg-config --variable=sdkdir xorg-server`" + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ +#include "xorg-server.h" +#if !defined $1 +#error $1 not defined +#endif + ]])], + [_EXT_CHECK=yes], + [_EXT_CHECK=no]) + CFLAGS="$SAVE_CFLAGS" + AC_MSG_CHECKING([if $1 is defined]) + AC_MSG_RESULT([$_EXT_CHECK]) + if test "$_EXT_CHECK" != no; then + REQUIRED_MODULES="$REQUIRED_MODULES $2" + fi +]) |