On 05/15/2012 05:24 PM, Peter Hutterer wrote: > On Tue, May 15, 2012 at 04:51:40PM -0700, Chase Douglas wrote: >> On 05/15/2012 04:18 PM, Peter Hutterer wrote: >>> On Tue, May 15, 2012 at 11:05:25AM -0700, Chase Douglas wrote: > > [snip] > >>>> + >>>> + GTEST_CPPFLAGS="$GTEST_CPPFLAGS -I$GTEST_SOURCE" >>>> + >>>> + AC_CHECK_FILES([$GTEST_SOURCE/src/gtest-all.cc] >>>> + [$GTEST_SOURCE/src/gtest_main.cc], >>>> + [have_gtest=yes], >>>> + [have_gtest=no]) >>>> + >>>> + AS_IF([test "x$have_gtest_source" = xyes], >>>> + [AC_SUBST(GTEST_CPPFLAGS)] >>>> + [AC_SUBST(GTEST_SOURCE)]) >>>> +]) # _CHECK_GTEST >>>> + >>>> +# CHECK_XORG_GTEST([ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) >>>> +# >>>> +# Checks whether the xorg-gtest source is available on the system. Allows >>>> for >>>> +# adjusting the include and source path. Sets have_xorg_gtest=yes if the >>>> source >>>> +# is present. Sets XORG_GTEST_CPPFLAGS and XORG_GTEST_SOURCE to the >>>> preprocessor >>>> +# flags and source location respectively. Sets XORG_GTEST_LIBS to all the >>>> +# libraries needed to link against a built xorg-gtest library. >>>> +# >>>> +# Both default actions are no-ops. >>>> +AC_DEFUN([CHECK_XORG_GTEST], >>>> +[ >>>> + AC_REQUIRE([_CHECK_GTEST]) >>>> + >>>> + PKG_CHECK_EXISTS([xorg-gtest], >>>> + [have_xorg_gtest=yes], >>>> + [have_xorg_gtest=no]) >>>> + >>>> + XORG_GTEST_SOURCE=`$PKG_CONFIG --variable=sourcedir --print-errors >>>> xorg-gtest` >>>> + XORG_GTEST_CPPFLAGS=`$PKG_CONFIG --variable=CPPflags --print-errors >>>> xorg-gtest` >>>> + XORG_GTEST_CPPFLAGS="$GTEST_CPPFLAGS $XORG_GTEST_CPPFLAGS" >>>> + XORG_GTEST_CPPFLAGS="$XORG_GTEST_CPPFLAGS -I$XORG_GTEST_SOURCE" >>>> + >>>> + PKG_CHECK_MODULES(X11, [x11], [have_x11=yes], [have_x11=no]) >>>> + >>>> + # Check if we should include support for utouch-evemu >>>> + AC_ARG_WITH([evemu], >>>> + [AS_HELP_STRING([--with-evemu], >>>> + [support Linux input device recording >>>> playback >>> >>> does anyone actually use the term "Linux input device recording playback" >>> instead of just calling it evemu? >> >> I can see a BSD user not realizing that it's Linux only. This is a file >> copied from the xorg-gtest distribution (via aclocal), so if you want to >> change it send a patch there. But I don't see why a more verbose >> configure help string is a problem :). > > mostly because I'd have no idea what "Linux input device recording playback" > is, whereas the term evemu is slowly becoming popular given that I stick it > into most bugreports these days.
The option is called --with-evemu, so I hope that's clear enough. [snip] >>>> diff --git a/test/integration/Makefile-xorg-gtest.am >>>> b/test/integration/Makefile-xorg-gtest.am >>>> new file mode 100644 >>>> index 0000000..185381d >>>> --- /dev/null >>>> +++ b/test/integration/Makefile-xorg-gtest.am >>>> @@ -0,0 +1,61 @@ >>>> +# Copyright (C) 2012 Canonical, Ltd. >>>> +# >>>> +# Permission is hereby granted, free of charge, to any person obtaining a >>>> copy >>>> +# of this software and associated documentation files (the "Software"), >>>> to deal >>>> +# in the Software without restriction, including without limitation the >>>> rights >>>> +# to use, copy, modify, merge, publish, distribute, sublicense, and/or >>>> sell >>>> +# copies of the Software, and to permit persons to whom the Software is >>>> +# furnished to do so, subject to the following conditions: >>>> +# >>>> +# The above copyright notice and this permission notice (including the >>>> next >>>> +# paragraph) shall be included in all copies or substantial portions of >>>> the >>>> +# Software. >>>> +# >>>> +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS >>>> OR >>>> +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, >>>> +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL >>>> THE >>>> +# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER >>>> +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING >>>> FROM, >>>> +# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS >>>> IN THE >>>> +# SOFTWARE. >>>> +# >>>> + >>>> +XORG_GTEST_BUILD_LIBS = \ >>>> + libgtest.a \ >>>> + libgtest_main.a \ >>>> + libxorg-gtest.a \ >>>> + libxorg-gtest_main.a >>>> + >>>> +nodist_libgtest_a_SOURCES = $(GTEST_SOURCE)/src/gtest-all.cc >>>> +libgtest_a_CPPFLAGS = $(GTEST_CPPFLAGS) $(AM_CPPFLAGS) -w >>>> +libgtest_a_CXXFLAGS = $(GTEST_CXXFLAGS) $(AM_CXXFLAGS) >>>> + >>>> +nodist_libgtest_main_a_SOURCES = $(GTEST_SOURCE)/src/gtest_main.cc >>>> +libgtest_main_a_CPPFLAGS = $(GTEST_CPPFLAGS) $(AM_CPPFLAGS) -w >>>> +libgtest_main_a_CXXFLAGS = $(GTEST_CXXFLAGS) $(AM_CXXFLAGS) >>>> + >>>> +nodist_libxorg_gtest_a_SOURCES = >>>> $(XORG_GTEST_SOURCE)/src/xorg-gtest-all.cpp >>>> +libxorg_gtest_a_CPPFLAGS = \ >>>> + $(XORG_GTEST_CPPFLAGS) \ >>>> + $(GTEST_CPPFLAGS) \ >>>> + $(AM_CPPFLAGS) \ >>>> + -w >>> >>> -w? really? >> >> Note that this is also another xorg-gtest file, so any changes would >> need to be patched there :). >> >> The reason for the -w here is that we don't want to cause warnings (and >> errors when built with -Werror) due to issues in xorg-gtest and gtest >> themselves. This flag is only used for building those sources. It isn't >> used for building any tests in the project that is using xorg-gtest. > > can we somehow pop a comment in there? that wasn't obvious to me on first > sight. plus, I keep forgetting that the libs need to be re-built instead of > just linking to... I just sent out a patch to xorg-gtest to do this, and I'll update this patch to include this change too. -- Chase _______________________________________________ [email protected]: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel
