diff options
author | Adam Jackson | 2005-07-10 17:42:42 -0500 |
---|---|---|
committer | Adam Jackson | 2005-07-10 17:42:42 -0500 |
commit | 07d23f9c60f9358f064eab7d944f3b28484b51ef (patch) | |
tree | 9687b5ed89314ad30a1939c6462ab5d6df0d4303 | |
parent | 04fea060023a539c6c6766ec184b59f32c97d474 (diff) | |
download | external-libdrm-07d23f9c60f9358f064eab7d944f3b28484b51ef.tar.gz external-libdrm-07d23f9c60f9358f064eab7d944f3b28484b51ef.tar.xz external-libdrm-07d23f9c60f9358f064eab7d944f3b28484b51ef.zip |
autoconfiscate libdrm
-rw-r--r-- | Makefile.am | 30 | ||||
-rw-r--r-- | README | 4 | ||||
-rw-r--r-- | configure.ac | 46 | ||||
-rw-r--r-- | libdrm.pc.in | 8 | ||||
-rw-r--r-- | libdrm/Makefile | 55 | ||||
-rw-r--r-- | libdrm/Makefile.am | 58 |
6 files changed, 146 insertions, 55 deletions
diff --git a/Makefile.am b/Makefile.am new file mode 100644 index 00000000..6cbd52a9 --- /dev/null +++ b/Makefile.am | |||
@@ -0,0 +1,30 @@ | |||
1 | # Copyright 2005 Adam Jackson. | ||
2 | # | ||
3 | # Permission is hereby granted, free of charge, to any person obtaining a | ||
4 | # copy of this software and associated documentation files (the "Software"), | ||
5 | # to deal in the Software without restriction, including without limitation | ||
6 | # on the rights to use, copy, modify, merge, publish, distribute, sub | ||
7 | # license, and/or sell copies of the Software, and to permit persons to whom | ||
8 | # the Software is furnished to do so, subject to the following conditions: | ||
9 | # | ||
10 | # The above copyright notice and this permission notice (including the next | ||
11 | # paragraph) shall be included in all copies or substantial portions of the | ||
12 | # Software. | ||
13 | # | ||
14 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
15 | # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
16 | # FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL | ||
17 | # ADAM JACKSON BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER | ||
18 | # IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN | ||
19 | # CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||
20 | |||
21 | # eventually someone might want to build the kernel modules or tests from | ||
22 | # here too, but let's just do libdrm for now | ||
23 | |||
24 | AUTOMAKE_OPTIONS = foreign | ||
25 | SUBDIRS = libdrm | ||
26 | |||
27 | pkgconfigdir = @pkgconfigdir@ | ||
28 | pkgconfig_DATA = libdrm.pc | ||
29 | |||
30 | EXTRA_DIST = libdrm.pc.in | ||
@@ -0,0 +1,4 @@ | |||
1 | By default, this will install into /usr/local. If you want to install this | ||
2 | libdrm to replace your system copy, say: | ||
3 | |||
4 | ./autogen.sh --enable-system | ||
diff --git a/configure.ac b/configure.ac new file mode 100644 index 00000000..4fb505df --- /dev/null +++ b/configure.ac | |||
@@ -0,0 +1,46 @@ | |||
1 | # Copyright 2005 Adam Jackson. | ||
2 | # | ||
3 | # Permission is hereby granted, free of charge, to any person obtaining a | ||
4 | # copy of this software and associated documentation files (the "Software"), | ||
5 | # to deal in the Software without restriction, including without limitation | ||
6 | # on the rights to use, copy, modify, merge, publish, distribute, sub | ||
7 | # license, and/or sell copies of the Software, and to permit persons to whom | ||
8 | # the Software is furnished to do so, subject to the following conditions: | ||
9 | # | ||
10 | # The above copyright notice and this permission notice (including the next | ||
11 | # paragraph) shall be included in all copies or substantial portions of the | ||
12 | # Software. | ||
13 | # | ||
14 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
15 | # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
16 | # FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL | ||
17 | # ADAM JACKSON BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER | ||
18 | # IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN | ||
19 | # CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||
20 | |||
21 | AC_PREREQ(2.57) | ||
22 | AC_INIT([libdrm], 1.0.0, [dri-devel@lists.sourceforge.net], libdrm) | ||
23 | AC_CONFIG_SRCDIR([Makefile.am]) | ||
24 | AM_INIT_AUTOMAKE([dist-bzip2]) | ||
25 | |||
26 | AM_CONFIG_HEADER([libdrm/config.h]) | ||
27 | |||
28 | AC_PROG_LIBTOOL | ||
29 | AC_PROG_CC | ||
30 | |||
31 | AC_HEADER_STDC | ||
32 | |||
33 | AC_ARG_ENABLE(system, AC_HELP_STRING([--enable-system], | ||
34 | [Configure to be the system libdrm]), | ||
35 | [SYSTEM=$enableval], [SYSTEM=no]) | ||
36 | AM_CONDITIONAL(SYSTEM, [test x$SYSTEM = xyes]) | ||
37 | if test x$SYSTEM = xyes; then | ||
38 | libdir=/lib | ||
39 | includedir=/usr/include | ||
40 | pkgconfigdir=/usr/lib/pkgconfig | ||
41 | else | ||
42 | pkgconfigdir=${libdir}/pkgconfig | ||
43 | fi | ||
44 | AC_SUBST(pkgconfigdir) | ||
45 | |||
46 | AC_OUTPUT([Makefile libdrm/Makefile libdrm.pc]) | ||
diff --git a/libdrm.pc.in b/libdrm.pc.in new file mode 100644 index 00000000..f8764c46 --- /dev/null +++ b/libdrm.pc.in | |||
@@ -0,0 +1,8 @@ | |||
1 | libdir=@libdir@ | ||
2 | includedir=@includedir@ | ||
3 | |||
4 | Name: libdrm | ||
5 | Description: Userspace interface to kernel DRM services | ||
6 | Version: @PACKAGE_VERSION@ | ||
7 | Libs: -L${libdir} | ||
8 | Cflags: -I${includedir} -I${includedir}/drm | ||
diff --git a/libdrm/Makefile b/libdrm/Makefile deleted file mode 100644 index 098f31a1..00000000 --- a/libdrm/Makefile +++ /dev/null | |||
@@ -1,55 +0,0 @@ | |||
1 | SOURCES = xf86drm.c xf86drmHash.c xf86drmRandom.c xf86drmSL.c | ||
2 | OBJECTS = xf86drm.o xf86drmHash.o xf86drmRandom.o xf86drmSL.o | ||
3 | |||
4 | CFLAGS ?= -O2 -fPIC -g | ||
5 | DEFINES = -D_IN_LIBDRM | ||
6 | |||
7 | # set this if you're installing into a fake root | ||
8 | DESTDIR ?= | ||
9 | |||
10 | DRIVER_HEADERS = ../shared-core/drm.h \ | ||
11 | ../shared-core/drm_sarea.h \ | ||
12 | ../shared-core/i915_drm.h \ | ||
13 | ../shared-core/i915_drv.h \ | ||
14 | ../shared-core/mach64_drm.h \ | ||
15 | ../shared-core/mach64_drv.h \ | ||
16 | ../shared-core/mga_drm.h \ | ||
17 | ../shared-core/mga_drv.h \ | ||
18 | ../shared-core/mga_ucode.h \ | ||
19 | ../shared-core/r128_drm.h \ | ||
20 | ../shared-core/r128_drv.h \ | ||
21 | ../shared-core/radeon_drm.h \ | ||
22 | ../shared-core/radeon_drv.h \ | ||
23 | ../shared-core/savage_drm.h \ | ||
24 | ../shared-core/savage_drv.h \ | ||
25 | ../shared-core/sis_drm.h \ | ||
26 | ../shared-core/sis_drv.h \ | ||
27 | ../shared-core/sis_ds.h \ | ||
28 | ../shared-core/tdfx_drv.h \ | ||
29 | ../shared-core/via_3d_reg.h \ | ||
30 | ../shared-core/via_drm.h \ | ||
31 | ../shared-core/via_drv.h \ | ||
32 | ../shared-core/via_ds.h \ | ||
33 | ../shared-core/via_mm.h \ | ||
34 | ../shared-core/via_verifier.h | ||
35 | |||
36 | all: libdrm.so | ||
37 | |||
38 | libdrm.so: $(OBJECTS) | ||
39 | $(CC) -shared -Wl,-hlibdrm.so.1 -o $@ $^ | ||
40 | |||
41 | .c.o: | ||
42 | $(CC) $(DEFINES) $(CFLAGS) -c -I../shared-core $< | ||
43 | |||
44 | clean: | ||
45 | rm -f *.a *.o *.so | ||
46 | |||
47 | # XXX remove the xf86drm.h compat once this is widely installed | ||
48 | install: libdrm.so xf86drm.h $(DRIVER_HEADERS) | ||
49 | install -m 755 libdrm.so $(DESTDIR)/lib | ||
50 | install -m 644 xf86drm.h $(DESTDIR)/usr/include/libdrm.h | ||
51 | install -m 644 xf86drm.h $(DESTDIR)/usr/include/xf86drm.h | ||
52 | echo '#warning Including xf86drm.h is deprecated, use libdrm.h' >> \ | ||
53 | $(DESTDIR)/usr/include/xf86drm.h | ||
54 | mkdir -p -m 755 $(DESTDIR)/usr/include/drm | ||
55 | install -m 644 $(DRIVER_HEADERS) $(DESTDIR)/usr/include/drm | ||
diff --git a/libdrm/Makefile.am b/libdrm/Makefile.am new file mode 100644 index 00000000..f5fa69b2 --- /dev/null +++ b/libdrm/Makefile.am | |||
@@ -0,0 +1,58 @@ | |||
1 | # Copyright 2005 Adam Jackson. | ||
2 | # | ||
3 | # Permission is hereby granted, free of charge, to any person obtaining a | ||
4 | # copy of this software and associated documentation files (the "Software"), | ||
5 | # to deal in the Software without restriction, including without limitation | ||
6 | # on the rights to use, copy, modify, merge, publish, distribute, sub | ||
7 | # license, and/or sell copies of the Software, and to permit persons to whom | ||
8 | # the Software is furnished to do so, subject to the following conditions: | ||
9 | # | ||
10 | # The above copyright notice and this permission notice (including the next | ||
11 | # paragraph) shall be included in all copies or substantial portions of the | ||
12 | # Software. | ||
13 | # | ||
14 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
15 | # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
16 | # FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL | ||
17 | # ADAM JACKSON BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER | ||
18 | # IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN | ||
19 | # CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||
20 | |||
21 | libdrm_la_LTLIBRARIES = libdrm.la | ||
22 | libdrm_ladir = /lib | ||
23 | libdrm_la_LDFLAGS = -version-number 1:0:0 -no-undefined | ||
24 | |||
25 | AM_CFLAGS = -I$(top_srcdir)/shared-core | ||
26 | libdrm_la_SOURCES = xf86drm.c xf86drmHash.c xf86drmRandom.c xf86drmSL.c | ||
27 | |||
28 | libdrmincludedir = ${includedir} | ||
29 | libdrminclude_HEADERS = xf86drm.h | ||
30 | |||
31 | klibdrmincludedir = ${includedir}/drm | ||
32 | klibdrminclude_HEADERS = \ | ||
33 | ../shared-core/drm.h \ | ||
34 | ../shared-core/drm_sarea.h \ | ||
35 | ../shared-core/i915_drm.h \ | ||
36 | ../shared-core/i915_drv.h \ | ||
37 | ../shared-core/imagine_drv.h \ | ||
38 | ../shared-core/mach64_drm.h \ | ||
39 | ../shared-core/mach64_drv.h \ | ||
40 | ../shared-core/mga_drm.h \ | ||
41 | ../shared-core/mga_drv.h \ | ||
42 | ../shared-core/mga_ucode.h \ | ||
43 | ../shared-core/r128_drm.h \ | ||
44 | ../shared-core/r128_drv.h \ | ||
45 | ../shared-core/radeon_drm.h \ | ||
46 | ../shared-core/radeon_drv.h \ | ||
47 | ../shared-core/savage_drm.h \ | ||
48 | ../shared-core/savage_drv.h \ | ||
49 | ../shared-core/sis_drm.h \ | ||
50 | ../shared-core/sis_drv.h \ | ||
51 | ../shared-core/sis_ds.h \ | ||
52 | ../shared-core/tdfx_drv.h \ | ||
53 | ../shared-core/via_3d_reg.h \ | ||
54 | ../shared-core/via_drm.h \ | ||
55 | ../shared-core/via_drv.h \ | ||
56 | ../shared-core/via_ds.h \ | ||
57 | ../shared-core/via_mm.h \ | ||
58 | ../shared-core/via_verifier.h | ||