~ubuntu-branches/ubuntu/natty/avahi/natty

« back to all changes in this revision

Viewing changes to common/lib-prefix.m4

  • Committer: Bazaar Package Importer
  • Author(s): Colin Watson
  • Date: 2010-12-06 15:31:58 UTC
  • mfrom: (4.1.16 experimental)
  • Revision ID: james.westby@ubuntu.com-20101206153158-et2wuk7kftodlc8b
Tags: 0.6.28-2ubuntu1
* Resynchronise with Debian.  Remaining changes:
  - debian/control:
    + Add versioned dependency on the dbus that satisfies our upstart job
      dependency.
    + Add udebs corresponding to libavahi-common3 and libavahi-core6, so
      that we can use them for Eucalyptus integration in the installer.
  - debian/rules, debian/avahi-daemon.init, debian/avahi-dnsconfd.init:
    + Avahi init scripts (daemon or dnsconfd) do not need to be started
      before gdm, and do not need to be stopped specially on shutdown.
  - debian/avahi-daemon.upstart, debian/avahi-dnsconfd.upstart:
    + Add Upstart config
* Restore Debian changes to migrate to DHCP 4, now that we have it in
  Ubuntu.  Adjust package versions for conffile migration.
* Launchpad supports 'linux-any' these days; restore Debian change to use
  that.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# lib-prefix.m4 serial 5 (gettext-0.15)
2
 
dnl Copyright (C) 2001-2005 Free Software Foundation, Inc.
 
1
# lib-prefix.m4 serial 7 (gettext-0.18)
 
2
dnl Copyright (C) 2001-2005, 2008-2010 Free Software Foundation, Inc.
3
3
dnl This file is free software; the Free Software Foundation
4
4
dnl gives unlimited permission to copy and/or distribute it,
5
5
dnl with or without modifications, as long as this notice is preserved.
153
153
  prefix="$acl_save_prefix"
154
154
])
155
155
 
156
 
dnl AC_LIB_PREPARE_MULTILIB creates a variable acl_libdirstem, containing
157
 
dnl the basename of the libdir, either "lib" or "lib64".
 
156
dnl AC_LIB_PREPARE_MULTILIB creates
 
157
dnl - a variable acl_libdirstem, containing the basename of the libdir, either
 
158
dnl   "lib" or "lib64" or "lib/64",
 
159
dnl - a variable acl_libdirstem2, as a secondary possible value for
 
160
dnl   acl_libdirstem, either the same as acl_libdirstem or "lib/sparcv9" or
 
161
dnl   "lib/amd64".
158
162
AC_DEFUN([AC_LIB_PREPARE_MULTILIB],
159
163
[
160
 
  dnl There is no formal standard regarding lib and lib64. The current
161
 
  dnl practice is that on a system supporting 32-bit and 64-bit instruction
162
 
  dnl sets or ABIs, 64-bit libraries go under $prefix/lib64 and 32-bit
163
 
  dnl libraries go under $prefix/lib. We determine the compiler's default
164
 
  dnl mode by looking at the compiler's library search path. If at least
165
 
  dnl of its elements ends in /lib64 or points to a directory whose absolute
166
 
  dnl pathname ends in /lib64, we assume a 64-bit ABI. Otherwise we use the
167
 
  dnl default, namely "lib".
 
164
  dnl There is no formal standard regarding lib and lib64.
 
165
  dnl On glibc systems, the current practice is that on a system supporting
 
166
  dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under
 
167
  dnl $prefix/lib64 and 32-bit libraries go under $prefix/lib. We determine
 
168
  dnl the compiler's default mode by looking at the compiler's library search
 
169
  dnl path. If at least one of its elements ends in /lib64 or points to a
 
170
  dnl directory whose absolute pathname ends in /lib64, we assume a 64-bit ABI.
 
171
  dnl Otherwise we use the default, namely "lib".
 
172
  dnl On Solaris systems, the current practice is that on a system supporting
 
173
  dnl 32-bit and 64-bit instruction sets or ABIs, 64-bit libraries go under
 
174
  dnl $prefix/lib/64 (which is a symlink to either $prefix/lib/sparcv9 or
 
175
  dnl $prefix/lib/amd64) and 32-bit libraries go under $prefix/lib.
 
176
  AC_REQUIRE([AC_CANONICAL_HOST])
168
177
  acl_libdirstem=lib
169
 
  searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
170
 
  if test -n "$searchpath"; then
171
 
    acl_save_IFS="${IFS=        }"; IFS=":"
172
 
    for searchdir in $searchpath; do
173
 
      if test -d "$searchdir"; then
174
 
        case "$searchdir" in
175
 
          */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
176
 
          *) searchdir=`cd "$searchdir" && pwd`
177
 
             case "$searchdir" in
178
 
               */lib64 ) acl_libdirstem=lib64 ;;
179
 
             esac ;;
 
178
  acl_libdirstem2=
 
179
  case "$host_os" in
 
180
    solaris*)
 
181
      dnl See Solaris 10 Software Developer Collection > Solaris 64-bit Developer's Guide > The Development Environment
 
182
      dnl <http://docs.sun.com/app/docs/doc/816-5138/dev-env?l=en&a=view>.
 
183
      dnl "Portable Makefiles should refer to any library directories using the 64 symbolic link."
 
184
      dnl But we want to recognize the sparcv9 or amd64 subdirectory also if the
 
185
      dnl symlink is missing, so we set acl_libdirstem2 too.
 
186
      AC_CACHE_CHECK([for 64-bit host], [gl_cv_solaris_64bit],
 
187
        [AC_EGREP_CPP([sixtyfour bits], [
 
188
#ifdef _LP64
 
189
sixtyfour bits
 
190
#endif
 
191
           ], [gl_cv_solaris_64bit=yes], [gl_cv_solaris_64bit=no])
 
192
        ])
 
193
      if test $gl_cv_solaris_64bit = yes; then
 
194
        acl_libdirstem=lib/64
 
195
        case "$host_cpu" in
 
196
          sparc*)        acl_libdirstem2=lib/sparcv9 ;;
 
197
          i*86 | x86_64) acl_libdirstem2=lib/amd64 ;;
180
198
        esac
181
199
      fi
182
 
    done
183
 
    IFS="$acl_save_IFS"
184
 
  fi
 
200
      ;;
 
201
    *)
 
202
      searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
 
203
      if test -n "$searchpath"; then
 
204
        acl_save_IFS="${IFS=    }"; IFS=":"
 
205
        for searchdir in $searchpath; do
 
206
          if test -d "$searchdir"; then
 
207
            case "$searchdir" in
 
208
              */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
 
209
              */../ | */.. )
 
210
                # Better ignore directories of this form. They are misleading.
 
211
                ;;
 
212
              *) searchdir=`cd "$searchdir" && pwd`
 
213
                 case "$searchdir" in
 
214
                   */lib64 ) acl_libdirstem=lib64 ;;
 
215
                 esac ;;
 
216
            esac
 
217
          fi
 
218
        done
 
219
        IFS="$acl_save_IFS"
 
220
      fi
 
221
      ;;
 
222
  esac
 
223
  test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
185
224
])