summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--AUTHORS2
-rw-r--r--COPYING19
-rw-r--r--ChangeLog171
-rw-r--r--INSTALL229
-rw-r--r--Makefile.am31
-rw-r--r--NEWS0
-rw-r--r--README0
-rwxr-xr-xautogen.sh12
-rw-r--r--configure.ac145
-rw-r--r--man/Makefile.am3
-rw-r--r--src/Makefile.am15
-rw-r--r--xcursor.pc.in15
12 files changed, 642 insertions, 0 deletions
diff --git a/AUTHORS b/AUTHORS
new file mode 100644
index 0000000..57c4efd
--- /dev/null
+++ b/AUTHORS
@@ -0,0 +1,2 @@
+Keith Packard, HP
+
diff --git a/COPYING b/COPYING
new file mode 100644
index 0000000..8d01a81
--- /dev/null
+++ b/COPYING
@@ -0,0 +1,19 @@
+Copyright © 2002 Keith Packard
+
+Permission to use, copy, modify, distribute, and sell this software and its
+documentation for any purpose is hereby granted without fee, provided that
+the above copyright notice appear in all copies and that both that
+copyright notice and this permission notice appear in supporting
+documentation, and that the name of Keith Packard not be used in
+advertising or publicity pertaining to distribution of the software without
+specific, written prior permission. Keith Packard makes no
+representations about the suitability of this software for any purpose. It
+is provided "as is" without express or implied warranty.
+
+KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
+INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
+EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR
+CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
+DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+PERFORMANCE OF THIS SOFTWARE.
diff --git a/ChangeLog b/ChangeLog
new file mode 100644
index 0000000..4b154dc
--- /dev/null
+++ b/ChangeLog
@@ -0,0 +1,171 @@
+Tue Feb 8 14:26:32 2005 Owen Taylor <otaylor@redhat.com>
+
+ * configure.ac: Remove AC_CONFIG_AUX_DIR()
+
+2004-04-13 Daniel Stone <daniel@freedesktop.org>
+
+ * ChangeLog:
+ Tag 1.1.3, for xlibs 1.0.1.
+
+2004-04-07 Keith Packard <keithp@keithp.com>
+
+ reviewed by: Michel Dänzer <michel@daenzer.net>
+
+ * configure.ac:
+ Make sure X_CFLAGS/X_LIBS are substituted in the xcursor.pc file
+
+2004-02-24 Fredrik Höglund <fredrik@kde.org>
+
+ * configure.ac:
+ * xcursorint.h:
+ Make the Xfixes code actually work by including the Xfixes.h
+ header file.
+
+2004-02-03 Jim Gettys <jg@freedesktop.org>
+
+ * AUTHORS: Add contents to author's file
+
+2004-01-17 Daniel Stone <daniel@fooishbar.org>
+ * Xcursor.h:
+ * configure.ac:
+ Bump package version to 1.1.2, slated for first fd.o platform release.
+
+2004-01-15 Harold L Hunt II <huntharo@msu.edu>
+ * Makefile.am: Pass -no-undefined to libtool via LDFLAGS.
+
+2003-11-10 Keith Packard <keithp@keithp.com>
+
+ * library.c: (_XcursorBuildThemeDir):
+ Make sure the allocated path has space for directory separators
+
+2003-10-29 Keith Packard <keithp@keithp.com>
+
+ * Xcursor.h:
+ * configure.ac:
+ Bump package version to 1.1.1 and library info to 1.2.0 as
+ the library exports new name-based APIs and uses Xfixes
+
+2003-10-28 Keith Packard <keithp@keithp.com>
+
+ * Makefile.am:
+ * Xcursor.h:
+ * configure.ac:
+ * cursor.c: (XcursorImagesLoadCursor):
+ * file.c: (XcursorImagesCreate), (XcursorImagesDestroy),
+ (XcursorImagesSetName):
+ * library.c: (XcursorLibraryLoadImages),
+ (XcursorLibraryLoadCursor):
+ Add support for XFixes version 2 cursor naming functions
+
+2003-10-16 23:45 fredrik
+
+ * Xcursor-def.cpp, Xcursor.h, configure.ac, library.c:
+ Rename _XcursorLibraryPath() to XcursorLibraryPath() and make
+ it a public function, since it's useful for theme selectors.
+ Bump version to 1.1.0
+
+2003-05-21 10:21 keithp
+
+ * Makefile.am, Xcursor.h, configure.ac, xcursorint.h: Package
+ Xcursor.3, bump version to 1.0.2
+
+2003-05-06 11:20 keithp
+
+ * ChangeLog: Add initial change log
+
+2003-05-06 11:09 keithp
+
+ * .cvsignore, Makefile.am, Xcursor-def.cpp, Xcursor.3, Xcursor.h,
+ Xcursor.man, cursor.c, display.c, file.c, library.c, xcursorint.h,
+ xlib.c: Update .cvsignore, move manual and install, fix CVS ident
+ lines
+
+2003-05-06 11:00 keithp
+
+ * configure.ac: replace Xrender test with fragment from Xft
+
+2003-05-06 10:52 keithp
+
+ * Makefile.am: Add xcursorint.h to library sources list
+
+2003-05-06 10:49 keithp
+
+ * Imakefile, Makefile.am, Xcursor.h, autogen.sh, configure.ac,
+ file.c, xcursor.pc.in: Convert Xcursor to autotools
+
+2003-02-21 22:16 dawes
+
+ * xlib.c: 941. Fix a problem where a malformed Ximage can cause
+ Xcursor to step
+ outside the image data (#A.1636, Keith Packard, reported by
+ Michel Dänzer).
+
+2003-02-19 19:13 dawes
+
+ * display.c: 924. Fix a memory leak in XCloseDisplay, and a
+ potential race condition
+ when multiple threads attempt to initialize the Xcursor
+ library
+ simultaneously (#A.1623, Keith Packard).
+
+2003-02-12 19:09 dawes
+
+ * Xcursor.man: 880. Fix the Xcursor include path in the man page
+ (#5617, Kevin Brosius).
+
+2003-01-25 19:22 eich
+
+ * Xcursor.h, cursor.c, library.c, xcursorint.h: 787. Add "core"
+ theme to Xcursor to force old behaviour (Keith Packard).
+
+2002-11-26 21:35 keithp
+
+ * display.c: Fix XcursorSetTheme to permit NULL theme
+
+2002-11-22 18:34 keithp
+
+ * Xcursor.h, cursor.c, display.c, xcursorint.h, xlib.c: Add animate
+ cursor support, client side
+
+2002-10-11 10:06 keithp
+
+ * cursor.c: Off by one in XcursorAnimateNext (from Anders Carlsson)
+
+2002-09-30 15:02 alanh
+
+ * Xcursor-def.cpp: add Xv-def.cpp file add $XFree86$ tags
+
+2002-09-26 00:52 alanh
+
+ * Imakefile: #elif -> #else
+
+2002-09-25 16:27 alanh
+
+ * Xcursor-def.cpp: #5350, add Xcursor-def.cpp
+
+2002-09-25 09:10 torrey
+
+ * Imakefile: Add SharedXcursorReqs for operating systems that
+ require it.
+
+2002-09-18 10:11 tsi
+
+ * file.c: Pacify gcc 3.2
+
+2002-09-05 00:55 keithp
+
+ * display.c: Clean up parsing of option that forces use of core
+ cursors
+
+2002-09-05 00:29 keithp
+
+ * Xcursor.h, cursor.c, display.c, xcursorint.h, xlib.c: Add
+ themeable app-specific cursors. Add dithers for core cursors.
+ Dont theme servers without Render by default
+
+2002-08-28 21:40 keithp
+
+ * Imakefile, Xcursor.h, Xcursor.man, config-subst, cursor.c,
+ display.c, file.c, library.c, xcursor-config.in, xcursor.pc.in,
+ xcursorint.h, xlib.c: Add Xcursor library and Xlib hooks for it
+
diff --git a/INSTALL b/INSTALL
new file mode 100644
index 0000000..54caf7c
--- /dev/null
+++ b/INSTALL
@@ -0,0 +1,229 @@
+Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002 Free Software
+Foundation, Inc.
+
+ This file is free documentation; the Free Software Foundation gives
+unlimited permission to copy, distribute and modify it.
+
+Basic Installation
+==================
+
+ These are generic installation instructions.
+
+ The `configure' shell script attempts to guess correct values for
+various system-dependent variables used during compilation. It uses
+those values to create a `Makefile' in each directory of the package.
+It may also create one or more `.h' files containing system-dependent
+definitions. Finally, it creates a shell script `config.status' that
+you can run in the future to recreate the current configuration, and a
+file `config.log' containing compiler output (useful mainly for
+debugging `configure').
+
+ It can also use an optional file (typically called `config.cache'
+and enabled with `--cache-file=config.cache' or simply `-C') that saves
+the results of its tests to speed up reconfiguring. (Caching is
+disabled by default to prevent problems with accidental use of stale
+cache files.)
+
+ If you need to do unusual things to compile the package, please try
+to figure out how `configure' could check whether to do them, and mail
+diffs or instructions to the address given in the `README' so they can
+be considered for the next release. If you are using the cache, and at
+some point `config.cache' contains results you don't want to keep, you
+may remove or edit it.
+
+ The file `configure.ac' (or `configure.in') is used to create
+`configure' by a program called `autoconf'. You only need
+`configure.ac' if you want to change it or regenerate `configure' using
+a newer version of `autoconf'.
+
+The simplest way to compile this package is:
+
+ 1. `cd' to the directory containing the package's source code and type
+ `./configure' to configure the package for your system. If you're
+ using `csh' on an old version of System V, you might need to type
+ `sh ./configure' instead to prevent `csh' from trying to execute
+ `configure' itself.
+
+ Running `configure' takes awhile. While running, it prints some
+ messages telling which features it is checking for.
+
+ 2. Type `make' to compile the package.
+
+ 3. Optionally, type `make check' to run any self-tests that come with
+ the package.
+
+ 4. Type `make install' to install the programs and any data files and
+ documentation.
+
+ 5. You can remove the program binaries and object files from the
+ source code directory by typing `make clean'. To also remove the
+ files that `configure' created (so you can compile the package for
+ a different kind of computer), type `make distclean'. There is
+ also a `make maintainer-clean' target, but that is intended mainly
+ for the package's developers. If you use it, you may have to get
+ all sorts of other programs in order to regenerate files that came
+ with the distribution.
+
+Compilers and Options
+=====================
+
+ Some systems require unusual options for compilation or linking that
+the `configure' script does not know about. Run `./configure --help'
+for details on some of the pertinent environment variables.
+
+ You can give `configure' initial values for configuration parameters
+by setting variables in the command line or in the environment. Here
+is an example:
+
+ ./configure CC=c89 CFLAGS=-O2 LIBS=-lposix
+
+ *Note Defining Variables::, for more details.
+
+Compiling For Multiple Architectures
+====================================
+
+ You can compile the package for more than one kind of computer at the
+same time, by placing the object files for each architecture in their
+own directory. To do this, you must use a version of `make' that
+supports the `VPATH' variable, such as GNU `make'. `cd' to the
+directory where you want the object files and executables to go and run
+the `configure' script. `configure' automatically checks for the
+source code in the directory that `configure' is in and in `..'.
+
+ If you have to use a `make' that does not support the `VPATH'
+variable, you have to compile the package for one architecture at a
+time in the source code directory. After you have installed the
+package for one architecture, use `make distclean' before reconfiguring
+for another architecture.
+
+Installation Names
+==================
+
+ By default, `make install' will install the package's files in
+`/usr/local/bin', `/usr/local/man', etc. You can specify an
+installation prefix other than `/usr/local' by giving `configure' the
+option `--prefix=PATH'.
+
+ You can specify separate installation prefixes for
+architecture-specific files and architecture-independent files. If you
+give `configure' the option `--exec-prefix=PATH', the package will use
+PATH as the prefix for installing programs and libraries.
+Documentation and other data files will still use the regular prefix.
+
+ In addition, if you use an unusual directory layout you can give
+options like `--bindir=PATH' to specify different values for particular
+kinds of files. Run `configure --help' for a list of the directories
+you can set and what kinds of files go in them.
+
+ If the package supports it, you can cause programs to be installed
+with an extra prefix or suffix on their names by giving `configure' the
+option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
+
+Optional Features
+=================
+
+ Some packages pay attention to `--enable-FEATURE' options to
+`configure', where FEATURE indicates an optional part of the package.
+They may also pay attention to `--with-PACKAGE' options, where PACKAGE
+is something like `gnu-as' or `x' (for the X Window System). The
+`README' should mention any `--enable-' and `--with-' options that the
+package recognizes.
+
+ For packages that use the X Window System, `configure' can usually
+find the X include and library files automatically, but if it doesn't,
+you can use the `configure' options `--x-includes=DIR' and
+`--x-libraries=DIR' to specify their locations.
+
+Specifying the System Type
+==========================
+
+ There may be some features `configure' cannot figure out
+automatically, but needs to determine by the type of machine the package
+will run on. Usually, assuming the package is built to be run on the
+_same_ architectures, `configure' can figure that out, but if it prints
+a message saying it cannot guess the machine type, give it the
+`--build=TYPE' option. TYPE can either be a short name for the system
+type, such as `sun4', or a canonical name which has the form:
+
+ CPU-COMPANY-SYSTEM
+
+where SYSTEM can have one of these forms:
+
+ OS KERNEL-OS
+
+ See the file `config.sub' for the possible values of each field. If
+`config.sub' isn't included in this package, then this package doesn't
+need to know the machine type.
+
+ If you are _building_ compiler tools for cross-compiling, you should
+use the `--target=TYPE' option to select the type of system they will
+produce code for.
+
+ If you want to _use_ a cross compiler, that generates code for a
+platform different from the build platform, you should specify the
+"host" platform (i.e., that on which the generated programs will
+eventually be run) with `--host=TYPE'.
+
+Sharing Defaults
+================
+
+ If you want to set default values for `configure' scripts to share,
+you can create a site shell script called `config.site' that gives
+default values for variables like `CC', `cache_file', and `prefix'.
+`configure' looks for `PREFIX/share/config.site' if it exists, then
+`PREFIX/etc/config.site' if it exists. Or, you can set the
+`CONFIG_SITE' environment variable to the location of the site script.
+A warning: not all `configure' scripts look for a site script.
+
+Defining Variables
+==================
+
+ Variables not defined in a site shell script can be set in the
+environment passed to `configure'. However, some packages may run
+configure again during the build, and the customized values of these
+variables may be lost. In order to avoid this problem, you should set
+them in the `configure' command line, using `VAR=value'. For example:
+
+ ./configure CC=/usr/local2/bin/gcc
+
+will cause the specified gcc to be used as the C compiler (unless it is
+overridden in the site shell script).
+
+`configure' Invocation
+======================
+
+ `configure' recognizes the following options to control how it
+operates.
+
+`--help'
+`-h'
+ Print a summary of the options to `configure', and exit.
+
+`--version'
+`-V'
+ Print the version of Autoconf used to generate the `configure'
+ script, and exit.
+
+`--cache-file=FILE'
+ Enable the cache: use and save the results of the tests in FILE,
+ traditionally `config.cache'. FILE defaults to `/dev/null' to
+ disable caching.
+
+`--config-cache'
+`-C'
+ Alias for `--cache-file=config.cache'.
+
+`--quiet'
+`--silent'
+`-q'
+ Do not print messages saying which checks are being made. To
+ suppress all normal output, redirect it to `/dev/null' (any error
+ messages will still be shown).
+
+`--srcdir=DIR'
+ Look for the package's source code in directory DIR. Usually
+ `configure' can determine that directory automatically.
+
+`configure' also accepts some other, not widely useful, options. Run
+`configure --help' for more details.
+
diff --git a/Makefile.am b/Makefile.am
new file mode 100644
index 0000000..7a8f39b
--- /dev/null
+++ b/Makefile.am
@@ -0,0 +1,31 @@
+#
+# $Id$
+#
+# Copyright © 2003 Keith Packard, Noah Levitt
+#
+# Permission to use, copy, modify, distribute, and sell this software and its
+# documentation for any purpose is hereby granted without fee, provided that
+# the above copyright notice appear in all copies and that both that
+# copyright notice and this permission notice appear in supporting
+# documentation, and that the name of Keith Packard not be used in
+# advertising or publicity pertaining to distribution of the software without
+# specific, written prior permission. Keith Packard makes no
+# representations about the suitability of this software for any purpose. It
+# is provided "as is" without express or implied warranty.
+#
+# KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
+# INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
+# EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR
+# CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
+# DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+# TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+# PERFORMANCE OF THIS SOFTWARE.
+
+SUBDIRS = src man
+
+AM_CFLAGS = $(XRENDER_CFLAGS) $(XFIXES_CFLAGS) $(X_CFLAGS)
+
+pkgconfigdir = $(libdir)/pkgconfig
+pkgconfig_DATA = xcursor.pc
+
+EXTRA_DIST = $(man_MANS) xcursor.pc.in autogen.sh
diff --git a/NEWS b/NEWS
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/NEWS
diff --git a/README b/README
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/README
diff --git a/autogen.sh b/autogen.sh
new file mode 100755
index 0000000..904cd67
--- /dev/null
+++ b/autogen.sh
@@ -0,0 +1,12 @@
+#! /bin/sh
+
+srcdir=`dirname $0`
+test -z "$srcdir" && srcdir=.
+
+ORIGDIR=`pwd`
+cd $srcdir
+
+autoreconf -v --install || exit 1
+cd $ORIGDIR || exit $?
+
+$srcdir/configure --enable-maintainer-mode "$@"
diff --git a/configure.ac b/configure.ac
new file mode 100644
index 0000000..73116ae
--- /dev/null
+++ b/configure.ac
@@ -0,0 +1,145 @@
+dnl
+dnl $Id$
+dnl
+dnl Copyright © 2003 Keith Packard
+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, and that the name of Keith Packard not be used in
+dnl advertising or publicity pertaining to distribution of the software without
+dnl specific, written prior permission. Keith Packard makes no
+dnl representations about the suitability of this software for any purpose. It
+dnl is provided "as is" without express or implied warranty.
+dnl
+dnl KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
+dnl INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
+dnl EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR
+dnl CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
+dnl DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+dnl TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+dnl PERFORMANCE OF THIS SOFTWARE.
+dnl
+dnl Process this file with autoconf to create configure.
+
+AC_PREREQ([2.57])
+dnl
+dnl This is the package version number, not the shared library
+dnl version. This same version number must appear in Xcursor.h
+dnl Yes, it is a pain to synchronize version numbers. Unfortunately, it's
+dnl not possible to extract the version number here from Xcursor.h
+dnl
+AC_INIT([libXcursor],1.1.3,[keithp@keithp.com],[libXcursor])
+AM_INIT_AUTOMAKE([dist-bzip2])
+AC_CONFIG_SRCDIR([Makefile.am])
+AM_MAINTAINER_MODE
+AM_CONFIG_HEADER(config.h)
+
+dnl libtool versioning
+
+LT_CURRENT=1
+LT_REVISION=2
+LT_AGE=0
+
+AC_SUBST(LT_CURRENT)
+AC_SUBST(LT_REVISION)
+LT_AGE=0
+
+LT_VERSION_INFO="$LT_CURRENT:$LT_REVISION:$LT_AGE"
+AC_SUBST(LT_VERSION_INFO)
+
+LT_CURRENT_MINUS_AGE=`expr $LT_CURRENT - $LT_AGE`
+AC_SUBST(LT_CURRENT_MINUS_AGE)
+
+# Check for progs
+AC_PROG_CC
+AC_PROG_LIBTOOL
+
+# Check for X
+PKG_CHECK_MODULES(X, x11,
+ [x_found_with_pkgconfig=yes],
+ [x_found_with_pkgconfig=no])
+
+if test "$x_found_with_pkgconfig" = "no"
+then
+ AC_PATH_XTRA
+ X_LIBS="$X_LIBS -lX11"
+
+ if test "x$no_x" = "xyes"
+ then
+ AC_MSG_ERROR([X is required, but it was either disabled or not found.])
+ fi
+ # Check for XTHREADS
+
+ save_LIBS="$LIBS"
+ save_CFLAGS="$CFLAGS"
+ CFLAGS="$CFLAGS $X_CFLAGS"
+ LIBS="$LIBS $X_LIBS"
+
+ AC_MSG_CHECKING([for XTHREADS in Xlib])
+ AC_RUN_IFELSE(
+ [AC_LANG_PROGRAM([[#include <X11/Xlib.h>]],
+ [[return XInitThreads() == 0 ? 0 : 1;]])],
+ [xthreads=no],
+ [xthreads=yes],
+ [xthreads=yes])
+
+ AC_MSG_RESULT($xthreads)
+
+ LIBS="$save_LIBS"
+ CFLAGS="$save_CFLAGS"
+
+ if test "x$xthreads" = "xyes"
+ then
+ X_CFLAGS="$X_CFLAGS -DXTHREADS"
+ fi
+
+ if test "x$no_x" = "xyes"
+ then
+ AC_MSG_ERROR([X is required, but it was either disabled or not found.])
+ fi
+fi
+
+AC_SUBST(X_CFLAGS)
+AC_SUBST(X_LIBS)
+
+PKG_CHECK_MODULES(XRENDER, xrender >= 0.8.2, [xrender_found_with_pkgconfig=yes],
+ [xrender_found_with_pkgconfig=no])
+case "$xrender_found_with_pkgconfig" in
+no)
+ PKG_CHECK_MODULES(XRENDER, xrender >= 0.8, [old_xrender_found_with_pkgconfig=yes],
+ [old_xrender_found_with_pkgconfig=no])
+ case "$old_xrender_found_with_pkgconfig" in
+ no)
+ # checks for X
+ AC_PATH_X
+
+ XRENDER_CFLAGS="-I$x_includes"
+ XRENDER_LIBS="-L$x_libraries -lXrender -lXext -lX11"
+
+ saved_CPPFLAGS="$CPPFLAGS"
+ CPPFLAGS="$CPPFLAGS $XRENDER_CFLAGS"
+ AC_CHECK_HEADERS([X11/extensions/Xrender.h], [], [AC_MSG_ERROR([Xrender.h not found.])])
+ CPPFLAGS="$saved_CPPFLAGS"
+
+ saved_LIBS="$LIBS"
+ LIBS="$LIBS $XRENDER_LIBS"
+ AC_CHECK_FUNCS([XRenderCreateAnimCursor], [], [AC_MSG_ERROR([libXrender not found.])])
+ LIBS="$saved_LIBS"
+ ;;
+ yes)
+ XRENDER_LIBS="$XRENDER_LIBS -lXext -lX11"
+ ;;
+ esac
+ ;;
+esac
+PKG_CHECK_MODULES(XFIXES, xfixes, [AC_DEFINE_UNQUOTED(HAVE_XFIXES, 1, [Define to 1 if you have Xfixes])])
+
+AC_SUBST(XRENDER_LIBS)
+AC_SUBST(XRENDER_CFLAGS)
+
+AC_OUTPUT([Makefile
+ src/Makefile
+ man/Makefile
+ xcursor.pc])
diff --git a/man/Makefile.am b/man/Makefile.am
new file mode 100644
index 0000000..94cca7f
--- /dev/null
+++ b/man/Makefile.am
@@ -0,0 +1,3 @@
+man_MANS = Xcursor.3
+
+EXTRA_DIST = $(man_MANS)
diff --git a/src/Makefile.am b/src/Makefile.am
new file mode 100644
index 0000000..c02fd9a
--- /dev/null
+++ b/src/Makefile.am
@@ -0,0 +1,15 @@
+lib_LTLIBRARIES = libXcursor.la
+
+libXcursor_la_SOURCES = xcursorint.h cursor.c display.c file.c library.c xlib.c
+
+libXcursor_la_LIBADD = $(XRENDER_LIBS) $(XFIXES_LIBS) $(X_LIBS)
+
+INCLUDES = -I$(top_srcdir)/include/X11/Xcursor
+
+#
+# Shared library version info. This is not the same as the package version
+#
+libXcursor_la_LDFLAGS = -version-info @LT_VERSION_INFO@ -no-undefined
+
+libXcursorincludedir = $(includedir)/X11/Xcursor
+libXcursorinclude_HEADERS = $(top_srcdir)/include/X11/Xcursor/Xcursor.h
diff --git a/xcursor.pc.in b/xcursor.pc.in
new file mode 100644
index 0000000..c39fce7
--- /dev/null
+++ b/xcursor.pc.in
@@ -0,0 +1,15 @@
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+libdir=@libdir@
+includedir=@includedir@
+xrenderlibs=@XRENDER_LIBS@
+xrendercflags=@XRENDER_CFLAGS@
+xlibs=@X_LIBS@
+xcflags=@X_CFLAGS@
+
+Name: Xcursor
+Description: X Cursor Library
+Version: @VERSION@
+Requires: xrender
+Cflags: -I${includedir} ${xrendercflags} ${xcflags}
+Libs: -L${libdir} -lXcursor ${xrenderlibs} ${xlibs}