diff --git a/libdrm/ChangeLog b/ChangeLog similarity index 100% rename from libdrm/ChangeLog rename to ChangeLog diff --git a/Makefile.am b/Makefile.am index 31b20e95..aa591010 100644 --- a/Makefile.am +++ b/Makefile.am @@ -19,12 +19,43 @@ # CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. AUTOMAKE_OPTIONS = foreign -SUBDIRS = libdrm tests pkgconfigdir = @pkgconfigdir@ pkgconfig_DATA = libdrm.pc -EXTRA_DIST = libdrm.pc.in include/drm/* +if HAVE_INTEL +INTEL_SUBDIR = intel +endif + +if HAVE_NOUVEAU +NOUVEAU_SUBDIR = nouveau +endif + +if HAVE_RADEON +RADEON_SUBDIR = radeon +endif + +SUBDIRS = . $(INTEL_SUBDIR) $(NOUVEAU_SUBDIR) $(RADEON_SUBDIR) tests + +libdrm_la_LTLIBRARIES = libdrm.la +libdrm_ladir = $(libdir) +libdrm_la_LDFLAGS = -version-number 2:4:0 -no-undefined +libdrm_la_LIBADD = @CLOCK_LIB@ + +libdrm_la_CPPFLAGS = -I$(top_srcdir)/include/drm + +libdrm_la_SOURCES = \ + xf86drm.c \ + xf86drmHash.c \ + xf86drmRandom.c \ + xf86drmSL.c \ + xf86drmMode.c \ + libdrm_lists.h + +libdrmincludedir = ${includedir} +libdrminclude_HEADERS = xf86drm.h xf86drmMode.h + +EXTRA_DIST = ChangeLog TODO libdrm.pc.in include/drm/* copy-headers : cp -r $(kernel_source)/usr/include/drm $(top_srcdir)/include diff --git a/libdrm/TODO b/TODO similarity index 100% rename from libdrm/TODO rename to TODO diff --git a/configure.ac b/configure.ac index 971dead3..857fc097 100644 --- a/configure.ac +++ b/configure.ac @@ -24,7 +24,7 @@ AC_USE_SYSTEM_EXTENSIONS AC_CONFIG_SRCDIR([Makefile.am]) AM_INIT_AUTOMAKE([dist-bzip2]) -AM_CONFIG_HEADER([libdrm/config.h]) +AM_CONFIG_HEADER([config.h]) AC_DISABLE_STATIC AC_PROG_LIBTOOL @@ -197,13 +197,12 @@ AC_SUBST(kernel_source) AC_SUBST(WARN_CFLAGS) AC_OUTPUT([ Makefile - libdrm/Makefile - libdrm/intel/Makefile - libdrm/intel/libdrm_intel.pc - libdrm/radeon/Makefile - libdrm/radeon/libdrm_radeon.pc - libdrm/nouveau/Makefile - libdrm/nouveau/libdrm_nouveau.pc + intel/Makefile + intel/libdrm_intel.pc + radeon/Makefile + radeon/libdrm_radeon.pc + nouveau/Makefile + nouveau/libdrm_nouveau.pc tests/Makefile tests/modeprint/Makefile tests/modetest/Makefile diff --git a/libdrm/intel/Makefile.am b/intel/Makefile.am similarity index 96% rename from libdrm/intel/Makefile.am rename to intel/Makefile.am index c3c563e4..8bb2c6e3 100644 --- a/libdrm/intel/Makefile.am +++ b/intel/Makefile.am @@ -24,8 +24,8 @@ AM_CFLAGS = \ $(WARN_CFLAGS) \ - -I$(top_srcdir)/libdrm \ - -I$(top_srcdir)/libdrm/intel \ + -I$(top_srcdir) \ + -I$(top_srcdir)/intel \ $(PTHREADSTUBS_CFLAGS) \ -I$(top_srcdir)/include/drm diff --git a/libdrm/intel/intel_atomic.h b/intel/intel_atomic.h similarity index 100% rename from libdrm/intel/intel_atomic.h rename to intel/intel_atomic.h diff --git a/libdrm/intel/intel_bufmgr.c b/intel/intel_bufmgr.c similarity index 100% rename from libdrm/intel/intel_bufmgr.c rename to intel/intel_bufmgr.c diff --git a/libdrm/intel/intel_bufmgr.h b/intel/intel_bufmgr.h similarity index 100% rename from libdrm/intel/intel_bufmgr.h rename to intel/intel_bufmgr.h diff --git a/libdrm/intel/intel_bufmgr_fake.c b/intel/intel_bufmgr_fake.c similarity index 100% rename from libdrm/intel/intel_bufmgr_fake.c rename to intel/intel_bufmgr_fake.c diff --git a/libdrm/intel/intel_bufmgr_gem.c b/intel/intel_bufmgr_gem.c similarity index 100% rename from libdrm/intel/intel_bufmgr_gem.c rename to intel/intel_bufmgr_gem.c diff --git a/libdrm/intel/intel_bufmgr_priv.h b/intel/intel_bufmgr_priv.h similarity index 100% rename from libdrm/intel/intel_bufmgr_priv.h rename to intel/intel_bufmgr_priv.h diff --git a/libdrm/intel/intel_chipset.h b/intel/intel_chipset.h similarity index 100% rename from libdrm/intel/intel_chipset.h rename to intel/intel_chipset.h diff --git a/libdrm/intel/libdrm_intel.pc.in b/intel/libdrm_intel.pc.in similarity index 100% rename from libdrm/intel/libdrm_intel.pc.in rename to intel/libdrm_intel.pc.in diff --git a/libdrm/intel/mm.c b/intel/mm.c similarity index 100% rename from libdrm/intel/mm.c rename to intel/mm.c diff --git a/libdrm/intel/mm.h b/intel/mm.h similarity index 100% rename from libdrm/intel/mm.h rename to intel/mm.h diff --git a/libdrm/Makefile.am b/libdrm/Makefile.am deleted file mode 100644 index 10de8e3d..00000000 --- a/libdrm/Makefile.am +++ /dev/null @@ -1,47 +0,0 @@ -# Copyright 2005 Adam Jackson. -# -# 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 -# on the rights to use, copy, modify, merge, publish, distribute, sub -# license, 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 NON-INFRINGEMENT. IN NO EVENT SHALL -# ADAM JACKSON 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. - -if HAVE_INTEL -INTEL_SUBDIR = intel -endif - -if HAVE_NOUVEAU -NOUVEAU_SUBDIR = nouveau -endif - -if HAVE_RADEON -RADEON_SUBDIR = radeon -endif - -SUBDIRS = . $(INTEL_SUBDIR) $(NOUVEAU_SUBDIR) $(RADEON_SUBDIR) - -libdrm_la_LTLIBRARIES = libdrm.la -libdrm_ladir = $(libdir) -libdrm_la_LDFLAGS = -version-number 2:4:0 -no-undefined -libdrm_la_LIBADD = @CLOCK_LIB@ - -AM_CFLAGS = -I$(top_srcdir)/include/drm -libdrm_la_SOURCES = xf86drm.c xf86drmHash.c xf86drmRandom.c xf86drmSL.c \ - xf86drmMode.c libdrm_lists.h - -libdrmincludedir = ${includedir} -libdrminclude_HEADERS = xf86drm.h xf86drmMode.h - -EXTRA_DIST = ChangeLog TODO diff --git a/libdrm/libdrm_lists.h b/libdrm_lists.h similarity index 100% rename from libdrm/libdrm_lists.h rename to libdrm_lists.h diff --git a/libdrm/nouveau/Makefile.am b/nouveau/Makefile.am similarity index 94% rename from libdrm/nouveau/Makefile.am rename to nouveau/Makefile.am index db6243cc..70bbbb27 100644 --- a/libdrm/nouveau/Makefile.am +++ b/nouveau/Makefile.am @@ -1,7 +1,7 @@ AM_CFLAGS = \ $(WARN_CFLAGS) \ - -I$(top_srcdir)/libdrm \ - -I$(top_srcdir)/libdrm/nouveau \ + -I$(top_srcdir) \ + -I$(top_srcdir)/nouveau \ $(PTHREADSTUBS_CFLAGS) \ -I$(top_srcdir)/include/drm @@ -31,6 +31,7 @@ libdrm_nouveaucommoninclude_HEADERS = \ nouveau_resource.h \ nouveau_class.h + libdrm_nouveauincludedir = ${includedir}/drm libdrm_nouveauinclude_HEADERS = \ nouveau_drmif.h diff --git a/libdrm/nouveau/libdrm_nouveau.pc.in b/nouveau/libdrm_nouveau.pc.in similarity index 100% rename from libdrm/nouveau/libdrm_nouveau.pc.in rename to nouveau/libdrm_nouveau.pc.in diff --git a/libdrm/nouveau/nouveau_bo.c b/nouveau/nouveau_bo.c similarity index 100% rename from libdrm/nouveau/nouveau_bo.c rename to nouveau/nouveau_bo.c diff --git a/libdrm/nouveau/nouveau_bo.h b/nouveau/nouveau_bo.h similarity index 100% rename from libdrm/nouveau/nouveau_bo.h rename to nouveau/nouveau_bo.h diff --git a/libdrm/nouveau/nouveau_channel.c b/nouveau/nouveau_channel.c similarity index 100% rename from libdrm/nouveau/nouveau_channel.c rename to nouveau/nouveau_channel.c diff --git a/libdrm/nouveau/nouveau_channel.h b/nouveau/nouveau_channel.h similarity index 100% rename from libdrm/nouveau/nouveau_channel.h rename to nouveau/nouveau_channel.h diff --git a/libdrm/nouveau/nouveau_class.h b/nouveau/nouveau_class.h similarity index 100% rename from libdrm/nouveau/nouveau_class.h rename to nouveau/nouveau_class.h diff --git a/libdrm/nouveau/nouveau_device.c b/nouveau/nouveau_device.c similarity index 100% rename from libdrm/nouveau/nouveau_device.c rename to nouveau/nouveau_device.c diff --git a/libdrm/nouveau/nouveau_device.h b/nouveau/nouveau_device.h similarity index 100% rename from libdrm/nouveau/nouveau_device.h rename to nouveau/nouveau_device.h diff --git a/libdrm/nouveau/nouveau_drmif.h b/nouveau/nouveau_drmif.h similarity index 100% rename from libdrm/nouveau/nouveau_drmif.h rename to nouveau/nouveau_drmif.h diff --git a/libdrm/nouveau/nouveau_grobj.c b/nouveau/nouveau_grobj.c similarity index 100% rename from libdrm/nouveau/nouveau_grobj.c rename to nouveau/nouveau_grobj.c diff --git a/libdrm/nouveau/nouveau_grobj.h b/nouveau/nouveau_grobj.h similarity index 100% rename from libdrm/nouveau/nouveau_grobj.h rename to nouveau/nouveau_grobj.h diff --git a/libdrm/nouveau/nouveau_notifier.c b/nouveau/nouveau_notifier.c similarity index 100% rename from libdrm/nouveau/nouveau_notifier.c rename to nouveau/nouveau_notifier.c diff --git a/libdrm/nouveau/nouveau_notifier.h b/nouveau/nouveau_notifier.h similarity index 100% rename from libdrm/nouveau/nouveau_notifier.h rename to nouveau/nouveau_notifier.h diff --git a/libdrm/nouveau/nouveau_private.h b/nouveau/nouveau_private.h similarity index 100% rename from libdrm/nouveau/nouveau_private.h rename to nouveau/nouveau_private.h diff --git a/libdrm/nouveau/nouveau_pushbuf.c b/nouveau/nouveau_pushbuf.c similarity index 100% rename from libdrm/nouveau/nouveau_pushbuf.c rename to nouveau/nouveau_pushbuf.c diff --git a/libdrm/nouveau/nouveau_pushbuf.h b/nouveau/nouveau_pushbuf.h similarity index 100% rename from libdrm/nouveau/nouveau_pushbuf.h rename to nouveau/nouveau_pushbuf.h diff --git a/libdrm/nouveau/nouveau_resource.c b/nouveau/nouveau_resource.c similarity index 100% rename from libdrm/nouveau/nouveau_resource.c rename to nouveau/nouveau_resource.c diff --git a/libdrm/nouveau/nouveau_resource.h b/nouveau/nouveau_resource.h similarity index 100% rename from libdrm/nouveau/nouveau_resource.h rename to nouveau/nouveau_resource.h diff --git a/libdrm/radeon/Makefile.am b/radeon/Makefile.am similarity index 96% rename from libdrm/radeon/Makefile.am rename to radeon/Makefile.am index 97801ead..dd136b1f 100644 --- a/libdrm/radeon/Makefile.am +++ b/radeon/Makefile.am @@ -24,8 +24,8 @@ AM_CFLAGS = \ $(WARN_CFLAGS) \ - -I$(top_srcdir)/libdrm \ - -I$(top_srcdir)/libdrm/radeon \ + -I$(top_srcdir) \ + -I$(top_srcdir)/radeon \ $(PTHREADSTUBS_CFLAGS) \ -I$(top_srcdir)/include/drm diff --git a/libdrm/radeon/libdrm_radeon.pc.in b/radeon/libdrm_radeon.pc.in similarity index 100% rename from libdrm/radeon/libdrm_radeon.pc.in rename to radeon/libdrm_radeon.pc.in diff --git a/libdrm/radeon/radeon_bo.h b/radeon/radeon_bo.h similarity index 100% rename from libdrm/radeon/radeon_bo.h rename to radeon/radeon_bo.h diff --git a/libdrm/radeon/radeon_bo_gem.c b/radeon/radeon_bo_gem.c similarity index 100% rename from libdrm/radeon/radeon_bo_gem.c rename to radeon/radeon_bo_gem.c diff --git a/libdrm/radeon/radeon_bo_gem.h b/radeon/radeon_bo_gem.h similarity index 100% rename from libdrm/radeon/radeon_bo_gem.h rename to radeon/radeon_bo_gem.h diff --git a/libdrm/radeon/radeon_cs.h b/radeon/radeon_cs.h similarity index 100% rename from libdrm/radeon/radeon_cs.h rename to radeon/radeon_cs.h diff --git a/libdrm/radeon/radeon_cs_gem.c b/radeon/radeon_cs_gem.c similarity index 100% rename from libdrm/radeon/radeon_cs_gem.c rename to radeon/radeon_cs_gem.c diff --git a/libdrm/radeon/radeon_cs_gem.h b/radeon/radeon_cs_gem.h similarity index 100% rename from libdrm/radeon/radeon_cs_gem.h rename to radeon/radeon_cs_gem.h diff --git a/libdrm/radeon/radeon_cs_space.c b/radeon/radeon_cs_space.c similarity index 100% rename from libdrm/radeon/radeon_cs_space.c rename to radeon/radeon_cs_space.c diff --git a/libdrm/radeon/radeon_track.c b/radeon/radeon_track.c similarity index 100% rename from libdrm/radeon/radeon_track.c rename to radeon/radeon_track.c diff --git a/libdrm/radeon/radeon_track.h b/radeon/radeon_track.h similarity index 100% rename from libdrm/radeon/radeon_track.h rename to radeon/radeon_track.h diff --git a/tests/Makefile.am b/tests/Makefile.am index 551589f8..d044474d 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -2,9 +2,9 @@ NULL:=# AM_CPPFLAGS = \ -I $(top_srcdir)/include/drm \ - -I $(top_srcdir)/libdrm + -I $(top_srcdir) -LDADD = $(top_builddir)/libdrm/libdrm.la +LDADD = $(top_builddir)/libdrm.la noinst_PROGRAMS = \ dristat \ @@ -24,7 +24,7 @@ libdrmtest_la_SOURCES = \ drmtest.h libdrmtest_la_LIBADD = \ - $(top_builddir)/libdrm/libdrm.la \ + $(top_builddir)/libdrm.la \ $(LIBUDEV_LIBS) LDADD += libdrmtest.la diff --git a/tests/modeprint/Makefile.am b/tests/modeprint/Makefile.am index 64f2f603..2ae0fdc6 100644 --- a/tests/modeprint/Makefile.am +++ b/tests/modeprint/Makefile.am @@ -1,7 +1,7 @@ AM_CFLAGS = \ -I$(top_srcdir)/include/drm \ - -I$(top_srcdir)/libdrm/intel/ \ - -I$(top_srcdir)/libdrm + -I$(top_srcdir)/intel/ \ + -I$(top_srcdir) noinst_PROGRAMS = \ modeprint @@ -9,5 +9,5 @@ noinst_PROGRAMS = \ modeprint_SOURCES = \ modeprint.c modeprint_LDADD = \ - $(top_builddir)/libdrm/libdrm.la \ - $(top_builddir)/libdrm/intel/libdrm_intel.la + $(top_builddir)/libdrm.la \ + $(top_builddir)/intel/libdrm_intel.la diff --git a/tests/modetest/Makefile.am b/tests/modetest/Makefile.am index 0fd59f1d..16f5e995 100644 --- a/tests/modetest/Makefile.am +++ b/tests/modetest/Makefile.am @@ -1,7 +1,7 @@ AM_CFLAGS = \ -I$(top_srcdir)/include/drm \ - -I$(top_srcdir)/libdrm/intel/ \ - -I$(top_srcdir)/libdrm \ + -I$(top_srcdir)/intel/ \ + -I$(top_srcdir) \ $(CAIRO_CFLAGS) noinst_PROGRAMS = \ @@ -10,6 +10,6 @@ noinst_PROGRAMS = \ modetest_SOURCES = \ modetest.c modetest_LDADD = \ - $(top_builddir)/libdrm/libdrm.la \ - $(top_builddir)/libdrm/intel/libdrm_intel.la \ + $(top_builddir)/libdrm.la \ + $(top_builddir)/intel/libdrm_intel.la \ $(CAIRO_LIBS) diff --git a/libdrm/xf86drm.c b/xf86drm.c similarity index 100% rename from libdrm/xf86drm.c rename to xf86drm.c diff --git a/libdrm/xf86drm.h b/xf86drm.h similarity index 100% rename from libdrm/xf86drm.h rename to xf86drm.h diff --git a/libdrm/xf86drmHash.c b/xf86drmHash.c similarity index 100% rename from libdrm/xf86drmHash.c rename to xf86drmHash.c diff --git a/libdrm/xf86drmMode.c b/xf86drmMode.c similarity index 100% rename from libdrm/xf86drmMode.c rename to xf86drmMode.c diff --git a/libdrm/xf86drmMode.h b/xf86drmMode.h similarity index 100% rename from libdrm/xf86drmMode.h rename to xf86drmMode.h diff --git a/libdrm/xf86drmRandom.c b/xf86drmRandom.c similarity index 100% rename from libdrm/xf86drmRandom.c rename to xf86drmRandom.c diff --git a/libdrm/xf86drmSL.c b/xf86drmSL.c similarity index 100% rename from libdrm/xf86drmSL.c rename to xf86drmSL.c diff --git a/libdrm/xf86mm.h b/xf86mm.h similarity index 100% rename from libdrm/xf86mm.h rename to xf86mm.h