diff options
| -rw-r--r-- | meta/recipes-devtools/e2fsprogs/e2fsprogs/acinclude.m4 | 53 |
1 files changed, 51 insertions, 2 deletions
diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs/acinclude.m4 b/meta/recipes-devtools/e2fsprogs/e2fsprogs/acinclude.m4 index 4b00668476..c0bd7dbdee 100644 --- a/meta/recipes-devtools/e2fsprogs/e2fsprogs/acinclude.m4 +++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs/acinclude.m4 | |||
| @@ -1,7 +1,56 @@ | |||
| 1 | # Extracted from the package's shipped aclocal.m4. Custom macros should be in | 1 | # Extracted from the package's shipped aclocal.m4. Custom macros should be in |
| 2 | # acinclude.m4 so running aclocal doesn't blow them away. | 2 | # acinclude.m4 so running aclocal doesn't blow them away. |
| 3 | # | 3 | # |
| 4 | # RP 1/6/2010 | 4 | # Signed-off-by: Ross Burton <ross.burton@intel.com> |
| 5 | |||
| 6 | # from http://autoconf-archive.cryp.to/ax_tls.html | ||
| 7 | # | ||
| 8 | # This was licensed under the GPL with the following exception: | ||
| 9 | # | ||
| 10 | # As a special exception, the respective Autoconf Macro's copyright | ||
| 11 | # owner gives unlimited permission to copy, distribute and modify the | ||
| 12 | # configure scripts that are the output of Autoconf when processing | ||
| 13 | # the Macro. You need not follow the terms of the GNU General Public | ||
| 14 | # License when using or distributing such scripts, even though | ||
| 15 | # portions of the text of the Macro appear in them. The GNU General | ||
| 16 | # Public License (GPL) does govern all other use of the material that | ||
| 17 | # constitutes the Autoconf Macro. | ||
| 18 | # | ||
| 19 | # This special exception to the GPL applies to versions of the | ||
| 20 | # Autoconf Macro released by the Autoconf Macro Archive. When you make | ||
| 21 | # and distribute a modified version of the Autoconf Macro, you may | ||
| 22 | # extend this special exception to the GPL to apply to your modified | ||
| 23 | # version as well. | ||
| 24 | # | ||
| 25 | AC_DEFUN([AX_TLS], [ | ||
| 26 | AC_MSG_CHECKING(for thread local storage (TLS) class) | ||
| 27 | AC_CACHE_VAL(ac_cv_tls, [ | ||
| 28 | ax_tls_keywords="__thread __declspec(thread) none" | ||
| 29 | for ax_tls_keyword in $ax_tls_keywords; do | ||
| 30 | case $ax_tls_keyword in | ||
| 31 | none) ac_cv_tls=none ; break ;; | ||
| 32 | *) | ||
| 33 | AC_TRY_COMPILE( | ||
| 34 | [#include <stdlib.h> | ||
| 35 | static void | ||
| 36 | foo(void) { | ||
| 37 | static ] $ax_tls_keyword [ int bar; | ||
| 38 | exit(1); | ||
| 39 | }], | ||
| 40 | [], | ||
| 41 | [ac_cv_tls=$ax_tls_keyword ; break], | ||
| 42 | ac_cv_tls=none | ||
| 43 | ) | ||
| 44 | esac | ||
| 45 | done | ||
| 46 | ]) | ||
| 47 | |||
| 48 | if test "$ac_cv_tls" != "none"; then | ||
| 49 | dnl AC_DEFINE([TLS], [], [If the compiler supports a TLS storage class define it to that here]) | ||
| 50 | AC_DEFINE_UNQUOTED([TLS], $ac_cv_tls, [If the compiler supports a TLS storage class define it to that here]) | ||
| 51 | fi | ||
| 52 | AC_MSG_RESULT($ac_cv_tls) | ||
| 53 | ]) | ||
| 5 | 54 | ||
| 6 | # =========================================================================== | 55 | # =========================================================================== |
| 7 | # http://www.nongnu.org/autoconf-archive/check_gnu_make.html | 56 | # http://www.nongnu.org/autoconf-archive/check_gnu_make.html |
