diff --git a/libffi/ChangeLog.libffi b/libffi/ChangeLog.libffi index 03f40f51..5b4b6677 100644 --- a/libffi/ChangeLog.libffi +++ b/libffi/ChangeLog.libffi @@ -1,3 +1,13 @@ +2008-02-14 Anthony Green + + * include/Makefile.am (includesdir): Install headers under libdir. + (pkgconfigdir): Define. Install libffi.pc. + * include/Makefile.in: Rebuilt. + * libffi.pc.in: Create. + * libtool-version: Increment CURRENT + * configure.ac: Add libffi.pc.in + * configure: Rebuilt. + 2008-02-03 Anthony Green * include/Makefile.am (includesdir): Fix header install with diff --git a/libffi/Makefile.am b/libffi/Makefile.am index e64ec9ce..4d30ce69 100644 --- a/libffi/Makefile.am +++ b/libffi/Makefile.am @@ -83,6 +83,9 @@ libffi_la_SOURCES = src/debug.c src/prep_cif.c src/types.c \ src/raw_api.c src/java_raw_api.c src/closures.c # include/ffi_common.h include/ffitarget.h +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = libffi.pc + nodist_libffi_la_SOURCES = if MIPS diff --git a/libffi/Makefile.in b/libffi/Makefile.in index fe22db71..5c3e8923 100644 --- a/libffi/Makefile.in +++ b/libffi/Makefile.in @@ -14,6 +14,7 @@ @SET_MAKE@ + VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ @@ -58,9 +59,10 @@ target_triplet = @target@ subdir = . DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in $(srcdir)/fficonfig.h.in \ - $(top_srcdir)/configure ChangeLog compile config.guess \ - config.sub depcomp install-sh ltcf-c.sh ltcf-cxx.sh \ - ltcf-gcj.sh ltconfig ltmain.sh missing mkinstalldirs + $(srcdir)/libffi.pc.in $(top_srcdir)/configure ChangeLog TODO \ + compile config.guess config.sub depcomp install-sh ltcf-c.sh \ + ltcf-cxx.sh ltcf-gcj.sh ltconfig ltmain.sh missing \ + mkinstalldirs ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \ $(top_srcdir)/configure.ac @@ -70,14 +72,15 @@ am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = fficonfig.h -CONFIG_CLEAN_FILES = +CONFIG_CLEAN_FILES = libffi.pc am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = `echo $$p | sed -e 's|^.*/||'`; -am__installdirs = "$(DESTDIR)$(toolexeclibdir)" +am__installdirs = "$(DESTDIR)$(toolexeclibdir)" \ + "$(DESTDIR)$(pkgconfigdir)" toolexeclibLTLIBRARIES_INSTALL = $(INSTALL) LTLIBRARIES = $(noinst_LTLIBRARIES) $(toolexeclib_LTLIBRARIES) libffi_la_LIBADD = @@ -175,6 +178,8 @@ RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ install-pdf-recursive install-ps-recursive install-recursive \ installcheck-recursive installdirs-recursive pdf-recursive \ ps-recursive uninstall-recursive +pkgconfigDATA_INSTALL = $(INSTALL_DATA) +DATA = $(pkgconfig_DATA) RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive ETAGS = etags @@ -386,6 +391,8 @@ libffi_la_SOURCES = src/debug.c src/prep_cif.c src/types.c \ src/raw_api.c src/java_raw_api.c src/closures.c # include/ffi_common.h include/ffitarget.h +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = libffi.pc nodist_libffi_la_SOURCES = $(am__append_1) $(am__append_2) \ $(am__append_3) $(am__append_4) $(am__append_5) \ $(am__append_6) $(am__append_7) $(am__append_8) \ @@ -455,6 +462,8 @@ $(srcdir)/fficonfig.h.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) distclean-hdr: -rm -f fficonfig.h stamp-h1 +libffi.pc: $(top_builddir)/config.status $(srcdir)/libffi.pc.in + cd $(top_builddir) && $(SHELL) ./config.status $@ clean-noinstLTLIBRARIES: -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) @@ -923,6 +932,23 @@ clean-libtool: distclean-libtool: -rm -f libtool +install-pkgconfigDATA: $(pkgconfig_DATA) + @$(NORMAL_INSTALL) + test -z "$(pkgconfigdir)" || $(MKDIR_P) "$(DESTDIR)$(pkgconfigdir)" + @list='$(pkgconfig_DATA)'; for p in $$list; do \ + if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ + f=$(am__strip_dir) \ + echo " $(pkgconfigDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(pkgconfigdir)/$$f'"; \ + $(pkgconfigDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(pkgconfigdir)/$$f"; \ + done + +uninstall-pkgconfigDATA: + @$(NORMAL_UNINSTALL) + @list='$(pkgconfig_DATA)'; for p in $$list; do \ + f=$(am__strip_dir) \ + echo " rm -f '$(DESTDIR)$(pkgconfigdir)/$$f'"; \ + rm -f "$(DESTDIR)$(pkgconfigdir)/$$f"; \ + done # This directory's subdirectories are mostly independent; you can cd # into them and run `make' without going through this Makefile. @@ -1199,10 +1225,10 @@ distcleancheck: distclean exit 1; } >&2 check-am: all-am check: check-recursive -all-am: Makefile $(LTLIBRARIES) fficonfig.h +all-am: Makefile $(LTLIBRARIES) $(DATA) fficonfig.h installdirs: installdirs-recursive installdirs-am: - for dir in "$(DESTDIR)$(toolexeclibdir)"; do \ + for dir in "$(DESTDIR)$(toolexeclibdir)" "$(DESTDIR)$(pkgconfigdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-recursive @@ -1283,7 +1309,7 @@ info: info-recursive info-am: -install-data-am: +install-data-am: install-pkgconfigDATA install-dvi: install-dvi-recursive @@ -1317,7 +1343,7 @@ ps: ps-recursive ps-am: -uninstall-am: uninstall-toolexeclibLTLIBRARIES +uninstall-am: uninstall-pkgconfigDATA uninstall-toolexeclibLTLIBRARIES .MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) install-am \ install-strip @@ -1333,13 +1359,14 @@ uninstall-am: uninstall-toolexeclibLTLIBRARIES info-am install install-am install-data install-data-am \ install-dvi install-dvi-am install-exec install-exec-am \ install-html install-html-am install-info install-info-am \ - install-man install-pdf install-pdf-am install-ps \ - install-ps-am install-strip install-toolexeclibLTLIBRARIES \ - installcheck installcheck-am installdirs installdirs-am \ - maintainer-clean maintainer-clean-generic mostlyclean \ - mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ - pdf pdf-am ps ps-am tags tags-recursive uninstall uninstall-am \ - uninstall-toolexeclibLTLIBRARIES + install-man install-pdf install-pdf-am install-pkgconfigDATA \ + install-ps install-ps-am install-strip \ + install-toolexeclibLTLIBRARIES installcheck installcheck-am \ + installdirs installdirs-am maintainer-clean \ + maintainer-clean-generic mostlyclean mostlyclean-compile \ + mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ + tags tags-recursive uninstall uninstall-am \ + uninstall-pkgconfigDATA uninstall-toolexeclibLTLIBRARIES # No install-html or install-pdf support in automake yet diff --git a/libffi/README b/libffi/README index f426c9df..56382bb3 100644 --- a/libffi/README +++ b/libffi/README @@ -1,40 +1,35 @@ -This directory contains the libffi package, which is not part of GCC but -shipped with GCC as convenience. - Status ====== -libffi-2.00 has not been released yet! This is a development snapshot! - -libffi-1.20 was released on October 5, 1998. Check the libffi web -page for updates: . +libffi-3.00 was released on February xx, 2008. Check the libffi web +page for updates: . What is libffi? =============== Compilers for high level languages generate code that follow certain -conventions. These conventions are necessary, in part, for separate -compilation to work. One such convention is the "calling -convention". The "calling convention" is essentially a set of -assumptions made by the compiler about where function arguments will -be found on entry to a function. A "calling convention" also specifies -where the return value for a function is found. +conventions. These conventions are necessary, in part, for separate +compilation to work. One such convention is the "calling convention". +The "calling convention" is a set of assumptions made by the compiler +about where function arguments will be found on entry to a function. +A "calling convention" also specifies where the return value for a +function is found. Some programs may not know at the time of compilation what arguments -are to be passed to a function. For instance, an interpreter may be +are to be passed to a function. For instance, an interpreter may be told at run-time about the number and types of arguments used to call -a given function. Libffi can be used in such programs to provide a +a given function. Libffi can be used in such programs to provide a bridge from the interpreter program to compiled code. The libffi library provides a portable, high level programming -interface to various calling conventions. This allows a programmer to +interface to various calling conventions. This allows a programmer to call any function specified by a call interface description at run -time. +time. -Ffi stands for Foreign Function Interface. A foreign function +FFI stands for Foreign Function Interface. A foreign function interface is the popular name for the interface that allows code -written in one language to call code written in another language. The +written in one language to call code written in another language. The libffi library really only provides the lowest, machine dependent layer of a fully featured foreign function interface. A layer must exist above libffi that handles type conversions for values passed @@ -120,7 +115,7 @@ call and that you know the number and types of arguments to pass it, as well as the return type of the function. The first thing you must do is create an ffi_cif object that matches -the signature of the function you wish to call. The cif in ffi_cif +the signature of the function you wish to call. The `cif' in ffi_cif stands for Call InterFace. To prepare a call interface object, use the following function: @@ -375,6 +370,9 @@ arguments' test). History ======= +3.00 Feb-XX-08 + Many changes, mostly thanks to the GCC project. + 1.20 Oct-5-98 Raffaele Sena produces ARM port. diff --git a/libffi/configure b/libffi/configure index 9fd638a6..8a2bbf99 100755 --- a/libffi/configure +++ b/libffi/configure @@ -22695,7 +22695,7 @@ ac_config_commands="$ac_config_commands src" ac_config_links="$ac_config_links include/ffitarget.h:src/$TARGETDIR/ffitarget.h" -ac_config_files="$ac_config_files include/Makefile include/ffi.h Makefile testsuite/Makefile" +ac_config_files="$ac_config_files include/Makefile include/ffi.h Makefile testsuite/Makefile libffi.pc" cat >confcache <<\_ACEOF @@ -23478,6 +23478,7 @@ do "include/ffi.h") CONFIG_FILES="$CONFIG_FILES include/ffi.h" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; "testsuite/Makefile") CONFIG_FILES="$CONFIG_FILES testsuite/Makefile" ;; + "libffi.pc") CONFIG_FILES="$CONFIG_FILES libffi.pc" ;; *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 echo "$as_me: error: invalid argument: $ac_config_target" >&2;} diff --git a/libffi/configure.ac b/libffi/configure.ac index 7c9713d5..fd9e4b82 100644 --- a/libffi/configure.ac +++ b/libffi/configure.ac @@ -352,6 +352,6 @@ test -d src/$TARGETDIR || mkdir src/$TARGETDIR AC_CONFIG_LINKS(include/ffitarget.h:src/$TARGETDIR/ffitarget.h) -AC_CONFIG_FILES(include/Makefile include/ffi.h Makefile testsuite/Makefile) +AC_CONFIG_FILES(include/Makefile include/ffi.h Makefile testsuite/Makefile libffi.pc) AC_OUTPUT diff --git a/libffi/include/Makefile.am b/libffi/include/Makefile.am index 03956afa..abdba526 100644 --- a/libffi/include/Makefile.am +++ b/libffi/include/Makefile.am @@ -5,5 +5,5 @@ AUTOMAKE_OPTIONS=foreign DISTCLEANFILES=ffitarget.h EXTRA_DIST=ffi.h.in ffi_common.h -includesdir = $(includedir) +includesdir = $(libdir)/@PACKAGE_NAME@-@PACKAGE_VERSION@/include includes_HEADERS = ffi.h ffitarget.h diff --git a/libffi/include/Makefile.in b/libffi/include/Makefile.in index e85e68b1..1c240f3a 100644 --- a/libffi/include/Makefile.in +++ b/libffi/include/Makefile.in @@ -182,7 +182,7 @@ top_srcdir = @top_srcdir@ AUTOMAKE_OPTIONS = foreign DISTCLEANFILES = ffitarget.h EXTRA_DIST = ffi.h.in ffi_common.h -includesdir = $(includedir) +includesdir = $(libdir)/@PACKAGE_NAME@-@PACKAGE_VERSION@/include includes_HEADERS = ffi.h ffitarget.h all: all-am diff --git a/libffi/libffi.pc.in b/libffi/libffi.pc.in new file mode 100644 index 00000000..10c910ab --- /dev/null +++ b/libffi/libffi.pc.in @@ -0,0 +1,10 @@ +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@/@PACKAGE_NAME@-@PACKAGE_VERSION@ +includedir=${libdir}/@PACKAGE_NAME@-@PACKAGE_VERSION@/include + +Name: libffi +Description: Library supporting Foreign Function Interfaces +Version: 3.0 +Libs: -lffi +Cflags: -I${includedir} diff --git a/libffi/libtool-version b/libffi/libtool-version index 67532867..71a31c48 100644 --- a/libffi/libtool-version +++ b/libffi/libtool-version @@ -3,4 +3,4 @@ # a separate file so that version updates don't involve re-running # automake. # CURRENT:REVISION:AGE -4:1:0 +5:1:0