-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add webos-gmp: gmp 4.2.1 for target only
- Loading branch information
1 parent
e71537d
commit f681c02
Showing
25 changed files
with
172 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
Upstream-Status: Pending | ||
|
||
# "extern inline" in traditional gcc means that the function should be | ||
# inlined wherever it's seen, while in C99, "extern inline" means that i | ||
# the function should only be inlined where the inline definition is | ||
# seen while in other places it's not inlined: | ||
# http://gcc.gnu.org/ml/gcc/2006-11/msg00006.html | ||
# | ||
# gmp checks "--std=gnu99" to use C99 convention however it internally | ||
# defines some "extern inline" functions in gmp.h, which is included | ||
# by mainly .c files and finally lead a flood of redefinition function | ||
# errors when linking objects together. | ||
# | ||
# So disable C99/ANSI detection to stick to tranditional gcc behavior | ||
# | ||
# by Kevin Tian <kevin.tian@intel.com>, 2010-08-13 | ||
# | ||
# (this patch is licensed under GPLv2+) | ||
|
||
diff --git a/configure.in b/configure.in | ||
index 450cc92..aab0b59 100644 | ||
--- a/configure.in | ||
+++ b/configure.in | ||
@@ -1869,9 +1869,7 @@ AC_SUBST(DEFN_LONG_LONG_LIMB) | ||
|
||
# The C compiler and preprocessor, put into ANSI mode if possible. | ||
AC_PROG_CC | ||
-AC_PROG_CC_STDC | ||
AC_PROG_CPP | ||
-GMP_H_ANSI | ||
|
||
|
||
# The C compiler on the build system, and associated tests. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
Upstream-Status: Pending | ||
|
||
automake 1.12 has depricated automatic de-ANSI-fication support | ||
|
||
this patch avoids these kinds of errors: | ||
|
||
| configure.in:2240: error: automatic de-ANSI-fication support has been removed | ||
| Makefile.am:28: error: automatic de-ANSI-fication support has been removed | ||
|
||
Signed-Off-By: Nitin A Kamble <nitin.a.kamble@intel.com> | ||
2012/05/02 | ||
|
||
Index: gmp-4.2.1/configure.in | ||
=================================================================== | ||
--- gmp-4.2.1.orig/configure.in | ||
+++ gmp-4.2.1/configure.in | ||
@@ -67,7 +67,7 @@ dnl | ||
dnl Note that there's a copy of these options in the top-level Makefile.am, | ||
dnl so update there too if changing anything. | ||
dnl | ||
-AM_INIT_AUTOMAKE([1.8 gnu no-dependencies $(top_builddir)/ansi2knr]) | ||
+AM_INIT_AUTOMAKE([1.8 gnu no-dependencies]) | ||
AM_CONFIG_HEADER(config.h:config.in) | ||
AM_MAINTAINER_MODE | ||
|
||
@@ -2022,9 +2022,6 @@ fi | ||
echo " MPN_PATH=\"$path\"" | ||
|
||
|
||
-# Automake ansi2knr support. | ||
-AM_C_PROTOTYPES | ||
- | ||
GMP_PROG_AR | ||
GMP_PROG_NM | ||
|
||
Index: gmp-4.2.1/Makefile.am | ||
=================================================================== | ||
--- gmp-4.2.1.orig/Makefile.am | ||
+++ gmp-4.2.1/Makefile.am | ||
@@ -27,7 +27,7 @@ | ||
# Makefiles in subdirectories, but here we must omit it so automake gives | ||
# the actual ansi2knr build rule, not "cd $(top_builddir) && make ansi2knr". | ||
# | ||
-AUTOMAKE_OPTIONS = 1.8 gnu no-dependencies ansi2knr | ||
+AUTOMAKE_OPTIONS = 1.8 gnu no-dependencies | ||
|
||
|
||
# Libtool -version-info for libgmp.la and libmp.la. See "Versioning" in the |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
This change was extracted from gmp 4.2.2 (2007-09-03) | ||
|
||
From Richard Guenther: | ||
* gmp-h.in (__GMP_EXTERN_INLINE): Declare conditionally on | ||
__GNUC_STDC_INLINE__. | ||
|
||
Index: gmp-4.2.1/gmp-h.in | ||
=================================================================== | ||
--- gmp-4.2.1.orig/gmp-h.in 2006-04-11 11:10:15.000000000 -0700 | ||
+++ gmp-4.2.1/gmp-h.in 2013-11-24 17:21:12.807735622 -0800 | ||
@@ -418,9 +418,15 @@ | ||
|
||
/* gcc has __inline__ in all modes, including strict ansi. Give a prototype | ||
for an inline too, so as to correctly specify "dllimport" on windows, in | ||
- case the function is called rather than inlined. */ | ||
+ case the function is called rather than inlined. | ||
+ GCC 4.3 and above with -std=c99 or -std=gnu99 implements ISO C99 | ||
+ inline semantics, unless -fgnu89-inline is used. */ | ||
#ifdef __GNUC__ | ||
+#ifdef __GNUC_STDC_INLINE__ | ||
+#define __GMP_EXTERN_INLINE extern __inline__ __attribute__ ((__gnu_inline__)) | ||
+#else | ||
#define __GMP_EXTERN_INLINE extern __inline__ | ||
+#endif | ||
#define __GMP_INLINE_PROTOTYPES 1 | ||
#endif | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
config BR2_PACKAGE_WEBOS_GMP | ||
bool "gmp 4.2.1 (shared only)" | ||
depends on BR2_WEBOS_COMPAT | ||
depends on BR2_PACKAGE_GMP | ||
help | ||
The version of gmp used on webOS (up through at least | ||
webOS 8). | ||
|
||
This replaces the normal buildroot gmp on the target (but not | ||
host). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Locally calculated | ||
sha256 d07ffcb37eecec35c5ec72516d10b35fdf6e6fef1fcf1dcd37e30b8cbf8bf941 gmp-4.2.1.tar.bz2 | ||
|
||
# Locally calculated | ||
sha256 ddb9db7630752f8fdc6898f7c99a99eaeeac5213627ecb093df9c82f56175dc7 COPYING | ||
sha256 5df07007198989c622f5d41de8d703e7bef3d0e79d62e24332ee739a452af62a COPYING.LIB |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
################################################################################ | ||
# | ||
# webos-gmp | ||
# | ||
################################################################################ | ||
|
||
WEBOS_GMP_VERSION = 4.2.1 | ||
WEBOS_GMP_SITE = $(BR2_GNU_MIRROR)/gmp | ||
WEBOS_GMP_SOURCE = gmp-$(WEBOS_GMP_VERSION).tar.bz2 | ||
WEBOS_GMP_INSTALL_STAGING = YES | ||
WEBOS_GMP_LICENSE = LGPL-2.1+ or GPL-2.0+ | ||
WEBOS_GMP_LICENSE_FILES = COPYING.LIB COPYING | ||
WEBOS_GMP_CPE_ID_VENDOR = gmplib | ||
WEBOS_GMP_DEPENDENCIES = host-m4 | ||
|
||
# 0001-mpz-inp_raw.c-Avoid-bit-size-overflows.patch | ||
WEBOS_GMP_IGNORE_CVES += CVE-2021-43618 | ||
|
||
ifeq ($(BR2_INSTALL_LIBSTDCPP),y) | ||
WEBOS_GMP_CONF_OPTS += --enable-cxx | ||
else | ||
WEBOS_GMP_CONF_OPTS += --disable-cxx | ||
endif | ||
|
||
$(eval $(autotools-package)) |