2008-06-22 18:41:09 +00:00
|
|
|
#
|
|
|
|
# Copyright (C) 2006-2008 OpenWrt.org
|
2006-09-07 12:42:27 +00: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 18:41:09 +00:00
|
|
|
PKG_VERSION:=4.2.2
|
2006-09-07 12:42:27 +00:00
|
|
|
PKG_RELEASE:=1
|
|
|
|
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
|
|
|
PKG_SOURCE_URL:=@GNU/gmp
|
2008-06-22 18:41:09 +00:00
|
|
|
PKG_MD5SUM:=7ce52531644e6d12f16911b7e3151f3f
|
2006-09-07 12:42:27 +00:00
|
|
|
|
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
|
|
|
|
define Package/libgmp
|
|
|
|
SECTION:=libs
|
|
|
|
CATEGORY:=Libraries
|
|
|
|
TITLE:=GNU multiprecision arithmetic library
|
2008-06-22 18:41:09 +00: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 12:42:27 +00:00
|
|
|
endef
|
|
|
|
|
2007-02-25 23:34:57 +00:00
|
|
|
CONFIGURE_VARS += CC="$(TARGET_CROSS)gcc"
|
|
|
|
CONFIGURE_ARGS += \
|
|
|
|
--enable-shared \
|
|
|
|
--enable-static \
|
2006-09-07 12:42:27 +00:00
|
|
|
|
|
|
|
define Build/Compile
|
2006-09-23 13:27:50 +00:00
|
|
|
$(call Build/Compile/Default, \
|
|
|
|
DESTDIR="$(PKG_INSTALL_DIR)" \
|
2006-10-05 11:08:18 +00:00
|
|
|
CC="$(TARGET_CC)" \
|
2006-09-23 13:27:50 +00:00
|
|
|
all install \
|
|
|
|
)
|
2006-09-07 12:42:27 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Build/InstallDev
|
2007-09-28 01:45:11 +00: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 12:42:27 +00:00
|
|
|
endef
|
|
|
|
|
2006-09-23 13:27:50 +00:00
|
|
|
define Package/libgmp/install
|
2006-11-23 00:29:07 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
2006-09-23 13:27:50 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libgmp.so.* $(1)/usr/lib/
|
|
|
|
endef
|
|
|
|
|
2006-09-07 12:42:27 +00:00
|
|
|
$(eval $(call BuildPackage,libgmp))
|