summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAbdoulaye Walsimou Gaye <awg@embtoolkit.com>2010-06-20 23:42:25 +0200
committerAbdoulaye Walsimou Gaye <awg@embtoolkit.com>2010-06-20 23:42:25 +0200
commit0c1443f1a5e49297f397aef489032fbbf720a88a (patch)
tree25e7eb6ed17aa0ca41a19afdfb4cd507273c09cc
parent50c6a3d5fa0c63379aeaa863e669a6f6e94942f5 (diff)
downloadembtoolkit-0c1443f1a5e49297f397aef489032fbbf720a88a.tar.gz
embtoolkit-0c1443f1a5e49297f397aef489032fbbf720a88a.tar.bz2
embtoolkit-0c1443f1a5e49297f397aef489032fbbf720a88a.tar.xz
Packages: X11: New libXrandr-1.3.0
Signed-off-by: Abdoulaye Walsimou Gaye <awg@embtoolkit.com>
-rw-r--r--packages/x11/libxrandr/libxrandr.kconfig45
-rw-r--r--packages/x11/libxrandr/libxrandr.mk94
-rw-r--r--packages/x11/x11.kconfig1
-rw-r--r--packages/x11/x11.mk5
4 files changed, 145 insertions, 0 deletions
diff --git a/packages/x11/libxrandr/libxrandr.kconfig b/packages/x11/libxrandr/libxrandr.kconfig
new file mode 100644
index 0000000..3081e5a
--- /dev/null
+++ b/packages/x11/libxrandr/libxrandr.kconfig
@@ -0,0 +1,45 @@
+################################################################################
+# Abdoulaye Walsimou GAYE <awg@embtoolkit.org>
+# Copyright(C) 2010 Abdoulaye Walsimou GAYE. All rights reserved.
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+#
+################################################################################
+#
+# \file libxrandr.kconfig
+# \brief libxrandr.kconfig of Embtoolkit
+# \author Abdoulaye Walsimou GAYE <awg@embtoolkit.org>
+# \date June 2010
+################################################################################
+
+config EMBTK_HAVE_LIBXRANDR
+ bool "Have libXrandr"
+ select EMBTK_HAVE_XPROTO
+ select EMBTK_HAVE_RANDRPROTO
+ help
+ libXrandr for X windowing system
+choice
+ prompt "libxrandr version you wish"
+ depends on EMBTK_HAVE_LIBXRANDR
+ help
+ Here you can choose which version of libXrandr you want to use.
+
+ config EMBTK_LIBXRANDR_VERSION_1_3_0
+ bool "libXrandr-1.3.0"
+endchoice
+
+config EMBTK_LIBXRANDR_VERSION_STRING
+ string
+ default "1.3.0" if EMBTK_LIBXRANDR_VERSION_1_3_0
+
diff --git a/packages/x11/libxrandr/libxrandr.mk b/packages/x11/libxrandr/libxrandr.mk
new file mode 100644
index 0000000..0bf0f86
--- /dev/null
+++ b/packages/x11/libxrandr/libxrandr.mk
@@ -0,0 +1,94 @@
+################################################################################
+# Abdoulaye Walsimou GAYE <awg@embtoolkit.org>
+# Copyright(C) 2010 Abdoulaye Walsimou GAYE. All rights reserved.
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+#
+################################################################################
+#
+# \file libxrandr.mk
+# \brief libxrandr.mk of Embtoolkit
+# \author Abdoulaye Walsimou GAYE <awg@embtoolkit.org>
+# \date June 2010
+################################################################################
+
+LIBXRANDR_VERSION := $(subst ",,$(strip $(CONFIG_EMBTK_LIBXRANDR_VERSION_STRING)))
+LIBXRANDR_SITE := http://xorg.freedesktop.org/archive/individual/lib
+LIBXRANDR_PACKAGE := libXrandr-$(LIBXRANDR_VERSION).tar.bz2
+LIBXRANDR_BUILD_DIR := $(PACKAGES_BUILD)/libXrandr-$(LIBXRANDR_VERSION)
+
+LIBXRANDR_BINS =
+LIBXRANDR_SBINS =
+LIBXRANDR_INCLUDES = X11/extensions/Xrandr.h
+LIBXRANDR_LIBS = libXrandr.*
+LIBXRANDR_PKGCONFIGS = xrandr.pc
+
+LIBXRANDR_DEPS = xproto_install randrproto_install
+
+libxrandr_install: $(LIBXRANDR_BUILD_DIR)/.installed
+
+$(LIBXRANDR_BUILD_DIR)/.installed: $(LIBXRANDR_DEPS) download_libxrandr \
+ $(LIBXRANDR_BUILD_DIR)/.decompressed $(LIBXRANDR_BUILD_DIR)/.configured
+ $(call EMBTK_GENERIC_MESSAGE,"Compiling and installing \
+ libxrandr-$(LIBXRANDR_VERSION) in your root filesystem...")
+ $(call EMBTK_KILL_LT_RPATH,$(LIBXRANDR_BUILD_DIR))
+ $(Q)$(MAKE) -C $(LIBXRANDR_BUILD_DIR) $(J)
+ $(Q)$(MAKE) -C $(LIBXRANDR_BUILD_DIR) DESTDIR=$(SYSROOT) install
+ $(Q)$(MAKE) libtool_files_adapt
+ $(Q)$(MAKE) pkgconfig_files_adapt
+ @touch $@
+
+download_libxrandr:
+ $(call EMBTK_GENERIC_MESSAGE,"Downloading $(LIBXRANDR_PACKAGE) \
+ if necessary...")
+ @test -e $(DOWNLOAD_DIR)/$(LIBXRANDR_PACKAGE) || \
+ wget -O $(DOWNLOAD_DIR)/$(LIBXRANDR_PACKAGE) \
+ $(LIBXRANDR_SITE)/$(LIBXRANDR_PACKAGE)
+
+$(LIBXRANDR_BUILD_DIR)/.decompressed:
+ $(call EMBTK_GENERIC_MESSAGE,"Decompressing $(LIBXRANDR_PACKAGE) ...")
+ @tar -C $(PACKAGES_BUILD) -xjf $(DOWNLOAD_DIR)/$(LIBXRANDR_PACKAGE)
+ @touch $@
+
+$(LIBXRANDR_BUILD_DIR)/.configured:
+ $(Q)cd $(LIBXRANDR_BUILD_DIR); \
+ CC=$(TARGETCC_CACHED) \
+ CXX=$(TARGETCXX_CACHED) \
+ AR=$(TARGETAR) \
+ RANLIB=$(TARGETRANLIB) \
+ AS=$(CROSS_COMPILE)as \
+ LD=$(TARGETLD) \
+ NM=$(TARGETNM) \
+ STRIP=$(TARGETSTRIP) \
+ OBJDUMP=$(TARGETOBJDUMP) \
+ OBJCOPY=$(TARGETOBJCOPY) \
+ CFLAGS="$(TARGET_CFLAGS)" \
+ CXXFLAGS="$(TARGET_CFLAGS)" \
+ LDFLAGS="-L$(SYSROOT)/$(LIBDIR) -L$(SYSROOT)/usr/$(LIBDIR)" \
+ CPPFLGAS="-I$(SYSROOT)/usr/include" \
+ PKG_CONFIG=$(PKGCONFIG_BIN) \
+ PKG_CONFIG_PATH=$(PKG_CONFIG_PATH) \
+ ./configure --build=$(HOST_BUILD) --host=$(STRICT_GNU_TARGET) \
+ --target=$(STRICT_GNU_TARGET) --libdir=/usr/$(LIBDIR) --prefix=/usr \
+ --disable-malloc0returnsnull
+ @touch $@
+
+libxrandr_clean:
+ $(call EMBTK_GENERIC_MESSAGE,"cleanup libxrandr-$(LIBXRANDR_VERSION)...")
+ $(Q)-cd $(SYSROOT)/usr/bin; rm -rf $(LIBXRANDR_BINS)
+ $(Q)-cd $(SYSROOT)/usr/sbin; rm -rf $(LIBXRANDR_SBINS)
+ $(Q)-cd $(SYSROOT)/usr/include; rm -rf $(LIBXRANDR_INCLUDES)
+ $(Q)-cd $(SYSROOT)/usr/$(LIBDIR); rm -rf $(LIBXRANDR_LIBS)
+ $(Q)-cd $(SYSROOT)/usr/$(LIBDIR)/pkgconfig; rm -rf $(LIBXRANDR_PKGCONFIGS)
+
diff --git a/packages/x11/x11.kconfig b/packages/x11/x11.kconfig
index 3d9933d..b09da6e 100644
--- a/packages/x11/x11.kconfig
+++ b/packages/x11/x11.kconfig
@@ -60,6 +60,7 @@ source packages/x11/libxinerama/libxinerama.kconfig
source packages/x11/libxfont/libxfont.kconfig
source packages/x11/libxft/libxft.kconfig
source packages/x11/libxkbfile/libxkbfile.kconfig
+source packages/x11/libxrandr/libxrandr.kconfig
source packages/x11/libxrender/libxrender.kconfig
endmenu
diff --git a/packages/x11/x11.mk b/packages/x11/x11.mk
index 9e25b07..6d68b1e 100644
--- a/packages/x11/x11.mk
+++ b/packages/x11/x11.mk
@@ -176,6 +176,11 @@ include $(EMBTK_ROOT)/packages/x11/libxkbfile/libxkbfile.mk
ROOTFS_COMPONENTS_CLEAN += libxkbfile_clean
ROOTFS_COMPONENTS-$(CONFIG_EMBTK_HAVE_LIBXKBFILE) += libxkbfile_install
+#libxrandr
+include $(EMBTK_ROOT)/packages/x11/libxrandr/libxrandr.mk
+ROOTFS_COMPONENTS_CLEAN += libxrandr_clean
+ROOTFS_COMPONENTS-$(CONFIG_EMBTK_HAVE_LIBXRANDR) += libxrandr_install
+
#libxrender
include $(EMBTK_ROOT)/packages/x11/libxrender/libxrender.mk
ROOTFS_COMPONENTS_CLEAN += libxrender_clean