[package] lvm2: add new mirror and fix shared library installation
authorFlorian Fainelli <florian@openwrt.org>
Sat, 20 Mar 2010 12:16:04 +0000 (12:16 +0000)
committerFlorian Fainelli <florian@openwrt.org>
Sat, 20 Mar 2010 12:16:04 +0000 (12:16 +0000)
SVN-Revision: 20319

utils/lvm2/Makefile

index e2abe42..3eacf30 100644 (file)
@@ -11,7 +11,8 @@ PKG_VERSION:=2.02.60
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME).$(PKG_VERSION).tgz
-PKG_SOURCE_URL:=ftp://sources.redhat.com/pub/lvm2/
+PKG_SOURCE_URL:=ftp://sources.redhat.com/pub/lvm2/ \
+               http://netbsd.mirrors.tds.net/pub/sourceware.org/lvm2/
 PKG_MD5SUM:=33e0e0f4b4582d495ff619696c634b2a
 # 2.02.43 = fc34655706a2aa116b92328b24fad619
 # 2.02.44 = 4ed7b99903a6fc5165b7b0b8def42486
@@ -81,18 +82,25 @@ endef
 # Debian Lenny's lvm2 also disables O_DIRECT on "arm armeb hppa mips mipsel".
 CONFIGURE_ARGS += --disable-o_direct
 
+define Build/Compile
+       $(MAKE) -C $(PKG_BUILD_DIR) \
+               CFLAGS="$(TARGET_CFLAGS) $(TARGET_CPPFLAGS)" \
+               DESTDIR="$(PKG_INSTALL_DIR)" \
+               install
+endef
+
 define Build/InstallDev
        mkdir -p $(1)/usr/include
-       $(INSTALL_DATA) $(PKG_BUILD_DIR)/include/libdevmapper.h $(1)/usr/include/
+       $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/include/libdevmapper.h $(1)/usr/include/
        mkdir -p $(1)/usr/lib
-       $(CP) $(PKG_BUILD_DIR)/libdm/ioctl/libdevmapper.so $(1)/usr/lib/
+       $(CP) $(PKG_INSTALL_DIR)/usr/lib/libdevmapper.so* $(1)/usr/lib/
        mkdir -p $(1)/usr/lib/pkgconfig
        $(CP) $(PKG_BUILD_DIR)/libdm/libdevmapper.pc $(1)/usr/lib/pkgconfig/
 endef
 
 define Package/libdevmapper/install
        $(INSTALL_DIR) $(1)/usr/lib
-       $(INSTALL_DATA) $(PKG_BUILD_DIR)/libdm/libdevmapper.so.* $(1)/usr/lib/
+       $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/libdevmapper.so.* $(1)/usr/lib/
 endef
 
 # This rule only installs the `lvm' executable.  Debian also installs