Browse Source

openobex: add new package (v1.7.1)

Signed-off-by: Nicolas Thill <nico@openwrt.org>
Nicolas Thill 10 years ago
parent
commit
8c482bdf95
2 changed files with 99 additions and 0 deletions
  1. 89
    0
      utils/openobex/Makefile
  2. 10
    0
      utils/openobex/patches/001-cxx.patch

+ 89
- 0
utils/openobex/Makefile View File

@@ -0,0 +1,89 @@
1
+#
2
+# Copyright (C) 2015 OpenWrt.org
3
+#
4
+# This is free software, licensed under the GNU General Public License v2.
5
+# See /LICENSE for more information.
6
+#
7
+
8
+include $(TOPDIR)/rules.mk
9
+
10
+PKG_NAME:=openobex
11
+PKG_VERSION:=1.7.1
12
+PKG_RELEASE:=1
13
+
14
+PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)-Source
15
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-Source.tar.gz
16
+PKG_SOURCE_URL:=@SF/openobex
17
+PKG_MD5SUM:=3181bfed9cb7db591605391068cb0085
18
+
19
+PKG_LICENSE:=GPL-2.0+ LGPL-2.1+
20
+PKG_LICENSE_FILES:=COPYING
21
+PKG_MAINTAINER:=Nicolas Thill <nico@openwrt.org>
22
+
23
+include $(INCLUDE_DIR)/package.mk
24
+include $(INCLUDE_DIR)/cmake.mk
25
+
26
+define Package/openobex/Default
27
+  TITLE:=Open Source impl of the OBject EXchange protocol
28
+  URL:=https://www.gitorious.org/openobex
29
+endef
30
+
31
+define Package/openobex
32
+$(call Package/openobex/Default)
33
+  SECTION:=utils
34
+  CATEGORY:=Utilities
35
+  TITLE+= (meta)
36
+  DEPENDS:=+openobex-apps +libopenobex
37
+endef
38
+
39
+define Package/openobex-apps
40
+$(call Package/openobex/Default)
41
+  SECTION:=utils
42
+  CATEGORY:=Utilities
43
+  TITLE+= (apps)
44
+  DEPENDS:=+libopenobex +bluez-libs
45
+endef
46
+
47
+define Package/libopenobex
48
+$(call Package/openobex/Default)
49
+  SECTION:=libs
50
+  CATEGORY:=Libraries
51
+  TITLE+= (library)
52
+  DEPENDS:=+libusb-1.0
53
+endef
54
+
55
+CMAKE_OPTIONS += \
56
+	-DBUILD_DOCUMENTATION:BOOL=OFF \
57
+
58
+MAKE_FLAGS += \
59
+	openobex openobex-apps \
60
+
61
+define Build/InstallDev
62
+	$(INSTALL_DIR) $(1)/usr/include
63
+	$(CP) $(PKG_INSTALL_DIR)/usr/include/openobex $(1)/usr/include/
64
+	$(INSTALL_DIR) $(1)/usr/lib
65
+	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libopenobex.so* $(1)/usr/lib/
66
+	$(CP) $(PKG_BUILD_DIR)/apps/lib/libopenobex-apps-common.a $(1)/usr/lib/
67
+	$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
68
+	$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/openobex.pc $(1)/usr/lib/pkgconfig/
69
+endef
70
+
71
+define Package/openobex/install
72
+	:
73
+endef
74
+
75
+define Package/openobex-apps/install
76
+	$(INSTALL_DIR) $(1)/usr/bin
77
+	$(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
78
+	$(INSTALL_DIR) $(1)/usr/sbin
79
+	$(CP) $(PKG_INSTALL_DIR)/usr/sbin/* $(1)/usr/sbin/
80
+endef
81
+
82
+define Package/libopenobex/install
83
+	$(INSTALL_DIR) $(1)/usr/lib
84
+	$(CP) $(PKG_INSTALL_DIR)/usr/lib/libopenobex.so.* $(1)/usr/lib/
85
+endef
86
+
87
+$(eval $(call BuildPackage,openobex))
88
+$(eval $(call BuildPackage,openobex-apps))
89
+$(eval $(call BuildPackage,libopenobex))

+ 10
- 0
utils/openobex/patches/001-cxx.patch View File

@@ -0,0 +1,10 @@
1
+--- a/CMakeLists.txt
2
++++ b/CMakeLists.txt
3
+@@ -1,6 +1,6 @@
4
+ cmake_minimum_required ( VERSION 2.8.5 FATAL_ERROR )
5
+ 
6
+-project ( openobex C )
7
++project ( openobex C CXX )
8
+ 
9
+ #
10
+ # The project version