[oe-commits] org.oe.dev libftdi: update to version 0.13
woglinde2 commit
oe at amethyst.openembedded.net
Fri Jul 18 12:57:31 UTC 2008
libftdi: update to version 0.13
*rewrite configure.ac and use rpath tools from gettext
*disable examples because of rpath issue needs more investigation
*doxygen is still disabled too
Author: woglinde2 at openembedded.org
Branch: org.openembedded.dev
Revision: 7ddcf7aeb14743db7aec16e7be026e81dd7d1b38
ViewMTN: http://monotone.openembedded.org/revision/info/7ddcf7aeb14743db7aec16e7be026e81dd7d1b38
Files:
1
packages/libftdi/libftdi-native_0.9.bb
packages/libftdi/libftdi-native_0.13.bb
packages/libftdi/libftdi_0.9.bb
packages/libftdi/libftdi_0.13.bb
packages/libftdi/files/autotools.patch
Diffs:
#
# mt diff -rddeae6e2f01db1e93d3e661840a4989d747bc1e0 -r7ddcf7aeb14743db7aec16e7be026e81dd7d1b38
#
#
#
# rename "packages/libftdi/libftdi-native_0.9.bb"
# to "packages/libftdi/libftdi-native_0.13.bb"
#
# rename "packages/libftdi/libftdi_0.9.bb"
# to "packages/libftdi/libftdi_0.13.bb"
#
# add_file "packages/libftdi/files/autotools.patch"
# content [34763077f48f126fe8a33bc3c7d33eaa7d4658c9]
#
# add_file "packages/libftdi/libftdi-native_0.9.bb"
# content [e606fa1e5a73fb6e4ac05018acff07c955ec7bbd]
#
# add_file "packages/libftdi/libftdi_0.9.bb"
# content [080df851d8fe425c65691b290fbe007211c4754f]
#
# patch "packages/libftdi/libftdi_0.13.bb"
# from [080df851d8fe425c65691b290fbe007211c4754f]
# to [e42e48562a25629f6524eae5f5d8e98f453a7a04]
#
============================================================
--- packages/libftdi/files/autotools.patch 34763077f48f126fe8a33bc3c7d33eaa7d4658c9
+++ packages/libftdi/files/autotools.patch 34763077f48f126fe8a33bc3c7d33eaa7d4658c9
@@ -0,0 +1,896 @@
+Index: libftdi-0.13/configure.ac
+===================================================================
+--- /dev/null 1970-01-01 00:00:00.000000000 +0000
++++ libftdi-0.13/configure.ac 2008-07-18 14:35:52.710117546 +0200
+@@ -0,0 +1,54 @@
++# -*- Autoconf -*-
++# Process this file with autoconf to produce a configure script.
++
++AC_PREREQ(2.61)
++AC_INIT([libftdi], [0.13])
++AM_INIT_AUTOMAKE
++AC_CONFIG_SRCDIR([config.h.in])
++AC_CONFIG_HEADER([config.h])
++
++AC_CONFIG_MACRO_DIR([m4])
++
++# Checks for programs.
++AC_PROG_CC
++AC_PROG_CPP
++AC_PROG_INSTALL
++AC_PROG_LN_S
++AC_PROG_MAKE_SET
++AC_PROG_RANLIB
++AM_PROG_LIBTOOL
++AC_LIB_RPATH
++AC_LIB_LINKFLAGS_FROM_LIBS
++
++# Checks for libraries.
++PKG_PROG_PKG_CONFIG
++PKG_CHECK_MODULES([LIBUSB],[libusb >= 0.1.7],,[AC_MSG_ERROR(libusb library not found.)])
++
++# Checks for header files.
++AC_HEADER_STDC
++AC_CHECK_HEADERS([stdlib.h string.h sys/ioctl.h sys/time.h unistd.h])
++
++# Checks for typedefs, structures, and compiler characteristics.
++AC_C_CONST
++AC_HEADER_TIME
++
++# Checks for library functions.
++AC_PROG_GCC_TRADITIONAL
++AC_FUNC_MALLOC
++AC_FUNC_MEMCMP
++AC_FUNC_REALLOC
++AC_FUNC_SELECT_ARGTYPES
++AC_CHECK_FUNCS([memmove memset select strtol])
++
++AC_CHECK_ENABLE_ASYNC_MODE
++AC_CHECK_ENABLE_DOCS
++
++AC_CONFIG_FILES([Makefile
++ libftdi-config
++ libftdi.pc
++ libftdi.spec
++ doc/Makefile
++ examples/Makefile
++ src/Makefile])
++AC_CONFIG_COMMANDS([default],[[chmod a+x libftdi-config]],[[]])
++AC_OUTPUT
+Index: libftdi-0.13/configure.in
+===================================================================
+--- libftdi-0.13.orig/configure.in 2008-06-13 10:28:54.000000000 +0200
++++ /dev/null 1970-01-01 00:00:00.000000000 +0000
+@@ -1,55 +0,0 @@
+-AC_INIT(configure.in)
+-
+-AM_CONFIG_HEADER(config.h)
+-AM_INIT_AUTOMAKE(libftdi, 0.13)
+-
+-AC_LANG_C
+-AC_PROG_CC
+-AM_PROG_LIBTOOL
+-
+-dnl check for libusb-config
+-AC_PATH_PROG(HAVELIBUSB, libusb-config, $PATH)
+-
+-if test ! -z "$HAVELIBUSB"; then
+- LIBUSB_CFLAGS=`$HAVELIBUSB --cflags`
+- LIBUSB_LIBS=`$HAVELIBUSB --libs`
+-
+- CFLAGS="$CFLAGS $LIBUSB_CFLAGS"
+- LIBS="$LIBS $LIBUSB_LIBS"
+-else
+- AC_MSG_ERROR([*** libusb-config not found. You need a working libusb installation.])
+-fi
+-
+-dnl check for version of libusb
+-AC_MSG_CHECKING([if libusb version is >= 0.1.7])
+-libusb_version_needed="1007"
+-libusb_version=`$HAVELIBUSB --version | sed -e "s/libusb //" | awk 'BEGIN { FS = "."; } { printf "%d", ($''1 * 1000 + $''2) * 1000 + $''3;}'`
+-
+-if test $libusb_version -lt $libusb_version_needed; then
+- AC_MSG_RESULT(no)
+- AC_MSG_ERROR([*** libusb is too old ($libusb_version). You need a libusb installation newer or equal to 0.1.7.])
+-else
+- AC_MSG_RESULT(yes)
+-fi
+-
+-ENABLE_ASYNC_MODE=0
+-AC_ARG_WITH(async-mode,
+-[ --with-async-mode enable experimental async mode. Linux only.],
+-[
+- AC_MSG_CHECKING(for experimental linux async mode)
+- if test "$withval" != "no"; then
+- ENABLE_ASYNC_MODE=1
+- CFLAGS="$CFLAGS -DLIBFTDI_LINUX_ASYNC_MODE"
+- AC_MSG_RESULT(yes)
+- else
+- AC_MSG_RESULT(no)
+- fi
+-])
+-AC_SUBST(ENABLE_ASYNC_MODE)
+-
+-dnl check for doxygen
+-AC_PATH_PROG(DOXYGEN, doxygen)
+-AM_CONDITIONAL(HAVE_DOXYGEN, test -n $DOXYGEN)
+-
+-AC_OUTPUT([libftdi-config],[chmod a+x libftdi-config])
+-AC_OUTPUT(Makefile src/Makefile examples/Makefile doc/Doxyfile doc/Makefile libftdi.pc libftdi.spec)
+Index: libftdi-0.13/m4/async.m4
+===================================================================
+--- /dev/null 1970-01-01 00:00:00.000000000 +0000
++++ libftdi-0.13/m4/async.m4 2008-07-18 14:35:52.710117546 +0200
+@@ -0,0 +1,17 @@
++AC_DEFUN([AC_CHECK_ENABLE_ASYNC_MODE],[
++AC_MSG_CHECKING([whether to compile with async-mode])
++ENABLE_ASYNC_MODE=0
++AC_ARG_WITH(async-mode,
++[ --with-async-mode enable experimental async mode. Linux only.],
++[
++ AC_MSG_CHECKING(for experimental linux async mode)
++ if test "$withval" != "no"; then
++ ENABLE_ASYNC_MODE=1
++ CFLAGS="$CFLAGS -DLIBFTDI_LINUX_ASYNC_MODE"
++ AC_MSG_RESULT(yes)
++ else
++ AC_MSG_RESULT(no)
++ fi
++])
++AC_SUBST(ENABLE_ASYNC_MODE)
++])
+Index: libftdi-0.13/m4/doxygen.m4
+===================================================================
+--- /dev/null 1970-01-01 00:00:00.000000000 +0000
++++ libftdi-0.13/m4/doxygen.m4 2008-07-18 14:35:52.710117546 +0200
+@@ -0,0 +1,11 @@
++AC_DEFUN([AC_CHECK_ENABLE_DOCS],[
++AC_MSG_CHECKING([whether to compile the docs])
++AC_ARG_ENABLE([docs],
++[ --enable-docs Turn on debugging],
++[case "${enableval}" in
++ yes) AC_PATH_PROG(DOXYGEN, doxygen);;
++ no) ;;
++ *) AC_MSG_ERROR([bad value ${enableval} for --enable-docs]) ;;
++esac],[DOXYGEN=""])
++AM_CONDITIONAL([HAVE_DOXYGEN], [test -n $DOXYGENx])
++])
+Index: libftdi-0.13/Makefile.am
+===================================================================
+--- libftdi-0.13.orig/Makefile.am 2008-06-13 10:28:54.000000000 +0200
++++ libftdi-0.13/Makefile.am 2008-07-18 14:36:25.160089170 +0200
+@@ -2,7 +2,9 @@
+ # have all needed files, that a GNU package needs
+ AUTOMAKE_OPTIONS = foreign 1.4
+
+-SUBDIRS = src examples doc
++ACLOCAL_AMFLAGS = -I m4
++
++SUBDIRS = src doc
+
+ EXTRA_DIST = libftdi.spec libftdi.spec.in COPYING.LIB README AUTHORS ChangeLog libftdi-config.in
+
+Index: libftdi-0.13/m4/lib-link.m4
+===================================================================
+--- /dev/null 1970-01-01 00:00:00.000000000 +0000
++++ libftdi-0.13/m4/lib-link.m4 2008-07-18 14:35:52.713438346 +0200
+@@ -0,0 +1,709 @@
++# lib-link.m4 serial 13 (gettext-0.17)
++dnl Copyright (C) 2001-2007 Free Software Foundation, Inc.
++dnl This file is free software; the Free Software Foundation
++dnl gives unlimited permission to copy and/or distribute it,
++dnl with or without modifications, as long as this notice is preserved.
++
++dnl From Bruno Haible.
++
++AC_PREREQ(2.54)
++
++dnl AC_LIB_LINKFLAGS(name [, dependencies]) searches for libname and
++dnl the libraries corresponding to explicit and implicit dependencies.
++dnl Sets and AC_SUBSTs the LIB${NAME} and LTLIB${NAME} variables and
++dnl augments the CPPFLAGS variable.
++dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname
++dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
++AC_DEFUN([AC_LIB_LINKFLAGS],
++[
++ AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
++ AC_REQUIRE([AC_LIB_RPATH])
++ define([Name],[translit([$1],[./-], [___])])
++ define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
++ AC_CACHE_CHECK([how to link with lib[]$1], [ac_cv_lib[]Name[]_libs], [
++ AC_LIB_LINKFLAGS_BODY([$1], [$2])
++ ac_cv_lib[]Name[]_libs="$LIB[]NAME"
++ ac_cv_lib[]Name[]_ltlibs="$LTLIB[]NAME"
++ ac_cv_lib[]Name[]_cppflags="$INC[]NAME"
++ ac_cv_lib[]Name[]_prefix="$LIB[]NAME[]_PREFIX"
++ ])
++ LIB[]NAME="$ac_cv_lib[]Name[]_libs"
++ LTLIB[]NAME="$ac_cv_lib[]Name[]_ltlibs"
++ INC[]NAME="$ac_cv_lib[]Name[]_cppflags"
++ LIB[]NAME[]_PREFIX="$ac_cv_lib[]Name[]_prefix"
++ AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
++ AC_SUBST([LIB]NAME)
++ AC_SUBST([LTLIB]NAME)
++ AC_SUBST([LIB]NAME[_PREFIX])
++ dnl Also set HAVE_LIB[]NAME so that AC_LIB_HAVE_LINKFLAGS can reuse the
++ dnl results of this search when this library appears as a dependency.
++ HAVE_LIB[]NAME=yes
++ undefine([Name])
++ undefine([NAME])
++])
++
++dnl AC_LIB_HAVE_LINKFLAGS(name, dependencies, includes, testcode)
++dnl searches for libname and the libraries corresponding to explicit and
++dnl implicit dependencies, together with the specified include files and
++dnl the ability to compile and link the specified testcode. If found, it
++dnl sets and AC_SUBSTs HAVE_LIB${NAME}=yes and the LIB${NAME} and
++dnl LTLIB${NAME} variables and augments the CPPFLAGS variable, and
++dnl #defines HAVE_LIB${NAME} to 1. Otherwise, it sets and AC_SUBSTs
++dnl HAVE_LIB${NAME}=no and LIB${NAME} and LTLIB${NAME} to empty.
++dnl Sets and AC_SUBSTs the LIB${NAME}_PREFIX variable to nonempty if libname
++dnl was found in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
++AC_DEFUN([AC_LIB_HAVE_LINKFLAGS],
++[
++ AC_REQUIRE([AC_LIB_PREPARE_PREFIX])
++ AC_REQUIRE([AC_LIB_RPATH])
++ define([Name],[translit([$1],[./-], [___])])
++ define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
++
++ dnl Search for lib[]Name and define LIB[]NAME, LTLIB[]NAME and INC[]NAME
++ dnl accordingly.
++ AC_LIB_LINKFLAGS_BODY([$1], [$2])
++
++ dnl Add $INC[]NAME to CPPFLAGS before performing the following checks,
++ dnl because if the user has installed lib[]Name and not disabled its use
++ dnl via --without-lib[]Name-prefix, he wants to use it.
++ ac_save_CPPFLAGS="$CPPFLAGS"
++ AC_LIB_APPENDTOVAR([CPPFLAGS], [$INC]NAME)
++
++ AC_CACHE_CHECK([for lib[]$1], [ac_cv_lib[]Name], [
++ ac_save_LIBS="$LIBS"
++ LIBS="$LIBS $LIB[]NAME"
++ AC_TRY_LINK([$3], [$4], [ac_cv_lib[]Name=yes], [ac_cv_lib[]Name=no])
++ LIBS="$ac_save_LIBS"
++ ])
++ if test "$ac_cv_lib[]Name" = yes; then
++ HAVE_LIB[]NAME=yes
++ AC_DEFINE([HAVE_LIB]NAME, 1, [Define if you have the $1 library.])
++ AC_MSG_CHECKING([how to link with lib[]$1])
++ AC_MSG_RESULT([$LIB[]NAME])
++ else
++ HAVE_LIB[]NAME=no
++ dnl If $LIB[]NAME didn't lead to a usable library, we don't need
++ dnl $INC[]NAME either.
++ CPPFLAGS="$ac_save_CPPFLAGS"
++ LIB[]NAME=
++ LTLIB[]NAME=
++ LIB[]NAME[]_PREFIX=
++ fi
++ AC_SUBST([HAVE_LIB]NAME)
++ AC_SUBST([LIB]NAME)
++ AC_SUBST([LTLIB]NAME)
++ AC_SUBST([LIB]NAME[_PREFIX])
++ undefine([Name])
++ undefine([NAME])
++])
++
++dnl Determine the platform dependent parameters needed to use rpath:
++dnl acl_libext,
++dnl acl_shlibext,
++dnl acl_hardcode_libdir_flag_spec,
++dnl acl_hardcode_libdir_separator,
++dnl acl_hardcode_direct,
++dnl acl_hardcode_minus_L.
++AC_DEFUN([AC_LIB_RPATH],
++[
++ dnl Tell automake >= 1.10 to complain if config.rpath is missing.
++ m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([config.rpath])])
++ AC_REQUIRE([AC_PROG_CC]) dnl we use $CC, $GCC, $LDFLAGS
++ AC_REQUIRE([AC_LIB_PROG_LD]) dnl we use $LD, $with_gnu_ld
++ AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use $host
++ AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT]) dnl we use $ac_aux_dir
++ AC_CACHE_CHECK([for shared library run path origin], acl_cv_rpath, [
++ CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
++ ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
++ . ./conftest.sh
++ rm -f ./conftest.sh
++ acl_cv_rpath=done
++ ])
++ wl="$acl_cv_wl"
++ acl_libext="$acl_cv_libext"
++ acl_shlibext="$acl_cv_shlibext"
++ acl_libname_spec="$acl_cv_libname_spec"
++ acl_library_names_spec="$acl_cv_library_names_spec"
++ acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
++ acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
++ acl_hardcode_direct="$acl_cv_hardcode_direct"
++ acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
++ dnl Determine whether the user wants rpath handling at all.
++ AC_ARG_ENABLE(rpath,
++ [ --disable-rpath do not hardcode runtime library paths],
++ :, enable_rpath=yes)
++])
++
++dnl AC_LIB_LINKFLAGS_BODY(name [, dependencies]) searches for libname and
++dnl the libraries corresponding to explicit and implicit dependencies.
++dnl Sets the LIB${NAME}, LTLIB${NAME} and INC${NAME} variables.
++dnl Also, sets the LIB${NAME}_PREFIX variable to nonempty if libname was found
++dnl in ${LIB${NAME}_PREFIX}/$acl_libdirstem.
++AC_DEFUN([AC_LIB_LINKFLAGS_BODY],
++[
++ AC_REQUIRE([AC_LIB_PREPARE_MULTILIB])
++ define([NAME],[translit([$1],[abcdefghijklmnopqrstuvwxyz./-],
++ [ABCDEFGHIJKLMNOPQRSTUVWXYZ___])])
++ dnl Autoconf >= 2.61 supports dots in --with options.
++ define([N_A_M_E],[m4_if(m4_version_compare(m4_defn([m4_PACKAGE_VERSION]),[2.61]),[-1],[translit([$1],[.],[_])],[$1])])
++ dnl By default, look in $includedir and $libdir.
++ use_additional=yes
++ AC_LIB_WITH_FINAL_PREFIX([
++ eval additional_includedir=\"$includedir\"
++ eval additional_libdir=\"$libdir\"
++ ])
++ AC_LIB_ARG_WITH([lib]N_A_M_E[-prefix],
++[ --with-lib]N_A_M_E[-prefix[=DIR] search for lib$1 in DIR/include and DIR/lib
++ --without-lib]N_A_M_E[-prefix don't search for lib$1 in includedir and libdir],
++[
++ if test "X$withval" = "Xno"; then
++ use_additional=no
++ else
++ if test "X$withval" = "X"; then
++ AC_LIB_WITH_FINAL_PREFIX([
++ eval additional_includedir=\"$includedir\"
++ eval additional_libdir=\"$libdir\"
++ ])
++ else
++ additional_includedir="$withval/include"
++ additional_libdir="$withval/$acl_libdirstem"
++ fi
++ fi
++])
++ dnl Search the library and its dependencies in $additional_libdir and
++ dnl $LDFLAGS. Using breadth-first-seach.
++ LIB[]NAME=
++ LTLIB[]NAME=
++ INC[]NAME=
++ LIB[]NAME[]_PREFIX=
++ rpathdirs=
++ ltrpathdirs=
++ names_already_handled=
++ names_next_round='$1 $2'
++ while test -n "$names_next_round"; do
++ names_this_round="$names_next_round"
++ names_next_round=
++ for name in $names_this_round; do
++ already_handled=
++ for n in $names_already_handled; do
++ if test "$n" = "$name"; then
++ already_handled=yes
++ break
++ fi
++ done
++ if test -z "$already_handled"; then
++ names_already_handled="$names_already_handled $name"
++ dnl See if it was already located by an earlier AC_LIB_LINKFLAGS
++ dnl or AC_LIB_HAVE_LINKFLAGS call.
++ uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
++ eval value=\"\$HAVE_LIB$uppername\"
++ if test -n "$value"; then
++ if test "$value" = yes; then
++ eval value=\"\$LIB$uppername\"
++ test -z "$value" || LIB[]NAME="${LIB[]NAME}${LIB[]NAME:+ }$value"
++ eval value=\"\$LTLIB$uppername\"
++ test -z "$value" || LTLIB[]NAME="${LTLIB[]NAME}${LTLIB[]NAME:+ }$value"
++ else
++ dnl An earlier call to AC_LIB_HAVE_LINKFLAGS has determined
++ dnl that this library doesn't exist. So just drop it.
++ :
++ fi
++ else
++ dnl Search the library lib$name in $additional_libdir and $LDFLAGS
++ dnl and the already constructed $LIBNAME/$LTLIBNAME.
++ found_dir=
++ found_la=
++ found_so=
++ found_a=
++ eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
++ if test -n "$acl_shlibext"; then
++ shrext=".$acl_shlibext" # typically: shrext=.so
++ else
++ shrext=
++ fi
++ if test $use_additional = yes; then
++ dir="$additional_libdir"
++ dnl The same code as in the loop below:
++ dnl First look for a shared library.
++ if test -n "$acl_shlibext"; then
++ if test -f "$dir/$libname$shrext"; then
++ found_dir="$dir"
++ found_so="$dir/$libname$shrext"
++ else
++ if%s
>>> DIFF TRUNCATED @ 16K
More information about the Openembedded-commits
mailing list