From 45a45e439370712417511960e02940794eabe771 Mon Sep 17 00:00:00 2001 From: Abdoulaye Walsimou Gaye Date: Sat, 18 Sep 2010 12:53:53 +0200 Subject: Packages: NEW X11 packages: add libXi-1.3 and xinput-1.5.2 Signed-off-by: Abdoulaye Walsimou Gaye --- packages/x11/libxi/libxi.kconfig | 52 ++++++++++++++++++ packages/x11/libxi/libxi.mk | 108 +++++++++++++++++++++++++++++++++++++ packages/x11/x11.kconfig | 2 + packages/x11/x11.mk | 8 +++ packages/x11/xinput/xinput.kconfig | 52 ++++++++++++++++++ packages/x11/xinput/xinput.mk | 108 +++++++++++++++++++++++++++++++++++++ 6 files changed, 330 insertions(+) create mode 100644 packages/x11/libxi/libxi.kconfig create mode 100644 packages/x11/libxi/libxi.mk create mode 100644 packages/x11/xinput/xinput.kconfig create mode 100644 packages/x11/xinput/xinput.mk (limited to 'packages') diff --git a/packages/x11/libxi/libxi.kconfig b/packages/x11/libxi/libxi.kconfig new file mode 100644 index 0000000..18a241f --- /dev/null +++ b/packages/x11/libxi/libxi.kconfig @@ -0,0 +1,52 @@ +################################################################################ +# Embtoolkit +# 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 . +# +################################################################################ +# +# \file libxi.kconfig +# \brief libxi.kconfig of Embtoolkit +# \author Abdoulaye Walsimou GAYE +# \date September 2010 +################################################################################ + +config EMBTK_HAVE_LIBXI + bool "Have libXi" + select EMBTK_HAVE_XPROTO + select EMBTK_HAVE_XEXTPROTO + select EMBTK_HAVE_INPUTPROTO + select EMBTK_HAVE_LIBX11 + select EMBTK_HAVE_LIBXEXT + help + library for the X Input Extension. +choice + prompt "libXi version you wish" + depends on EMBTK_HAVE_LIBXI + help + Here you can choose which version of libXi you want to use. + + config EMBTK_LIBXI_VERSION_1_3 + bool "libXi-1.3" +endchoice + +config EMBTK_LIBXI_VERSION_STRING + string + default "1.3" if EMBTK_LIBXI_VERSION_1_3 + +config EMBTK_LIBXI_NEED_PATCH + bool + + diff --git a/packages/x11/libxi/libxi.mk b/packages/x11/libxi/libxi.mk new file mode 100644 index 0000000..5d69d39 --- /dev/null +++ b/packages/x11/libxi/libxi.mk @@ -0,0 +1,108 @@ +################################################################################ +# Embtoolkit +# 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 . +# +################################################################################ +# +# \file libxi.mk +# \brief libxi.mk of Embtoolkit +# \author Abdoulaye Walsimou GAYE +# \date September 2010 +################################################################################ + +LIBXI_VERSION := $(subst ",,$(strip $(CONFIG_EMBTK_LIBXI_VERSION_STRING))) +LIBXI_SITE := http://xorg.freedesktop.org/archive/individual/lib +LIBXI_PATCH_SITE := ftp://ftp.embtoolkit.org/embtoolkit.org/libxi/$(LIBXI_VERSION) +LIBXI_PACKAGE := libXi-$(LIBXI_VERSION).tar.bz2 +LIBXI_BUILD_DIR := $(PACKAGES_BUILD)/libXi-$(LIBXI_VERSION) + +LIBXI_BINS = +LIBXI_SBINS = +LIBXI_INCLUDES = X11/extensions/XInput.h X11/extensions/XInput2.h +LIBXI_LIBS = libXi.* +LIBXI_PKGCONFIGS = xi.pc + +LIBXI_DEPS := xproto_install xextproto_install inputproto_install \ + libx11_install libxext_install + +libxi_install: + @test -e $(LIBXI_BUILD_DIR)/.installed || \ + $(MAKE) $(LIBXI_BUILD_DIR)/.installed + +$(LIBXI_BUILD_DIR)/.installed: $(LIBXI_DEPS) download_libxi \ + $(LIBXI_BUILD_DIR)/.decompressed $(LIBXI_BUILD_DIR)/.configured + $(call EMBTK_GENERIC_MESSAGE,"Compiling and installing \ + libxi-$(LIBXI_VERSION) in your root filesystem...") + $(call EMBTK_KILL_LT_RPATH,$(LIBXI_BUILD_DIR)) + $(Q)$(MAKE) -C $(LIBXI_BUILD_DIR) $(J) + $(Q)$(MAKE) -C $(LIBXI_BUILD_DIR) DESTDIR=$(SYSROOT) install + $(Q)$(MAKE) libtool_files_adapt + $(Q)$(MAKE) pkgconfig_files_adapt + @touch $@ + +download_libxi: + $(call EMBTK_GENERIC_MESSAGE,"Downloading $(LIBXI_PACKAGE) \ + if necessary...") + @test -e $(DOWNLOAD_DIR)/$(LIBXI_PACKAGE) || \ + wget -O $(DOWNLOAD_DIR)/$(LIBXI_PACKAGE) \ + $(LIBXI_SITE)/$(LIBXI_PACKAGE) +ifeq ($(CONFIG_EMBTK_LIBXI_NEED_PATCH),y) + @test -e $(DOWNLOAD_DIR)/libXi-$(LIBXI_VERSION).patch || \ + wget -O $(DOWNLOAD_DIR)/libXi-$(LIBXI_VERSION).patch \ + $(LIBXI_PATCH_SITE)/libXi-$(LIBXI_VERSION)-*.patch +endif + +$(LIBXI_BUILD_DIR)/.decompressed: + $(call EMBTK_GENERIC_MESSAGE,"Decompressing $(LIBXI_PACKAGE) ...") + @tar -C $(PACKAGES_BUILD) -xjf $(DOWNLOAD_DIR)/$(LIBXI_PACKAGE) +ifeq ($(CONFIG_EMBTK_LIBXI_NEED_PATCH),y) + @cd $(LIBXI_BUILD_DIR); \ + patch -p1 < $(DOWNLOAD_DIR)/libXi-$(LIBXI_VERSION).patch +endif + @touch $@ + +$(LIBXI_BUILD_DIR)/.configured: + $(Q)cd $(LIBXI_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 $@ + +libxi_clean: + $(call EMBTK_GENERIC_MESSAGE,"cleanup libxi...") + $(Q)-cd $(SYSROOT)/usr/bin; rm -rf $(LIBXI_BINS) + $(Q)-cd $(SYSROOT)/usr/sbin; rm -rf $(LIBXI_SBINS) + $(Q)-cd $(SYSROOT)/usr/include; rm -rf $(LIBXI_INCLUDES) + $(Q)-cd $(SYSROOT)/usr/$(LIBDIR); rm -rf $(LIBXI_LIBS) + $(Q)-cd $(SYSROOT)/usr/$(LIBDIR)/pkgconfig; rm -rf $(LIBXI_PKGCONFIGS) + $(Q)-rm -rf $(LIBXI_BUILD_DIR)* + diff --git a/packages/x11/x11.kconfig b/packages/x11/x11.kconfig index 04020eb..083232f 100644 --- a/packages/x11/x11.kconfig +++ b/packages/x11/x11.kconfig @@ -54,6 +54,7 @@ source packages/x11/libpciaccess/libpciaccess.kconfig source packages/x11/libpthreadstubs/libpthreadstubs.kconfig source packages/x11/libx11/libx11.kconfig source packages/x11/libxau/libxau.kconfig +source packages/x11/libxi/libxi.kconfig source packages/x11/libxcb/libxcb.kconfig source packages/x11/libxcomposite/libxcomposite.kconfig source packages/x11/libxext/libxext.kconfig @@ -66,6 +67,7 @@ source packages/x11/libxrender/libxrender.kconfig endmenu menu "X windowing system application packages" +source packages/x11/xinput/xinput.kconfig source packages/x11/xkeyboardconfig/xkeyboardconfig.kconfig source packages/x11/xkbcomp/xkbcomp.kconfig source packages/x11/xtrans/xtrans.kconfig diff --git a/packages/x11/x11.mk b/packages/x11/x11.mk index cf905f9..b6046b0 100644 --- a/packages/x11/x11.mk +++ b/packages/x11/x11.mk @@ -123,6 +123,10 @@ ROOTFS_COMPONENTS-$(CONFIG_EMBTK_HAVE_LIBX11) += libx11_install include $(EMBTK_ROOT)/packages/x11/libxau/libxau.mk ROOTFS_COMPONENTS-$(CONFIG_EMBTK_HAVE_LIBXAU) += libxau_install +#libxi +include $(EMBTK_ROOT)/packages/x11/libxi/libxi.mk +ROOTFS_COMPONENTS-$(CONFIG_EMBTK_HAVE_LIBXI) += libxi_install + #libxcb include $(EMBTK_ROOT)/packages/x11/libxcb/libxcb.mk ROOTFS_COMPONENTS-$(CONFIG_EMBTK_HAVE_LIBXCB) += libxcb_install @@ -162,6 +166,10 @@ ROOTFS_COMPONENTS-$(CONFIG_EMBTK_HAVE_LIBXRENDER) += libxrender_install ######################################### # X windowing system application packages ######################################### +#xinput +include $(EMBTK_ROOT)/packages/x11/xinput/xinput.mk +ROOTFS_COMPONENTS-$(CONFIG_EMBTK_HAVE_XINPUT) += xinput_install + #xkbcomp include $(EMBTK_ROOT)/packages/x11/xkbcomp/xkbcomp.mk ROOTFS_COMPONENTS-$(CONFIG_EMBTK_HAVE_XKBCOMP) += xkbcomp_install diff --git a/packages/x11/xinput/xinput.kconfig b/packages/x11/xinput/xinput.kconfig new file mode 100644 index 0000000..0729c2b --- /dev/null +++ b/packages/x11/xinput/xinput.kconfig @@ -0,0 +1,52 @@ +################################################################################ +# Embtoolkit +# 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 . +# +################################################################################ +# +# \file xinput.kconfig +# \brief xinput.kconfig of Embtoolkit +# \author Abdoulaye Walsimou GAYE +# \date September 2010 +################################################################################ + +config EMBTK_HAVE_XINPUT + bool "Have xinput" + select EMBTK_HAVE_XPROTO + select EMBTK_HAVE_INPUTPROTO + select EMBTK_HAVE_LIBX11 + select EMBTK_HAVE_LIBXEXT + select EMBTK_HAVE_LIBXI + help + xinput is a utility to configure and test XInput devices. +choice + prompt "xinput version you wish" + depends on EMBTK_HAVE_XINPUT + help + Here you can choose which version of xinput you want to use. + + config EMBTK_XINPUT_VERSION_1_5_2 + bool "xinput-1.5.2" +endchoice + +config EMBTK_XINPUT_VERSION_STRING + string + default "1.5.2" if EMBTK_XINPUT_VERSION_1_5_2 + +config EMBTK_XINPUT_NEED_PATCH + bool + + diff --git a/packages/x11/xinput/xinput.mk b/packages/x11/xinput/xinput.mk new file mode 100644 index 0000000..7f17b00 --- /dev/null +++ b/packages/x11/xinput/xinput.mk @@ -0,0 +1,108 @@ +################################################################################ +# Embtoolkit +# 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 . +# +################################################################################ +# +# \file xinput.mk +# \brief xinput.mk of Embtoolkit +# \author Abdoulaye Walsimou GAYE +# \date September 2010 +################################################################################ + +XINPUT_VERSION := $(subst ",,$(strip $(CONFIG_EMBTK_XINPUT_VERSION_STRING))) +XINPUT_SITE := http://xorg.freedesktop.org/archive/individual/app +XINPUT_PATCH_SITE := ftp://ftp.embtoolkit.org/embtoolkit.org/xinput/$(XINPUT_VERSION) +XINPUT_PACKAGE := xinput-$(XINPUT_VERSION).tar.bz2 +XINPUT_BUILD_DIR := $(PACKAGES_BUILD)/xinput-$(XINPUT_VERSION) + +XINPUT_BINS = xinput +XINPUT_SBINS = +XINPUT_INCLUDES = +XINPUT_LIBS = +XINPUT_PKGCONFIGS = + +XINPUT_DEPS := xproto_install inputproto_install libx11_install \ + libxext_install libxi_install + +xinput_install: + @test -e $(XINPUT_BUILD_DIR)/.installed || \ + $(MAKE) $(XINPUT_BUILD_DIR)/.installed + +$(XINPUT_BUILD_DIR)/.installed: $(XINPUT_DEPS) download_xinput \ + $(XINPUT_BUILD_DIR)/.decompressed $(XINPUT_BUILD_DIR)/.configured + $(call EMBTK_GENERIC_MESSAGE,"Compiling and installing \ + xinput-$(XINPUT_VERSION) in your root filesystem...") + $(call EMBTK_KILL_LT_RPATH,$(XINPUT_BUILD_DIR)) + $(Q)$(MAKE) -C $(XINPUT_BUILD_DIR) $(J) + $(Q)$(MAKE) -C $(XINPUT_BUILD_DIR) DESTDIR=$(SYSROOT) install + $(Q)$(MAKE) libtool_files_adapt + $(Q)$(MAKE) pkgconfig_files_adapt + @touch $@ + +download_xinput: + $(call EMBTK_GENERIC_MESSAGE,"Downloading $(XINPUT_PACKAGE) \ + if necessary...") + @test -e $(DOWNLOAD_DIR)/$(XINPUT_PACKAGE) || \ + wget -O $(DOWNLOAD_DIR)/$(XINPUT_PACKAGE) \ + $(XINPUT_SITE)/$(XINPUT_PACKAGE) +ifeq ($(CONFIG_EMBTK_XINPUT_NEED_PATCH),y) + @test -e $(DOWNLOAD_DIR)/xinput-$(XINPUT_VERSION).patch || \ + wget -O $(DOWNLOAD_DIR)/xinput-$(XINPUT_VERSION).patch \ + $(XINPUT_PATCH_SITE)/xinput-$(XINPUT_VERSION)-*.patch +endif + +$(XINPUT_BUILD_DIR)/.decompressed: + $(call EMBTK_GENERIC_MESSAGE,"Decompressing $(XINPUT_PACKAGE) ...") + @tar -C $(PACKAGES_BUILD) -xjf $(DOWNLOAD_DIR)/$(XINPUT_PACKAGE) +ifeq ($(CONFIG_EMBTK_XINPUT_NEED_PATCH),y) + @cd $(XINPUT_BUILD_DIR); \ + patch -p1 < $(DOWNLOAD_DIR)/xinput-$(XINPUT_VERSION).patch +endif + @touch $@ + +$(XINPUT_BUILD_DIR)/.configured: + $(Q)cd $(XINPUT_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 + @touch $@ + +xinput_clean: + $(call EMBTK_GENERIC_MESSAGE,"cleanup xinput...") + $(Q)-cd $(SYSROOT)/usr/bin; rm -rf $(XINPUT_BINS) + $(Q)-cd $(SYSROOT)/usr/sbin; rm -rf $(XINPUT_SBINS) + $(Q)-cd $(SYSROOT)/usr/include; rm -rf $(XINPUT_INCLUDES) + $(Q)-cd $(SYSROOT)/usr/$(LIBDIR); rm -rf $(XINPUT_LIBS) + $(Q)-cd $(SYSROOT)/usr/$(LIBDIR)/pkgconfig; rm -rf $(XINPUT_PKGCONFIGS) + $(Q)-rm -rf $(XINPUT_BUILD_DIR)* + -- cgit v1.2.3