diff options
| author | Holger Weiss <holger@zedat.fu-berlin.de> | 2013-08-19 23:27:12 +0200 |
|---|---|---|
| committer | Holger Weiss <holger@zedat.fu-berlin.de> | 2013-08-19 23:27:12 +0200 |
| commit | 26fbe7f1e68bb0c96da32491efcf3696fe6c299b (patch) | |
| tree | c4d95289187a64e9c7517bf73d8208026c3d2fb3 /gl/m4/asm-underscore.m4 | |
| parent | 5f79e3e9f62ca5487d9881973149136ba1d19d3e (diff) | |
| download | monitoring-plugins-26fbe7f1e68bb0c96da32491efcf3696fe6c299b.tar.gz | |
Sync with the latest Gnulib code (6f2d632)
Diffstat (limited to 'gl/m4/asm-underscore.m4')
| -rw-r--r-- | gl/m4/asm-underscore.m4 | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/gl/m4/asm-underscore.m4 b/gl/m4/asm-underscore.m4 deleted file mode 100644 index 1736cc43..00000000 --- a/gl/m4/asm-underscore.m4 +++ /dev/null | |||
| @@ -1,48 +0,0 @@ | |||
| 1 | # asm-underscore.m4 serial 1 | ||
| 2 | dnl Copyright (C) 2010 Free Software Foundation, Inc. | ||
| 3 | dnl This file is free software; the Free Software Foundation | ||
| 4 | dnl gives unlimited permission to copy and/or distribute it, | ||
| 5 | dnl with or without modifications, as long as this notice is preserved. | ||
| 6 | |||
| 7 | dnl From Bruno Haible. Based on as-underscore.m4 in GNU clisp. | ||
| 8 | |||
| 9 | # gl_ASM_SYMBOL_PREFIX | ||
| 10 | # Tests for the prefix of C symbols at the assembly language level and the | ||
| 11 | # linker level. This prefix is either an underscore or empty. Defines the | ||
| 12 | # C macro USER_LABEL_PREFIX to this prefix, and sets ASM_SYMBOL_PREFIX to | ||
| 13 | # a stringified variant of this prefix. | ||
| 14 | |||
| 15 | AC_DEFUN([gl_ASM_SYMBOL_PREFIX], | ||
| 16 | [ | ||
| 17 | dnl We don't use GCC's __USER_LABEL_PREFIX__ here, because | ||
| 18 | dnl 1. It works only for GCC. | ||
| 19 | dnl 2. It is incorrectly defined on some platforms, in some GCC versions. | ||
| 20 | AC_CACHE_CHECK( | ||
| 21 | [whether C symbols are prefixed with underscore at the linker level], | ||
| 22 | [gl_cv_prog_as_underscore], | ||
| 23 | [cat > conftest.c <<EOF | ||
| 24 | #ifdef __cplusplus | ||
| 25 | extern "C" int foo (void); | ||
| 26 | #endif | ||
| 27 | int foo(void) { return 0; } | ||
| 28 | EOF | ||
| 29 | # Look for the assembly language name in the .s file. | ||
| 30 | AC_TRY_COMMAND(${CC-cc} $CFLAGS $CPPFLAGS -S conftest.c) >/dev/null 2>&1 | ||
| 31 | if grep _foo conftest.s >/dev/null ; then | ||
| 32 | gl_cv_prog_as_underscore=yes | ||
| 33 | else | ||
| 34 | gl_cv_prog_as_underscore=no | ||
| 35 | fi | ||
| 36 | rm -f conftest* | ||
| 37 | ]) | ||
| 38 | if test $gl_cv_prog_as_underscore = yes; then | ||
| 39 | USER_LABEL_PREFIX=_ | ||
| 40 | else | ||
| 41 | USER_LABEL_PREFIX= | ||
| 42 | fi | ||
| 43 | AC_DEFINE_UNQUOTED([USER_LABEL_PREFIX], [$USER_LABEL_PREFIX], | ||
| 44 | [Define to the prefix of C symbols at the assembler and linker level, | ||
| 45 | either an underscore or empty.]) | ||
| 46 | ASM_SYMBOL_PREFIX='"'${USER_LABEL_PREFIX}'"' | ||
| 47 | AC_SUBST([ASM_SYMBOL_PREFIX]) | ||
| 48 | ]) | ||
