[packages] add libimobiledevice, libplist & usbmuxd for iPhone tethering (#10157)

git-svn-id: svn://svn.openwrt.org/openwrt/packages@29714 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
swalker 2012-01-12 06:41:03 +00:00
parent 46f2694a74
commit 6ceb1322ea
3 changed files with 265 additions and 0 deletions

View File

@ -0,0 +1,85 @@
#
# Copyright (C) 2012 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=libimobiledevice
PKG_REV:=c182599c8c18ed729726ea7cbbd0a3b89790d2db
PKG_VERSION:=20120112
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=git://git.sukimashita.com/libimobiledevice.git
PKG_SOURCE_PROTO:=git
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_VERSION:=$(PKG_REV)
PKG_FIXUP:=autoreconf
PKG_INSTALL:=1
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/nls.mk
$(call include_mk, python-package.mk)
define Package/libimobiledevice/Default
TITLE:=A library that talks to Apple devices.
URL:=http://www.libimobiledevice.org/
endef
define Package/libimobiledevice/Default/description
libimobiledevice is a software library that talks the protocols to support
iPhone®, iPod Touch®, iPad® and Apple TV® devices.
endef
define Package/libimobiledevice
$(call Package/libimobiledevice/Default)
SECTION:=libs
CATEGORY:=Libraries
DEPENDS:=+glib2 +libgcrypt +libgnutls $(ICONV_DEPENDS) +libplist +libtasn1 +libusbmuxd
endef
define Package/libimobiledevice/description
$(call Package/libimobiledevice/Default/description)
endef
define Package/libimobiledevice-utils
$(call Package/libimobiledevice/Default)
SECTION:=utils
CATEGORY:=Utilities
DEPENDS:=+libimobiledevice
endef
define Package/libimobiledevice-utils/description
$(call Package/libimobiledevice/Default/description)
This package contains the libimobiledevice utilities.
endef
CONFIGURE_ARGS += --without-swig
TARGET_LDFLAGS += -Wl,-rpath-link=$(STAGING_DIR)/usr/lib
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include
$(CP) $(PKG_INSTALL_DIR)/usr/include/libimobiledevice $(1)/usr/include/
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libimobiledevice.{a,la,so*} $(1)/usr/lib/
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libimobiledevice-*.pc $(1)/usr/lib/pkgconfig/
endef
define Package/libimobiledevice/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libimobiledevice.so.* $(1)/usr/lib/
endef
define Package/libimobiledevice-utils/install
$(INSTALL_DIR) $(1)/usr/bin
$(CP) $(PKG_INSTALL_DIR)/usr/bin/idevice* $(1)/usr/bin/
endef
$(eval $(call BuildPackage,libimobiledevice))
$(eval $(call BuildPackage,libimobiledevice-utils))

96
libs/libplist/Makefile Normal file
View File

@ -0,0 +1,96 @@
#
# Copyright (C) 2012 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=libplist
PKG_VERSION:=1.8
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=http://www.libimobiledevice.org/downloads
PKG_MD5SUM:=2a9e0258847d50f9760dc3ece25f4dc6
CMAKE_INSTALL:=1
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk
define Package/libplist/Default
TITLE:=Apple property list
URL:=http://www.libimobiledevice.org/
endef
define Package/libplist/Default/description
A library to handle Apple Property List format whereas it's binary or XML
endef
define Package/libplist
$(call Package/libplist/Default)
SECTION:=libs
CATEGORY:=Libraries
DEPENDS:=+libxml2
TITLE+= library
endef
define Package/libplist/description
$(call Package/libplist/Default/description)
endef
define Package/libplistcxx
$(call Package/libplist/Default)
SECTION:=libs
CATEGORY:=Libraries
DEPENDS:=+libplist +libstdcpp
TITLE+= C++ library
endef
define Package/libplistcxx/description
$(call Package/libplist/Default/description)
This package contains the libplist C++ shared library.
endef
define Package/libplist-utils
$(call Package/libplist/Default)
SECTION:=utils
CATEGORY:=Utilities
DEPENDS:=+libplist
TITLE+= converter
endef
define Package/libplist-utils/description
$(call Package/libplist/Default/description)
This package contains the libplist utilities.
endef
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include
$(CP) $(PKG_INSTALL_DIR)/usr/include/plist $(1)/usr/include/
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libplist*.so* $(1)/usr/lib/
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libplist*.pc $(1)/usr/lib/pkgconfig/
endef
define Package/libplist/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libplist.so.* $(1)/usr/lib/
endef
define Package/libplistcxx/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libplist++.so.* $(1)/usr/lib/
endef
define Package/libplist-utils/install
$(INSTALL_DIR) $(1)/usr/bin
$(CP) $(PKG_INSTALL_DIR)/usr/bin/plutil* $(1)/usr/bin/
endef
$(eval $(call BuildPackage,libplist))
$(eval $(call BuildPackage,libplistcxx))
$(eval $(call BuildPackage,libplist-utils))

84
utils/usbmuxd/Makefile Normal file
View File

@ -0,0 +1,84 @@
#
# Copyright (C) 2012 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=usbmuxd
PKG_VERSION:=1.0.7
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_URL:=http://marcansoft.com/uploads/usbmuxd
PKG_MD5SUM:=6f431541f3177fa06aa6df9ceecb2da0
CMAKE_INSTALL:=1
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk
define Package/usbmuxd/Default
TITLE:=USB multiplexing daemon
URL:=http://marcansoft.com/blog/iphonelinux/usbmuxd/
endef
define Package/usbmuxd/Default/description
This daemon is in charge of multiplexing connections over USB to an iPhone or
iPod touch. To users, it means you can sync your music, contacts, photos, etc.
over USB. To developers, it means you can connect to any listening localhost
socket on the device. usbmuxd is not used for tethering data transfer, which
uses a dedicated USB interface as a virtual network device.
endef
define Package/usbmuxd
$(call Package/usbmuxd/Default)
SECTION:=utils
CATEGORY:=Utilities
DEPENDS:=+librt +libusb-1.0 +libusbmuxd
endef
define Package/usbmuxd/description
$(call Package/usbmuxd/Default/description)
endef
define Package/libusbmuxd
$(call Package/usbmuxd/Default)
SECTION:=libs
CATEGORY:=Libraries
TITLE+= library
DEPENDS:=+libplist +libpthread +libxml2 +zlib
endef
define Package/libusbmuxd/description
$(call Package/usbmuxd/Default/description)
This package contains the usbmuxd shared library.
endef
TARGET_CFLAGS += $(FPIC)
define Build/InstallDev
$(INSTALL_DIR) $(1)/usr/include
$(CP) $(PKG_INSTALL_DIR)/usr/include/*.h $(1)/usr/include/
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libusbmuxd.so* $(1)/usr/lib/
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libusbmuxd.pc $(1)/usr/lib/pkgconfig/
endef
define Package/usbmuxd/install
$(INSTALL_DIR) $(1)/usr/bin
$(CP) $(PKG_INSTALL_DIR)/usr/bin/iproxy $(1)/usr/bin/
$(INSTALL_DIR) $(1)/usr/sbin
$(CP) $(PKG_INSTALL_DIR)/usr/sbin/usbmuxd $(1)/usr/sbin/
endef
define Package/libusbmuxd/install
$(INSTALL_DIR) $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libusbmuxd.so.* $(1)/usr/lib/
endef
$(eval $(call BuildPackage,usbmuxd))
$(eval $(call BuildPackage,libusbmuxd))