From 555ec261298d46b861db39c894adb8291cd86ab0 Mon Sep 17 00:00:00 2001 From: Scott James Remnant Date: Tue, 1 May 2012 14:41:32 -0700 Subject: [PATCH] Add games-util/joystick from portage, enable arm jstest is useful for testing. BUG=chromium-os:30273 TEST=emerge-$BOARD games-util/joystick Change-Id: I5a79a5dbf5ea2e65899524f4c47a2f1cfecb3f05 Reviewed-on: https://gerrit.chromium.org/gerrit/21549 Reviewed-by: Mike Frysinger Commit-Ready: Scott James Remnant Tested-by: Scott James Remnant --- .../joystick/files/joystick-1.4.2-build.patch | 79 +++++++++++++++++++ .../games-util/joystick/joystick-1.4.2.ebuild | 34 ++++++++ 2 files changed, 113 insertions(+) create mode 100644 sdk_container/src/third_party/portage-stable/games-util/joystick/files/joystick-1.4.2-build.patch create mode 100644 sdk_container/src/third_party/portage-stable/games-util/joystick/joystick-1.4.2.ebuild diff --git a/sdk_container/src/third_party/portage-stable/games-util/joystick/files/joystick-1.4.2-build.patch b/sdk_container/src/third_party/portage-stable/games-util/joystick/files/joystick-1.4.2-build.patch new file mode 100644 index 0000000000..6e3d5774e5 --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/games-util/joystick/files/joystick-1.4.2-build.patch @@ -0,0 +1,79 @@ +--- a/docs/Makefile ++++ b/docs/Makefile +@@ -20,13 +20,16 @@ + # 02110-1301 USA. + + MANPAGES = inputattach.1 jstest.1 jscal.1 fftest.1 \ +- ffmvforce.1 ffset.1 ffcfstress.1 jscal-store.1 \ ++ ffset.1 ffcfstress.1 jscal-store.1 \ + jscal-restore.1 ++ifneq ($(USE_SDL),no) ++MANPAGES += ffmvforce.1 ++endif + + PREFIX ?= /usr/local + + install: + install -d $(DESTDIR)$(PREFIX)/share/man/man1 +- install $(MANPAGES) $(DESTDIR)$(PREFIX)/share/man/man1 ++ install -m 644 $(MANPAGES) $(DESTDIR)$(PREFIX)/share/man/man1 + + .PHONY: install +--- a/utils/Makefile ++++ b/utils/Makefile +@@ -25,11 +25,19 @@ + # Edit the options below to suit your needs + # + +-CC = gcc +-CFLAGS = -g -O2 -Wall -I../linux/include ++CC ?= gcc ++PKG_CONFIG ?= pkg-config ++CFLAGS ?= -g -O2 ++CFLAGS += -Wall ++CPPFLAGS += -I../linux/include ++SDL_CFLAGS = $(shell $(PKG_CONFIG) --cflags sdl) ++SDL_LIBS = $(shell $(PKG_CONFIG) --libs sdl) + +-PROGRAMS = inputattach jstest jscal fftest ffmvforce ffset \ ++PROGRAMS = inputattach jstest jscal fftest ffset \ + ffcfstress jscal-restore jscal-store ++ifneq ($(USE_SDL),no) ++PROGRAMS += ffmvforce ++endif + + PREFIX ?= /usr/local + +@@ -40,27 +48,27 @@ + $(RM) *.o *.swp $(PROGRAMS) *.orig *.rej map *~ + + ffcfstress: ffcfstress.c +- $(CC) -O2 -funsigned-char ffcfstress.c -lm -o ffcfstress ++ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -funsigned-char ffcfstress.c -lm -o ffcfstress + + ffmvforce.o: ffmvforce.c +- $(CC) -c $(CFLAGS) $(CPPFLAGS) $^ -o $@ `sdl-config --cflags` ++ $(CC) -c $(CFLAGS) $(CPPFLAGS) $(SDL_CFLAGS) $^ -o $@ + + ffmvforce: ffmvforce.o +- $(CC) $^ -o $@ $(LDFLAGS) -g -lm `sdl-config --libs` ++ $(CC) $^ -o $@ $(CFLAGS) $(LDFLAGS) -lm $(SDL_LIBS) + + axbtnmap.o: axbtnmap.c axbtnmap.h + + jscal.o: jscal.c axbtnmap.h + + jscal: jscal.o axbtnmap.o +- $(CC) $(CFLAGS) $(CPPFLAGS) $^ -lm -o $@ ++ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) $^ -lm -o $@ + + jstest.o: jstest.c axbtnmap.h + + jstest: jstest.o axbtnmap.o + + gencodes: gencodes.c scancodes.h +- $(CC) $(CFLAGS) $(CPPFLAGS) gencodes.c -o gencodes ++ $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) gencodes.c -o gencodes + + jscal-restore: jscal-restore.in + sed "s^@@PREFIX@@^$(PREFIX)^g" < $^ > $@ diff --git a/sdk_container/src/third_party/portage-stable/games-util/joystick/joystick-1.4.2.ebuild b/sdk_container/src/third_party/portage-stable/games-util/joystick/joystick-1.4.2.ebuild new file mode 100644 index 0000000000..3d2be1847c --- /dev/null +++ b/sdk_container/src/third_party/portage-stable/games-util/joystick/joystick-1.4.2.ebuild @@ -0,0 +1,34 @@ +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/games-util/joystick/joystick-1.4.2.ebuild,v 1.4 2012/04/15 16:53:35 maekke Exp $ + +EAPI="4" + +inherit eutils toolchain-funcs + +MY_P="linuxconsoletools-${PV}" +DESCRIPTION="joystick testing utilities" +HOMEPAGE="http://sourceforge.net/projects/linuxconsole/ http://atrey.karlin.mff.cuni.cz/~vojtech/input/" +SRC_URI="mirror://sourceforge/linuxconsole/files/${MY_P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="amd64 arm ppc x86" +IUSE="sdl" + +DEPEND="sdl? ( media-libs/libsdl[video] ) + !