2008-06-22 21:41:09 +03:00
|
|
|
#
|
|
|
|
# Copyright (C) 2006-2008 OpenWrt.org
|
2006-09-07 15:42:27 +03:00
|
|
|
#
|
|
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
|
|
# See /LICENSE for more information.
|
|
|
|
#
|
|
|
|
# $Id$
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME:=gmp
|
2008-06-22 21:41:09 +03:00
|
|
|
PKG_VERSION:=4.2.2
|
2006-09-07 15:42:27 +03:00
|
|
|
PKG_RELEASE:=1
|
|
|
|
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
|
|
|
PKG_SOURCE_URL:=@GNU/gmp
|
2008-06-22 21:41:09 +03:00
|
|
|
PKG_MD5SUM:=7ce52531644e6d12f16911b7e3151f3f
|
2006-09-07 15:42:27 +03:00
|
|
|
|
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
|
|
|
|
define Package/libgmp
|
|
|
|
SECTION:=libs
|
|
|
|
CATEGORY:=Libraries
|
|
|
|
TITLE:=GNU multiprecision arithmetic library
|
2008-06-22 21:41:09 +03:00
|
|
|
URL:=http://gmplib.org/
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/libgmp/description
|
|
|
|
GMP is a free library for arbitrary precision arithmetic, operating on
|
|
|
|
signed integers, rational numbers, and floating point numbers.
|
2006-09-07 15:42:27 +03:00
|
|
|
endef
|
|
|
|
|
2007-02-26 01:34:57 +02:00
|
|
|
CONFIGURE_VARS += CC="$(TARGET_CROSS)gcc"
|
|
|
|
CONFIGURE_ARGS += \
|
|
|
|
--enable-shared \
|
|
|
|
--enable-static \
|
2006-09-07 15:42:27 +03:00
|
|
|
|
|
|
|
define Build/Compile
|
2006-09-23 16:27:50 +03:00
|
|
|
$(call Build/Compile/Default, \
|
|
|
|
DESTDIR="$(PKG_INSTALL_DIR)" \
|
2006-10-05 14:08:18 +03:00
|
|
|
CC="$(TARGET_CC)" \
|
2006-09-23 16:27:50 +03:00
|
|
|
all install \
|
|
|
|
)
|
2006-09-07 15:42:27 +03:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Build/InstallDev
|
2007-09-28 04:45:11 +03:00
|
|
|
mkdir -p $(1)/usr/include
|
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/gmp* $(1)/usr/include/
|
|
|
|
mkdir -p $(1)/usr/lib
|
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libgmp.{a,so*} $(1)/usr/lib/
|
2006-09-07 15:42:27 +03:00
|
|
|
endef
|
|
|
|
|
2006-09-23 16:27:50 +03:00
|
|
|
define Package/libgmp/install
|
2006-11-23 02:29:07 +02:00
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
2006-09-23 16:27:50 +03:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libgmp.so.* $(1)/usr/lib/
|
|
|
|
endef
|
|
|
|
|
2006-09-07 15:42:27 +03:00
|
|
|
$(eval $(call BuildPackage,libgmp))
|