[PATCH xrandr-utils 2/6] Import xrandr.c and its test as implementation examples.

Gaetan Nadon memsize at videotron.ca
Thu Dec 22 07:11:24 PST 2011


On 11-12-21 09:47 PM, Bryce Harrington wrote:
> Over the course of this development effort, code will be refactored out
> of xrandr.c into the library source.  As this is done, the corresponding
> code will be excised from this copy of xrandr.c and replaced with the
> new API calls.
>
> This will enable before/after testing of xrandr behavior to catch
> functional regressions.
>
> Ultimately, prior to libXrandrUtils 1.0.0, this work should be complete
> and xrandr.c migrated back home to the xrandr package.
>
> Signed-off-by: Bryce Harrington<bryce at canonical.com>
> ---
>   Makefile.am          |    2 +-
>   configure.ac         |    1 +
>   examples/Makefile.am |   13 +
>   examples/xrandr.c    | 3433 ++++++++++++++++++++++++++++++++++++++++++++++++++
>   4 files changed, 3448 insertions(+), 1 deletions(-)
>   create mode 100644 examples/Makefile.am
>   create mode 100644 examples/xrandr.c
>
> diff --git a/Makefile.am b/Makefile.am
> index 1b5ac68..607dfc1 100644
> --- a/Makefile.am
> +++ b/Makefile.am
> @@ -19,7 +19,7 @@
>   #  TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
>   #  PERFORMANCE OF THIS SOFTWARE.
>
> -SUBDIRS = man src
> +SUBDIRS = examples man src
>
>   pkgconfigdir = $(libdir)/pkgconfig
>   pkgconfig_DATA = xrandr-utils.pc
> diff --git a/configure.ac b/configure.ac
> index 794ba19..7ebefd8 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -55,6 +55,7 @@ PKG_CHECK_MODULES(RANDRUTILS, x11 xrandr>= 1.3 xrender xproto>= 7.0.17)
>
>   AC_CONFIG_FILES([
>   	Makefile
> +	examples/Makefile
>   	man/Makefile
>   	src/Makefile
>   	xrandr-utils.pc])
> diff --git a/examples/Makefile.am b/examples/Makefile.am
> new file mode 100644
> index 0000000..86e9943
> --- /dev/null
> +++ b/examples/Makefile.am
> @@ -0,0 +1,13 @@
> +bin_PROGRAMS = xrandr
> +
> +AM_CFLAGS = \
> +	$(RANDUTILS_CFLAGS) \
Typo, should be RANDRUTILS.
Even after fixing that I still get:
../../examples/xrandr.c:29:22: fatal error: X11/Xlib.h: No such file or 
directory


Remove the developer headers installed by your distro to reproduce.
I'll check that again later, got to go now...

Using git://people.freedesktop.org/~bryce/libXrandrUtils 
<git://people.freedesktop.org/%7Ebryce/libXrandrUtils> which should be 
the same as your patches.
> +	$(MALLOC_ZERO_CFLAGS) \
> +	$(CWARNFLAGS)
> +xrandr_LDADD = @RANDRUTILS_LIBS@
> +
> +INCLUDES = -I$(top_srcdir)/include/X11/extensions
> +
> +xrandr_SOURCES =	\
> +        xrandr.c
> +

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.x.org/archives/xorg-devel/attachments/20111222/1f225f41/attachment.htm>


More information about the xorg-devel mailing list