source: packages/utils/cwiid/Makefile @ 22224

Last change on this file since 22224 was 22224, checked in by nico, 6 years ago

[packages] cwiid: don't build on 2.4, reformat, cleanup

  • use the uinput subsystem, only available on 2.6
File size: 1.8 KB
Line 
1#
2# Copyright (C) 2010 OpenWrt.org
3#
4# This is free software, licensed under the GNU General Public License v2.
5# See /LICENSE for more information.
6#
7
8include $(TOPDIR)/rules.mk
9
10PKG_NAME:=cwiid
11PKG_VERSION:=0.6.00
12PKG_RELEASE:=1
13
14PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tgz
15PKG_SOURCE_URL:=http://abstrakraft.org/cwiid/downloads/
16PKG_SOURCE_VERSION:=2100f14c612471084434b364501e3818c7f4144e
17
18include $(INCLUDE_DIR)/package.mk
19
20define Package/cwiid/Default
21  TITLE:=Linux Nintendo Wiimote interface
22  URL:=http://abstrakraft.org/cwiid/
23  DEPENDS:= @!LINUX_2_4
24endef
25
26define Package/libcwiid
27$(call Package/cwiid/Default)
28  SECTION:=libs
29  CATEGORY:=Libraries
30  TITLE+= (library)
31  DEPENDS+= +bluez-libs
32endef
33
34define Package/wminput
35$(call Package/cwiid/Default)
36  SECTION:=utils
37  CATEGORY:=Utilities
38  TITLE+= (utility)
39  DEPENDS+= +libcwiid
40endef
41
42CONFIGURE_ARGS += \
43        --without-python \
44        --disable-ldconfig \
45        --enable-shared \
46
47TARGET_CFLAGS += $(FPIC)
48
49define Build/Prepare
50        $(call Build/Prepare/Default)
51        ( cd $(PKG_BUILD_DIR) ; \
52                autoconf ; \
53        )
54endef
55
56define Build/Compile
57        $(MAKE) -C "$(PKG_BUILD_DIR)" \
58                CC="$(TARGET_CC)" \
59                OFLAGS="$(TARGET_CFLAGS)" \
60                CPPFLAGS="$(TARGET_CPPFLAGS)" \
61                LDFLAGS="$(TARGET_LDFLAGS) -L../libcwiid/" \
62                all
63endef
64
65define Build/InstallDev
66        $(INSTALL_DIR) $(1)/usr/include
67        $(CP) $(PKG_BUILD_DIR)/libcwiid/*.h $(1)/usr/include/
68        $(INSTALL_DIR) $(1)/usr/lib
69        $(CP) $(PKG_BUILD_DIR)/libcwiid/*.so $(1)/usr/lib/
70endef
71
72define Package/libcwiid/install
73        $(INSTALL_DIR) $(1)/usr/lib
74        $(CP) $(PKG_BUILD_DIR)/libcwiid/libcwiid.so.1.0 $(1)/usr/lib/
75endef
76
77define Package/wminput/install
78        $(INSTALL_DIR) $(1)/usr/bin
79        $(CP) $(PKG_BUILD_DIR)/wminput/wminput $(1)/usr/bin/
80        $(CP) $(PKG_BUILD_DIR)/lswm/lswm $(1)/usr/bin/
81endef
82
83$(eval $(call BuildPackage,libcwiid))
84$(eval $(call BuildPackage,wminput))
Note: See TracBrowser for help on using the repository browser.