1999-08-08 15:27:18 +02:00
|
|
|
## Process this with automake to create Makefile.in
|
|
|
|
|
|
|
|
AUTOMAKE_OPTIONS = cygnus
|
|
|
|
|
2000-05-01 23:35:35 +02:00
|
|
|
SUBDIRS = include
|
|
|
|
|
1999-08-08 15:27:18 +02:00
|
|
|
EXTRA_DIST = LICENSE ChangeLog.v1 src/mips/ffi.c src/mips/n32.S \
|
|
|
|
src/mips/n32.s src/mips/o32.S src/mips/o32.s \
|
2000-04-17 04:15:32 +02:00
|
|
|
src/sparc/ffi.c src/sparc/v8.S src/sparc/v9.S \
|
2001-03-27 04:39:16 +02:00
|
|
|
src/x86/ffi.c src/x86/sysv.S src/x86/win32.S \
|
1999-08-08 15:27:18 +02:00
|
|
|
src/alpha/ffi.c src/alpha/osf.S \
|
|
|
|
src/m68k/ffi.c src/m68k/sysv.S \
|
2001-03-24 04:26:28 +01:00
|
|
|
src/powerpc/ffi.c src/powerpc/sysv.S \
|
2002-01-17 17:04:21 +01:00
|
|
|
src/powerpc/ppc_closure.S src/powerpc/asm.h \
|
|
|
|
src/powerpc/ffi_darwin.c \
|
|
|
|
src/powerpc/darwin.S src/powerpc/aix.S \
|
2002-03-07 19:24:42 +01:00
|
|
|
src/powerpc/darwin_closure.S src/powerpc/aix_closures.S \
|
2002-04-29 06:14:44 +02:00
|
|
|
src/arm/ffi.c src/arm/sysv.S \
|
|
|
|
src/s390/ffi.c src/s390/sysv.S
|
1999-08-08 15:27:18 +02:00
|
|
|
|
|
|
|
VPATH = @srcdir@:@srcdir@/src:@srcdir@/src/@TARGETDIR@
|
|
|
|
|
2000-05-01 23:35:35 +02:00
|
|
|
## ################################################################
|
|
|
|
|
|
|
|
##
|
|
|
|
## This section is for make and multilib madness.
|
|
|
|
##
|
|
|
|
|
|
|
|
# Work around what appears to be a GNU make bug handling MAKEFLAGS
|
|
|
|
# values defined in terms of make variables, as is the case for CC and
|
|
|
|
# friends when we are called from the top level Makefile.
|
|
|
|
AM_MAKEFLAGS = \
|
|
|
|
"AR_FLAGS=$(AR_FLAGS)" \
|
|
|
|
"CC_FOR_BUILD=$(CC_FOR_BUILD)" \
|
|
|
|
"CFLAGS=$(CFLAGS)" \
|
|
|
|
"CXXFLAGS=$(CXXFLAGS)" \
|
|
|
|
"CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
|
|
|
|
"CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
|
|
|
|
"INSTALL=$(INSTALL)" \
|
|
|
|
"INSTALL_DATA=$(INSTALL_DATA)" \
|
|
|
|
"INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
|
|
|
|
"INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
|
|
|
|
"JC1FLAGS=$(JC1FLAGS)" \
|
|
|
|
"LDFLAGS=$(LDFLAGS)" \
|
|
|
|
"LIBCFLAGS=$(LIBCFLAGS)" \
|
|
|
|
"LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
|
|
|
|
"MAKE=$(MAKE)" \
|
|
|
|
"MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
|
|
|
|
"PICFLAG=$(PICFLAG)" \
|
|
|
|
"PICFLAG_FOR_TARGET=$(PICFLAG_FOR_TARGET)" \
|
|
|
|
"SHELL=$(SHELL)" \
|
|
|
|
"exec_prefix=$(exec_prefix)" \
|
|
|
|
"infodir=$(infodir)" \
|
|
|
|
"libdir=$(libdir)" \
|
|
|
|
"prefix=$(prefix)" \
|
|
|
|
"AR=$(AR)" \
|
|
|
|
"AS=$(AS)" \
|
|
|
|
"CC=$(CC)" \
|
|
|
|
"CXX=$(CXX)" \
|
|
|
|
"LD=$(LD)" \
|
|
|
|
"LIBCFLAGS=$(LIBCFLAGS)" \
|
|
|
|
"NM=$(NM)" \
|
|
|
|
"PICFLAG=$(PICFLAG)" \
|
|
|
|
"RANLIB=$(RANLIB)" \
|
|
|
|
"DESTDIR=$(DESTDIR)"
|
|
|
|
|
|
|
|
MAKEOVERRIDES=
|
|
|
|
|
1999-08-08 15:27:18 +02:00
|
|
|
# Multilib support variables.
|
|
|
|
MULTISRCTOP =
|
|
|
|
MULTIBUILDTOP =
|
|
|
|
MULTIDIRS =
|
|
|
|
MULTISUBDIR =
|
|
|
|
MULTIDO = true
|
|
|
|
MULTICLEAN = true
|
|
|
|
|
1999-08-10 07:29:27 +02:00
|
|
|
## Install a library built with a cross compiler in tooldir, not
|
|
|
|
## libdir.
|
|
|
|
if USE_LIBDIR
|
|
|
|
toolexeclibdir = $(libdir)$(MULTISUBDIR)
|
|
|
|
else
|
1999-08-08 15:27:18 +02:00
|
|
|
toolexecdir = $(exec_prefix)/$(target_alias)
|
|
|
|
toolexeclibdir = $(toolexecdir)/lib$(MULTISUBDIR)
|
1999-08-10 07:29:27 +02:00
|
|
|
endif
|
1999-08-08 15:27:18 +02:00
|
|
|
|
|
|
|
toolexeclib_LTLIBRARIES = libffi.la
|
2002-03-17 01:35:21 +01:00
|
|
|
noinst_LTLIBRARIES = libffi_convenience.la
|
1999-08-08 15:27:18 +02:00
|
|
|
|
|
|
|
noinst_PROGRAMS = ffitest
|
|
|
|
|
2002-03-17 02:05:11 +01:00
|
|
|
ffitest_OBJECTS = ffitest.lo
|
1999-08-08 15:27:18 +02:00
|
|
|
ffitest_LDADD = libffi.la
|
2001-03-23 02:26:33 +01:00
|
|
|
ffitest_LDFLAGS = -shared-libgcc
|
1999-08-08 15:27:18 +02:00
|
|
|
|
|
|
|
TARGET_SRC_MIPS_GCC = src/mips/ffi.c src/mips/o32.S src/mips/n32.S
|
|
|
|
TARGET_SRC_MIPS_SGI = src/mips/ffi.c src/mips/o32.s src/mips/n32.s
|
|
|
|
TARGET_SRC_X86 = src/x86/ffi.c src/x86/sysv.S
|
2001-03-27 04:39:16 +02:00
|
|
|
TARGET_SRC_X86_WIN32 = src/x86/ffi.c src/x86/win32.S
|
2000-04-17 04:15:32 +02:00
|
|
|
TARGET_SRC_SPARC = src/sparc/ffi.c src/sparc/v8.S src/sparc/v9.S
|
1999-08-08 15:27:18 +02:00
|
|
|
TARGET_SRC_ALPHA = src/alpha/ffi.c src/alpha/osf.S
|
2000-03-03 02:19:22 +01:00
|
|
|
TARGET_SRC_IA64 = src/ia64/ffi.c src/ia64/unix.S
|
1999-08-08 15:27:18 +02:00
|
|
|
TARGET_SRC_M68K = src/m68k/ffi.c src/m68k/sysv.S
|
2001-03-24 04:26:28 +01:00
|
|
|
TARGET_SRC_POWERPC = src/powerpc/ffi.c src/powerpc/sysv.S src/powerpc/ppc_closure.S
|
2002-03-07 19:24:42 +01:00
|
|
|
TARGET_SRC_POWERPC_AIX = src/powerpc/ffi_darwin.c src/powerpc/aix.S src/powerpc/aix_closures.S
|
|
|
|
TARGET_SRC_POWERPC_DARWIN = src/powerpc/ffi_darwin.c src/powerpc/darwin.S src/powerpc/darwin_closure.S
|
1999-08-08 15:27:18 +02:00
|
|
|
TARGET_SRC_ARM = src/arm/sysv.S src/arm/ffi.c
|
2002-04-29 06:14:44 +02:00
|
|
|
TARGET_SRC_S390 = src/s390/sysv.S src/s390/ffi.c
|
1999-08-08 15:27:18 +02:00
|
|
|
|
|
|
|
##libffi_la_SOURCES = src/debug.c src/prep_cif.c src/types.c $(TARGET_SRC_@TARGET@)
|
|
|
|
## Work around automake deficiency
|
2000-02-25 20:13:44 +01:00
|
|
|
libffi_la_common_SOURCES = src/debug.c src/prep_cif.c src/types.c \
|
|
|
|
src/raw_api.c src/java_raw_api.c
|
1999-08-08 15:27:18 +02:00
|
|
|
if MIPS_GCC
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_MIPS_GCC)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_MIPS_GCC)
|
1999-08-08 15:27:18 +02:00
|
|
|
endif
|
|
|
|
if MIPS_SGI
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_MIPS_SGI)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_MIPS_SGI)
|
1999-08-08 15:27:18 +02:00
|
|
|
endif
|
|
|
|
if X86
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_X86)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_X86)
|
1999-08-08 15:27:18 +02:00
|
|
|
endif
|
2001-03-27 04:39:16 +02:00
|
|
|
if X86_WIN32
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_X86_WIN32)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_X86_WIN32)
|
2001-03-27 04:39:16 +02:00
|
|
|
endif
|
1999-08-08 15:27:18 +02:00
|
|
|
if SPARC
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_SPARC)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_SPARC)
|
1999-08-08 15:27:18 +02:00
|
|
|
endif
|
|
|
|
if ALPHA
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_ALPHA)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_ALPHA)
|
1999-08-08 15:27:18 +02:00
|
|
|
endif
|
2000-02-25 20:13:44 +01:00
|
|
|
if IA64
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_IA64)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_IA64)
|
2000-02-25 20:13:44 +01:00
|
|
|
endif
|
1999-08-08 15:27:18 +02:00
|
|
|
if M68K
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_M68K)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_M68K)
|
1999-08-08 15:27:18 +02:00
|
|
|
endif
|
|
|
|
if POWERPC
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_POWERPC)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_POWERPC)
|
1999-08-08 15:27:18 +02:00
|
|
|
endif
|
2002-01-17 17:04:21 +01:00
|
|
|
if POWERPC_AIX
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_POWERPC_AIX)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_POWERPC_AIX)
|
2002-01-17 17:04:21 +01:00
|
|
|
endif
|
2001-10-09 07:32:16 +02:00
|
|
|
if POWERPC_DARWIN
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_POWERPC_DARWIN)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_POWERPC_DARWIN)
|
2001-10-09 07:32:16 +02:00
|
|
|
endif
|
1999-08-08 15:27:18 +02:00
|
|
|
if ARM
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_ARM)
|
2002-03-17 01:35:21 +01:00
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_ARM)
|
1999-08-08 15:27:18 +02:00
|
|
|
endif
|
2002-04-29 06:14:44 +02:00
|
|
|
if S390
|
|
|
|
libffi_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_S390)
|
|
|
|
libffi_convenience_la_SOURCES = $(libffi_la_common_SOURCES) $(TARGET_SRC_S390)
|
|
|
|
endif
|
1999-08-08 15:27:18 +02:00
|
|
|
|
1999-08-09 00:58:30 +02:00
|
|
|
AM_CFLAGS = -fexceptions
|
|
|
|
|
1999-08-08 15:27:18 +02:00
|
|
|
libffi_la_LDFLAGS = -release $(VERSION)
|
|
|
|
|
1999-12-31 23:44:09 +01:00
|
|
|
INCLUDES = -I$(top_srcdir)/include -Iinclude -I$(top_srcdir)/src
|
2000-05-01 23:35:35 +02:00
|
|
|
|
2001-03-27 00:52:36 +02:00
|
|
|
# Override these rules so that object files get put in the correct
|
|
|
|
# subdirectories.
|
|
|
|
.c.o:
|
|
|
|
$(LTCOMPILE) -c -o $@ $<
|
|
|
|
|
|
|
|
.s.o:
|
|
|
|
$(LTCOMPILE) -c -o $@ $<
|
|
|
|
|
|
|
|
.S.o:
|
|
|
|
$(LTCOMPILE) -c -o $@ $<
|
|
|
|
|
|
|
|
.c.lo:
|
|
|
|
$(LTCOMPILE) -c -o $@ $<
|
|
|
|
|
|
|
|
.s.lo:
|
|
|
|
$(LTCOMPILE) -c -o $@ $<
|
|
|
|
|
|
|
|
.S.lo:
|
|
|
|
$(LTCOMPILE) -c -o $@ $<
|
|
|
|
|
2000-05-01 23:35:35 +02:00
|
|
|
# Multilib support.
|
|
|
|
.PHONY: all-multi mostlyclean-multi clean-multi distclean-multi \
|
|
|
|
maintainer-clean-multi
|
|
|
|
|
|
|
|
all-recursive: all-multi
|
|
|
|
install-recursive: install-multi
|
|
|
|
mostlyclean-recursive: mostlyclean-multi
|
|
|
|
clean-recursive: clean-multi
|
|
|
|
distclean-recursive: distclean-multi
|
|
|
|
maintainer-clean-recursive: maintainer-clean-multi
|
|
|
|
|
|
|
|
all-multi:
|
|
|
|
$(MULTIDO) $(AM_MAKEFLAGS) DO=all multi-do
|
|
|
|
install-multi:
|
|
|
|
$(MULTIDO) $(AM_MAKEFLAGS) DO=install multi-do
|
|
|
|
mostlyclean-multi:
|
|
|
|
$(MULTICLEAN) $(AM_MAKEFLAGS) DO=mostlyclean multi-clean
|
|
|
|
clean-multi:
|
|
|
|
$(MULTICLEAN) $(AM_MAKEFLAGS) DO=clean multi-clean
|
|
|
|
distclean-multi:
|
|
|
|
$(MULTICLEAN) $(AM_MAKEFLAGS) DO=distclean multi-clean
|
|
|
|
maintainer-clean-multi:
|
|
|
|
$(MULTICLEAN) $(AM_MAKEFLAGS) DO=maintainer-clean multi-clean
|
|
|
|
|
|
|
|
|
|
|
|
## ################################################################
|
|
|
|
|