Browse Source

gammu: use cmake.mk

- remove not needed legacy stuff
- fix lib64 suffix when installing
fixes build error when target is x86_64

Signed-off-by: Dirk Neukirchen <dirkneukirchen@web.de>
lilik-openwrt-22.03
Dirk Neukirchen 10 years ago
parent
commit
5819a55155
1 changed files with 6 additions and 21 deletions
  1. +6
    -21
      utils/gammu/Makefile

+ 6
- 21
utils/gammu/Makefile View File

@ -10,7 +10,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=gammu
PKG_VERSION:=1.34.0
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_SOURCE_URL:=http://dl.cihar.com/gammu/releases/
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
@ -18,8 +18,11 @@ PKG_MD5SUM:=5bc2508389d9b291ca0b8d4f210d0012
PKG_MAINTAINER:=Vitaly Protsko <villy@sft.ru>
PKG_LICENCE:=GPL-2.0
PKG_INSTALL:=1
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/nls.mk
include $(INCLUDE_DIR)/cmake.mk
define Package/gammu
SECTION:=utils
@ -32,30 +35,12 @@ define Package/gammu
DEPENDS+=+PACKAGE_libusb-1.0:libusb-1.0
endef
CONFIGURE_ARGS:= \
--prefix=/usr \
--cross-root="$(STAGING_DIR) $(TOOLCHAIN_DIR)" \
--enable-shared \
--without-libdbi
define Build/Compile
$(MAKE) -C $(PKG_BUILD_DIR) \
$(TARGET_CONFIGURE_OPTS) \
LDSHARED="$(TARGET_CROSS)ld -shared" \
CFLAGS="$(TARGET_CFLAGS) $(FPIC)"
endef
define Build/Install
$(MAKE) -C $(PKG_BUILD_DIR) \
DESTDIR="$(PKG_INSTALL_DIR)" \
install
endef
define Build/InstallDev
mkdir -p $(1)/usr/include
$(CP) -r $(PKG_INSTALL_DIR)/usr/include/gammu $(1)/usr/include/
mkdir -p $(1)/usr/lib
$(CP) $(PKG_INSTALL_DIR)/usr/lib/lib{Gammu*,gsmsd*} $(1)/usr/lib/
$(CP) $(PKG_INSTALL_DIR)/usr/lib$(LIB_SUFFIX)/lib{Gammu*,gsmsd*} $(1)/usr/lib/
endef
define Package/gammu/install
@ -63,7 +48,7 @@ define Package/gammu/install
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gammu $(1)/usr/bin
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gammu-{smsd,smsd-inject,smsd-monitor} $(1)/usr/bin
$(INSTALL_DIR) $(1)/usr/lib
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/lib{Gammu*,gsmsd*} $(1)/usr/lib
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib$(LIB_SUFFIX)/lib{Gammu*,gsmsd*} $(1)/usr/lib
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_CONF) ./files/gammu $(1)/etc/config/gammu


Loading…
Cancel
Save