orc-0.4.18/ 0000775 0001750 0001750 00000000000 12206165374 007400 5 0000000 0000000 orc-0.4.18/depcomp 0000755 0001750 0001750 00000050643 12206165330 010673 0000000 0000000 #! /bin/sh
# depcomp - compile a program generating dependencies as side-effects
scriptversion=2012-03-27.16; # UTC
# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009, 2010,
# 2011, 2012 Free Software Foundation, Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see .
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
# Originally written by Alexandre Oliva .
case $1 in
'')
echo "$0: No command. Try '$0 --help' for more information." 1>&2
exit 1;
;;
-h | --h*)
cat <<\EOF
Usage: depcomp [--help] [--version] PROGRAM [ARGS]
Run PROGRAMS ARGS to compile a file, generating dependencies
as side-effects.
Environment variables:
depmode Dependency tracking mode.
source Source file read by 'PROGRAMS ARGS'.
object Object file output by 'PROGRAMS ARGS'.
DEPDIR directory where to store dependencies.
depfile Dependency file to output.
tmpdepfile Temporary file to use when outputting dependencies.
libtool Whether libtool is used (yes/no).
Report bugs to .
EOF
exit $?
;;
-v | --v*)
echo "depcomp $scriptversion"
exit $?
;;
esac
# A tabulation character.
tab=' '
# A newline character.
nl='
'
if test -z "$depmode" || test -z "$source" || test -z "$object"; then
echo "depcomp: Variables source, object and depmode must be set" 1>&2
exit 1
fi
# Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po.
depfile=${depfile-`echo "$object" |
sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`}
tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`}
rm -f "$tmpdepfile"
# Some modes work just like other modes, but use different flags. We
# parameterize here, but still list the modes in the big case below,
# to make depend.m4 easier to write. Note that we *cannot* use a case
# here, because this file can only contain one case statement.
if test "$depmode" = hp; then
# HP compiler uses -M and no extra arg.
gccflag=-M
depmode=gcc
fi
if test "$depmode" = dashXmstdout; then
# This is just like dashmstdout with a different argument.
dashmflag=-xM
depmode=dashmstdout
fi
cygpath_u="cygpath -u -f -"
if test "$depmode" = msvcmsys; then
# This is just like msvisualcpp but w/o cygpath translation.
# Just convert the backslash-escaped backslashes to single forward
# slashes to satisfy depend.m4
cygpath_u='sed s,\\\\,/,g'
depmode=msvisualcpp
fi
if test "$depmode" = msvc7msys; then
# This is just like msvc7 but w/o cygpath translation.
# Just convert the backslash-escaped backslashes to single forward
# slashes to satisfy depend.m4
cygpath_u='sed s,\\\\,/,g'
depmode=msvc7
fi
if test "$depmode" = xlc; then
# IBM C/C++ Compilers xlc/xlC can output gcc-like dependency informations.
gccflag=-qmakedep=gcc,-MF
depmode=gcc
fi
case "$depmode" in
gcc3)
## gcc 3 implements dependency tracking that does exactly what
## we want. Yay! Note: for some reason libtool 1.4 doesn't like
## it if -MD -MP comes after the -MF stuff. Hmm.
## Unfortunately, FreeBSD c89 acceptance of flags depends upon
## the command line argument order; so add the flags where they
## appear in depend2.am. Note that the slowdown incurred here
## affects only configure: in makefiles, %FASTDEP% shortcuts this.
for arg
do
case $arg in
-c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;;
*) set fnord "$@" "$arg" ;;
esac
shift # fnord
shift # $arg
done
"$@"
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
mv "$tmpdepfile" "$depfile"
;;
gcc)
## There are various ways to get dependency output from gcc. Here's
## why we pick this rather obscure method:
## - Don't want to use -MD because we'd like the dependencies to end
## up in a subdir. Having to rename by hand is ugly.
## (We might end up doing this anyway to support other compilers.)
## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like
## -MM, not -M (despite what the docs say).
## - Using -M directly means running the compiler twice (even worse
## than renaming).
if test -z "$gccflag"; then
gccflag=-MD,
fi
"$@" -Wp,"$gccflag$tmpdepfile"
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
echo "$object : \\" > "$depfile"
alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
## The second -e expression handles DOS-style file names with drive letters.
sed -e 's/^[^:]*: / /' \
-e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile"
## This next piece of magic avoids the "deleted header file" problem.
## The problem is that when a header file which appears in a .P file
## is deleted, the dependency causes make to die (because there is
## typically no way to rebuild the header). We avoid this by adding
## dummy dependencies for each header file. Too bad gcc doesn't do
## this for us directly.
tr ' ' "$nl" < "$tmpdepfile" |
## Some versions of gcc put a space before the ':'. On the theory
## that the space means something, we add a space to the output as
## well. hp depmode also adds that space, but also prefixes the VPATH
## to the object. Take care to not repeat it in the output.
## Some versions of the HPUX 10.20 sed can't process this invocation
## correctly. Breaking it into two sed invocations is a workaround.
sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \
| sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
hp)
# This case exists only to let depend.m4 do its work. It works by
# looking at the text of this script. This case will never be run,
# since it is checked for above.
exit 1
;;
sgi)
if test "$libtool" = yes; then
"$@" "-Wp,-MDupdate,$tmpdepfile"
else
"$@" -MDupdate "$tmpdepfile"
fi
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files
echo "$object : \\" > "$depfile"
# Clip off the initial element (the dependent). Don't try to be
# clever and replace this with sed code, as IRIX sed won't handle
# lines with more than a fixed number of characters (4096 in
# IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines;
# the IRIX cc adds comments like '#:fec' to the end of the
# dependency line.
tr ' ' "$nl" < "$tmpdepfile" \
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \
tr "$nl" ' ' >> "$depfile"
echo >> "$depfile"
# The second pass generates a dummy entry for each header file.
tr ' ' "$nl" < "$tmpdepfile" \
| sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \
>> "$depfile"
else
# The sourcefile does not contain any dependencies, so just
# store a dummy comment line, to avoid errors with the Makefile
# "include basename.Plo" scheme.
echo "#dummy" > "$depfile"
fi
rm -f "$tmpdepfile"
;;
xlc)
# This case exists only to let depend.m4 do its work. It works by
# looking at the text of this script. This case will never be run,
# since it is checked for above.
exit 1
;;
aix)
# The C for AIX Compiler uses -M and outputs the dependencies
# in a .u file. In older versions, this file always lives in the
# current directory. Also, the AIX compiler puts '$object:' at the
# start of each line; $object doesn't have directory information.
# Version 6 uses the directory in both cases.
dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
test "x$dir" = "x$object" && dir=
base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
if test "$libtool" = yes; then
tmpdepfile1=$dir$base.u
tmpdepfile2=$base.u
tmpdepfile3=$dir.libs/$base.u
"$@" -Wc,-M
else
tmpdepfile1=$dir$base.u
tmpdepfile2=$dir$base.u
tmpdepfile3=$dir$base.u
"$@" -M
fi
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
exit $stat
fi
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3"
do
test -f "$tmpdepfile" && break
done
if test -f "$tmpdepfile"; then
# Each line is of the form 'foo.o: dependent.h'.
# Do two passes, one to just change these to
# '$object: dependent.h' and one to simply 'dependent.h:'.
sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile"
sed -e 's,^.*\.[a-z]*:['"$tab"' ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile"
else
# The sourcefile does not contain any dependencies, so just
# store a dummy comment line, to avoid errors with the Makefile
# "include basename.Plo" scheme.
echo "#dummy" > "$depfile"
fi
rm -f "$tmpdepfile"
;;
icc)
# Intel's C compiler anf tcc (Tiny C Compiler) understand '-MD -MF file'.
# However on
# $CC -MD -MF foo.d -c -o sub/foo.o sub/foo.c
# ICC 7.0 will fill foo.d with something like
# foo.o: sub/foo.c
# foo.o: sub/foo.h
# which is wrong. We want
# sub/foo.o: sub/foo.c
# sub/foo.o: sub/foo.h
# sub/foo.c:
# sub/foo.h:
# ICC 7.1 will output
# foo.o: sub/foo.c sub/foo.h
# and will wrap long lines using '\':
# foo.o: sub/foo.c ... \
# sub/foo.h ... \
# ...
# tcc 0.9.26 (FIXME still under development at the moment of writing)
# will emit a similar output, but also prepend the continuation lines
# with horizontal tabulation characters.
"$@" -MD -MF "$tmpdepfile"
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
# Each line is of the form 'foo.o: dependent.h',
# or 'foo.o: dep1.h dep2.h \', or ' dep3.h dep4.h \'.
# Do two passes, one to just change these to
# '$object: dependent.h' and one to simply 'dependent.h:'.
sed -e "s/^[ $tab][ $tab]*/ /" -e "s,^[^:]*:,$object :," \
< "$tmpdepfile" > "$depfile"
sed '
s/[ '"$tab"'][ '"$tab"']*/ /g
s/^ *//
s/ *\\*$//
s/^[^:]*: *//
/^$/d
/:$/d
s/$/ :/
' < "$tmpdepfile" >> "$depfile"
rm -f "$tmpdepfile"
;;
hp2)
# The "hp" stanza above does not work with aCC (C++) and HP's ia64
# compilers, which have integrated preprocessors. The correct option
# to use with these is +Maked; it writes dependencies to a file named
# 'foo.d', which lands next to the object file, wherever that
# happens to be.
# Much of this is similar to the tru64 case; see comments there.
dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
test "x$dir" = "x$object" && dir=
base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
if test "$libtool" = yes; then
tmpdepfile1=$dir$base.d
tmpdepfile2=$dir.libs/$base.d
"$@" -Wc,+Maked
else
tmpdepfile1=$dir$base.d
tmpdepfile2=$dir$base.d
"$@" +Maked
fi
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile1" "$tmpdepfile2"
exit $stat
fi
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2"
do
test -f "$tmpdepfile" && break
done
if test -f "$tmpdepfile"; then
sed -e "s,^.*\.[a-z]*:,$object:," "$tmpdepfile" > "$depfile"
# Add 'dependent.h:' lines.
sed -ne '2,${
s/^ *//
s/ \\*$//
s/$/:/
p
}' "$tmpdepfile" >> "$depfile"
else
echo "#dummy" > "$depfile"
fi
rm -f "$tmpdepfile" "$tmpdepfile2"
;;
tru64)
# The Tru64 compiler uses -MD to generate dependencies as a side
# effect. 'cc -MD -o foo.o ...' puts the dependencies into 'foo.o.d'.
# At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put
# dependencies in 'foo.d' instead, so we check for that too.
# Subdirectories are respected.
dir=`echo "$object" | sed -e 's|/[^/]*$|/|'`
test "x$dir" = "x$object" && dir=
base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'`
if test "$libtool" = yes; then
# With Tru64 cc, shared objects can also be used to make a
# static library. This mechanism is used in libtool 1.4 series to
# handle both shared and static libraries in a single compilation.
# With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d.
#
# With libtool 1.5 this exception was removed, and libtool now
# generates 2 separate objects for the 2 libraries. These two
# compilations output dependencies in $dir.libs/$base.o.d and
# in $dir$base.o.d. We have to check for both files, because
# one of the two compilations can be disabled. We should prefer
# $dir$base.o.d over $dir.libs/$base.o.d because the latter is
# automatically cleaned when .libs/ is deleted, while ignoring
# the former would cause a distcleancheck panic.
tmpdepfile1=$dir.libs/$base.lo.d # libtool 1.4
tmpdepfile2=$dir$base.o.d # libtool 1.5
tmpdepfile3=$dir.libs/$base.o.d # libtool 1.5
tmpdepfile4=$dir.libs/$base.d # Compaq CCC V6.2-504
"$@" -Wc,-MD
else
tmpdepfile1=$dir$base.o.d
tmpdepfile2=$dir$base.d
tmpdepfile3=$dir$base.d
tmpdepfile4=$dir$base.d
"$@" -MD
fi
stat=$?
if test $stat -eq 0; then :
else
rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4"
exit $stat
fi
for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4"
do
test -f "$tmpdepfile" && break
done
if test -f "$tmpdepfile"; then
sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile"
sed -e 's,^.*\.[a-z]*:['"$tab"' ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile"
else
echo "#dummy" > "$depfile"
fi
rm -f "$tmpdepfile"
;;
msvc7)
if test "$libtool" = yes; then
showIncludes=-Wc,-showIncludes
else
showIncludes=-showIncludes
fi
"$@" $showIncludes > "$tmpdepfile"
stat=$?
grep -v '^Note: including file: ' "$tmpdepfile"
if test "$stat" = 0; then :
else
rm -f "$tmpdepfile"
exit $stat
fi
rm -f "$depfile"
echo "$object : \\" > "$depfile"
# The first sed program below extracts the file names and escapes
# backslashes for cygpath. The second sed program outputs the file
# name when reading, but also accumulates all include files in the
# hold buffer in order to output them again at the end. This only
# works with sed implementations that can handle large buffers.
sed < "$tmpdepfile" -n '
/^Note: including file: *\(.*\)/ {
s//\1/
s/\\/\\\\/g
p
}' | $cygpath_u | sort -u | sed -n '
s/ /\\ /g
s/\(.*\)/'"$tab"'\1 \\/p
s/.\(.*\) \\/\1:/
H
$ {
s/.*/'"$tab"'/
G
p
}' >> "$depfile"
rm -f "$tmpdepfile"
;;
msvc7msys)
# This case exists only to let depend.m4 do its work. It works by
# looking at the text of this script. This case will never be run,
# since it is checked for above.
exit 1
;;
#nosideeffect)
# This comment above is used by automake to tell side-effect
# dependency tracking mechanisms from slower ones.
dashmstdout)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout, regardless of -o.
"$@" || exit $?
# Remove the call to Libtool.
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
# Remove '-o $object'.
IFS=" "
for arg
do
case $arg in
-o)
shift
;;
$object)
shift
;;
*)
set fnord "$@" "$arg"
shift # fnord
shift # $arg
;;
esac
done
test -z "$dashmflag" && dashmflag=-M
# Require at least two characters before searching for ':'
# in the target name. This is to cope with DOS-style filenames:
# a dependency such as 'c:/foo/bar' could be seen as target 'c' otherwise.
"$@" $dashmflag |
sed 's:^['"$tab"' ]*[^:'"$tab"' ][^:][^:]*\:['"$tab"' ]*:'"$object"'\: :' > "$tmpdepfile"
rm -f "$depfile"
cat < "$tmpdepfile" > "$depfile"
tr ' ' "$nl" < "$tmpdepfile" | \
## Some versions of the HPUX 10.20 sed can't process this invocation
## correctly. Breaking it into two sed invocations is a workaround.
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
dashXmstdout)
# This case only exists to satisfy depend.m4. It is never actually
# run, as this mode is specially recognized in the preamble.
exit 1
;;
makedepend)
"$@" || exit $?
# Remove any Libtool call
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
# X makedepend
shift
cleared=no eat=no
for arg
do
case $cleared in
no)
set ""; shift
cleared=yes ;;
esac
if test $eat = yes; then
eat=no
continue
fi
case "$arg" in
-D*|-I*)
set fnord "$@" "$arg"; shift ;;
# Strip any option that makedepend may not understand. Remove
# the object too, otherwise makedepend will parse it as a source file.
-arch)
eat=yes ;;
-*|$object)
;;
*)
set fnord "$@" "$arg"; shift ;;
esac
done
obj_suffix=`echo "$object" | sed 's/^.*\././'`
touch "$tmpdepfile"
${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@"
rm -f "$depfile"
# makedepend may prepend the VPATH from the source file name to the object.
# No need to regex-escape $object, excess matching of '.' is harmless.
sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile"
sed '1,2d' "$tmpdepfile" | tr ' ' "$nl" | \
## Some versions of the HPUX 10.20 sed can't process this invocation
## correctly. Breaking it into two sed invocations is a workaround.
sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile"
rm -f "$tmpdepfile" "$tmpdepfile".bak
;;
cpp)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout.
"$@" || exit $?
# Remove the call to Libtool.
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
# Remove '-o $object'.
IFS=" "
for arg
do
case $arg in
-o)
shift
;;
$object)
shift
;;
*)
set fnord "$@" "$arg"
shift # fnord
shift # $arg
;;
esac
done
"$@" -E |
sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \
-e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' |
sed '$ s: \\$::' > "$tmpdepfile"
rm -f "$depfile"
echo "$object : \\" > "$depfile"
cat < "$tmpdepfile" >> "$depfile"
sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile"
rm -f "$tmpdepfile"
;;
msvisualcpp)
# Important note: in order to support this mode, a compiler *must*
# always write the preprocessed file to stdout.
"$@" || exit $?
# Remove the call to Libtool.
if test "$libtool" = yes; then
while test "X$1" != 'X--mode=compile'; do
shift
done
shift
fi
IFS=" "
for arg
do
case "$arg" in
-o)
shift
;;
$object)
shift
;;
"-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI")
set fnord "$@"
shift
shift
;;
*)
set fnord "$@" "$arg"
shift
shift
;;
esac
done
"$@" -E 2>/dev/null |
sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile"
rm -f "$depfile"
echo "$object : \\" > "$depfile"
sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::'"$tab"'\1 \\:p' >> "$depfile"
echo "$tab" >> "$depfile"
sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile"
rm -f "$tmpdepfile"
;;
msvcmsys)
# This case exists only to let depend.m4 do its work. It works by
# looking at the text of this script. This case will never be run,
# since it is checked for above.
exit 1
;;
none)
exec "$@"
;;
*)
echo "Unknown depmode $depmode" 1>&2
exit 1
;;
esac
exit 0
# Local Variables:
# mode: shell-script
# sh-indentation: 2
# eval: (add-hook 'write-file-hooks 'time-stamp)
# time-stamp-start: "scriptversion="
# time-stamp-format: "%:y-%02m-%02d.%02H"
# time-stamp-time-zone: "UTC"
# time-stamp-end: "; # UTC"
# End:
orc-0.4.18/orc-uninstalled.pc.in 0000664 0001750 0001750 00000000507 12126351204 013344 0000000 0000000 prefix=
exec_prefix=
libdir=${pcfiledir}/orc/
includedir=${pcfiledir}/
Name: orc-@ORC_MAJORMINOR@ uninstalled
Description: Library of Optimized Inner Loops Runtime Compiler
Version: @VERSION@
Libs: @abs_top_builddir@/orc/liborc-@ORC_MAJORMINOR@.la @LIBM@ @LIBRT@
Cflags: -I${includedir}
orcc=${pcfiledir}/tools/orcc@EXEEXT@
orc-0.4.18/COPYING 0000644 0001750 0001750 00000006064 11551076052 010353 0000000 0000000
The majority of the source code and the collective work is subject
to the following license:
Copyright 2002 - 2009 David A. Schleef
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
The source code implementing the Mersenne Twister algorithm is
subject to the following license:
Copyright (C) 1997 - 2002, Makoto Matsumoto and Takuji Nishimura,
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. The names of its contributors may not be used to endorse or promote
products derived from this software without specific prior written
permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
orc-0.4.18/m4/ 0000775 0001750 0001750 00000000000 12206165373 007717 5 0000000 0000000 orc-0.4.18/m4/ltversion.m4 0000644 0001750 0001750 00000001262 12206165324 012121 0000000 0000000 # ltversion.m4 -- version numbers -*- Autoconf -*-
#
# Copyright (C) 2004 Free Software Foundation, Inc.
# Written by Scott James Remnant, 2004
#
# This file is free software; the Free Software Foundation gives
# unlimited permission to copy and/or distribute it, with or without
# modifications, as long as this notice is preserved.
# @configure_input@
# serial 3337 ltversion.m4
# This file is part of GNU Libtool
m4_define([LT_PACKAGE_VERSION], [2.4.2])
m4_define([LT_PACKAGE_REVISION], [1.3337])
AC_DEFUN([LTVERSION_VERSION],
[macro_version='2.4.2'
macro_revision='1.3337'
_LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?])
_LT_DECL(, macro_revision, 0)
])
orc-0.4.18/m4/libtool.m4 0000644 0001750 0001750 00001060434 12206165324 011547 0000000 0000000 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
#
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
# 2006, 2007, 2008, 2009, 2010, 2011 Free Software
# Foundation, Inc.
# Written by Gordon Matzigkeit, 1996
#
# This file is free software; the Free Software Foundation gives
# unlimited permission to copy and/or distribute it, with or without
# modifications, as long as this notice is preserved.
m4_define([_LT_COPYING], [dnl
# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
# 2006, 2007, 2008, 2009, 2010, 2011 Free Software
# Foundation, Inc.
# Written by Gordon Matzigkeit, 1996
#
# This file is part of GNU Libtool.
#
# GNU Libtool is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation; either version 2 of
# the License, or (at your option) any later version.
#
# As a special exception to the GNU General Public License,
# if you distribute this file as part of a program or library that
# is built using GNU Libtool, you may include this file under the
# same distribution terms that you use for the rest of that program.
#
# GNU Libtool is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GNU Libtool; see the file COPYING. If not, a copy
# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
# obtained by writing to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
])
# serial 57 LT_INIT
# LT_PREREQ(VERSION)
# ------------------
# Complain and exit if this libtool version is less that VERSION.
m4_defun([LT_PREREQ],
[m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1,
[m4_default([$3],
[m4_fatal([Libtool version $1 or higher is required],
63)])],
[$2])])
# _LT_CHECK_BUILDDIR
# ------------------
# Complain if the absolute build directory name contains unusual characters
m4_defun([_LT_CHECK_BUILDDIR],
[case `pwd` in
*\ * | *\ *)
AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;;
esac
])
# LT_INIT([OPTIONS])
# ------------------
AC_DEFUN([LT_INIT],
[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT
AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl
AC_BEFORE([$0], [LT_LANG])dnl
AC_BEFORE([$0], [LT_OUTPUT])dnl
AC_BEFORE([$0], [LTDL_INIT])dnl
m4_require([_LT_CHECK_BUILDDIR])dnl
dnl Autoconf doesn't catch unexpanded LT_ macros by default:
m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl
m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl
dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4
dnl unless we require an AC_DEFUNed macro:
AC_REQUIRE([LTOPTIONS_VERSION])dnl
AC_REQUIRE([LTSUGAR_VERSION])dnl
AC_REQUIRE([LTVERSION_VERSION])dnl
AC_REQUIRE([LTOBSOLETE_VERSION])dnl
m4_require([_LT_PROG_LTMAIN])dnl
_LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}])
dnl Parse OPTIONS
_LT_SET_OPTIONS([$0], [$1])
# This can be used to rebuild libtool when needed
LIBTOOL_DEPS="$ltmain"
# Always use our own libtool.
LIBTOOL='$(SHELL) $(top_builddir)/libtool'
AC_SUBST(LIBTOOL)dnl
_LT_SETUP
# Only expand once:
m4_define([LT_INIT])
])# LT_INIT
# Old names:
AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT])
AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_PROG_LIBTOOL], [])
dnl AC_DEFUN([AM_PROG_LIBTOOL], [])
# _LT_CC_BASENAME(CC)
# -------------------
# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
m4_defun([_LT_CC_BASENAME],
[for cc_temp in $1""; do
case $cc_temp in
compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;;
distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;;
\-*) ;;
*) break;;
esac
done
cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
])
# _LT_FILEUTILS_DEFAULTS
# ----------------------
# It is okay to use these file commands and assume they have been set
# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'.
m4_defun([_LT_FILEUTILS_DEFAULTS],
[: ${CP="cp -f"}
: ${MV="mv -f"}
: ${RM="rm -f"}
])# _LT_FILEUTILS_DEFAULTS
# _LT_SETUP
# ---------
m4_defun([_LT_SETUP],
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl
AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl
_LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl
dnl
_LT_DECL([], [host_alias], [0], [The host system])dnl
_LT_DECL([], [host], [0])dnl
_LT_DECL([], [host_os], [0])dnl
dnl
_LT_DECL([], [build_alias], [0], [The build system])dnl
_LT_DECL([], [build], [0])dnl
_LT_DECL([], [build_os], [0])dnl
dnl
AC_REQUIRE([AC_PROG_CC])dnl
AC_REQUIRE([LT_PATH_LD])dnl
AC_REQUIRE([LT_PATH_NM])dnl
dnl
AC_REQUIRE([AC_PROG_LN_S])dnl
test -z "$LN_S" && LN_S="ln -s"
_LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl
dnl
AC_REQUIRE([LT_CMD_MAX_LEN])dnl
_LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl
_LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl
dnl
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
m4_require([_LT_CHECK_SHELL_FEATURES])dnl
m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl
m4_require([_LT_CMD_RELOAD])dnl
m4_require([_LT_CHECK_MAGIC_METHOD])dnl
m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl
m4_require([_LT_CMD_OLD_ARCHIVE])dnl
m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
m4_require([_LT_WITH_SYSROOT])dnl
_LT_CONFIG_LIBTOOL_INIT([
# See if we are running on zsh, and set the options which allow our
# commands through without removal of \ escapes INIT.
if test -n "\${ZSH_VERSION+set}" ; then
setopt NO_GLOB_SUBST
fi
])
if test -n "${ZSH_VERSION+set}" ; then
setopt NO_GLOB_SUBST
fi
_LT_CHECK_OBJDIR
m4_require([_LT_TAG_COMPILER])dnl
case $host_os in
aix3*)
# AIX sometimes has problems with the GCC collect2 program. For some
# reason, if we set the COLLECT_NAMES environment variable, the problems
# vanish in a puff of smoke.
if test "X${COLLECT_NAMES+set}" != Xset; then
COLLECT_NAMES=
export COLLECT_NAMES
fi
;;
esac
# Global variables:
ofile=libtool
can_build_shared=yes
# All known linkers require a `.a' archive for static linking (except MSVC,
# which needs '.lib').
libext=a
with_gnu_ld="$lt_cv_prog_gnu_ld"
old_CC="$CC"
old_CFLAGS="$CFLAGS"
# Set sane defaults for various variables
test -z "$CC" && CC=cc
test -z "$LTCC" && LTCC=$CC
test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
test -z "$LD" && LD=ld
test -z "$ac_objext" && ac_objext=o
_LT_CC_BASENAME([$compiler])
# Only perform the check for file, if the check method requires it
test -z "$MAGIC_CMD" && MAGIC_CMD=file
case $deplibs_check_method in
file_magic*)
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
_LT_PATH_MAGIC
fi
;;
esac
# Use C for the default configuration in the libtool script
LT_SUPPORTED_TAG([CC])
_LT_LANG_C_CONFIG
_LT_LANG_DEFAULT_CONFIG
_LT_CONFIG_COMMANDS
])# _LT_SETUP
# _LT_PREPARE_SED_QUOTE_VARS
# --------------------------
# Define a few sed substitution that help us do robust quoting.
m4_defun([_LT_PREPARE_SED_QUOTE_VARS],
[# Backslashify metacharacters that are still active within
# double-quoted strings.
sed_quote_subst='s/\([["`$\\]]\)/\\\1/g'
# Same as above, but do not quote variable references.
double_quote_subst='s/\([["`\\]]\)/\\\1/g'
# Sed substitution to delay expansion of an escaped shell variable in a
# double_quote_subst'ed string.
delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
# Sed substitution to delay expansion of an escaped single quote.
delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
# Sed substitution to avoid accidental globbing in evaled expressions
no_glob_subst='s/\*/\\\*/g'
])
# _LT_PROG_LTMAIN
# ---------------
# Note that this code is called both from `configure', and `config.status'
# now that we use AC_CONFIG_COMMANDS to generate libtool. Notably,
# `config.status' has no value for ac_aux_dir unless we are using Automake,
# so we pass a copy along to make sure it has a sensible value anyway.
m4_defun([_LT_PROG_LTMAIN],
[m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl
_LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir'])
ltmain="$ac_aux_dir/ltmain.sh"
])# _LT_PROG_LTMAIN
## ------------------------------------- ##
## Accumulate code for creating libtool. ##
## ------------------------------------- ##
# So that we can recreate a full libtool script including additional
# tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS
# in macros and then make a single call at the end using the `libtool'
# label.
# _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS])
# ----------------------------------------
# Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later.
m4_define([_LT_CONFIG_LIBTOOL_INIT],
[m4_ifval([$1],
[m4_append([_LT_OUTPUT_LIBTOOL_INIT],
[$1
])])])
# Initialize.
m4_define([_LT_OUTPUT_LIBTOOL_INIT])
# _LT_CONFIG_LIBTOOL([COMMANDS])
# ------------------------------
# Register COMMANDS to be passed to AC_CONFIG_COMMANDS later.
m4_define([_LT_CONFIG_LIBTOOL],
[m4_ifval([$1],
[m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS],
[$1
])])])
# Initialize.
m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS])
# _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS])
# -----------------------------------------------------
m4_defun([_LT_CONFIG_SAVE_COMMANDS],
[_LT_CONFIG_LIBTOOL([$1])
_LT_CONFIG_LIBTOOL_INIT([$2])
])
# _LT_FORMAT_COMMENT([COMMENT])
# -----------------------------
# Add leading comment marks to the start of each line, and a trailing
# full-stop to the whole comment if one is not present already.
m4_define([_LT_FORMAT_COMMENT],
[m4_ifval([$1], [
m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])],
[['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.])
)])
## ------------------------ ##
## FIXME: Eliminate VARNAME ##
## ------------------------ ##
# _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?])
# -------------------------------------------------------------------
# CONFIGNAME is the name given to the value in the libtool script.
# VARNAME is the (base) name used in the configure script.
# VALUE may be 0, 1 or 2 for a computed quote escaped value based on
# VARNAME. Any other value will be used directly.
m4_define([_LT_DECL],
[lt_if_append_uniq([lt_decl_varnames], [$2], [, ],
[lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name],
[m4_ifval([$1], [$1], [$2])])
lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3])
m4_ifval([$4],
[lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])])
lt_dict_add_subkey([lt_decl_dict], [$2],
[tagged?], [m4_ifval([$5], [yes], [no])])])
])
# _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION])
# --------------------------------------------------------
m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])])
# lt_decl_tag_varnames([SEPARATOR], [VARNAME1...])
# ------------------------------------------------
m4_define([lt_decl_tag_varnames],
[_lt_decl_filter([tagged?], [yes], $@)])
# _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..])
# ---------------------------------------------------------
m4_define([_lt_decl_filter],
[m4_case([$#],
[0], [m4_fatal([$0: too few arguments: $#])],
[1], [m4_fatal([$0: too few arguments: $#: $1])],
[2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)],
[3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)],
[lt_dict_filter([lt_decl_dict], $@)])[]dnl
])
# lt_decl_quote_varnames([SEPARATOR], [VARNAME1...])
# --------------------------------------------------
m4_define([lt_decl_quote_varnames],
[_lt_decl_filter([value], [1], $@)])
# lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...])
# ---------------------------------------------------
m4_define([lt_decl_dquote_varnames],
[_lt_decl_filter([value], [2], $@)])
# lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...])
# ---------------------------------------------------
m4_define([lt_decl_varnames_tagged],
[m4_assert([$# <= 2])dnl
_$0(m4_quote(m4_default([$1], [[, ]])),
m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]),
m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))])
m4_define([_lt_decl_varnames_tagged],
[m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])])
# lt_decl_all_varnames([SEPARATOR], [VARNAME1...])
# ------------------------------------------------
m4_define([lt_decl_all_varnames],
[_$0(m4_quote(m4_default([$1], [[, ]])),
m4_if([$2], [],
m4_quote(lt_decl_varnames),
m4_quote(m4_shift($@))))[]dnl
])
m4_define([_lt_decl_all_varnames],
[lt_join($@, lt_decl_varnames_tagged([$1],
lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl
])
# _LT_CONFIG_STATUS_DECLARE([VARNAME])
# ------------------------------------
# Quote a variable value, and forward it to `config.status' so that its
# declaration there will have the same value as in `configure'. VARNAME
# must have a single quote delimited value for this to work.
m4_define([_LT_CONFIG_STATUS_DECLARE],
[$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`'])
# _LT_CONFIG_STATUS_DECLARATIONS
# ------------------------------
# We delimit libtool config variables with single quotes, so when
# we write them to config.status, we have to be sure to quote all
# embedded single quotes properly. In configure, this macro expands
# each variable declared with _LT_DECL (and _LT_TAGDECL) into:
#
# ='`$ECHO "$" | $SED "$delay_single_quote_subst"`'
m4_defun([_LT_CONFIG_STATUS_DECLARATIONS],
[m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames),
[m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])])
# _LT_LIBTOOL_TAGS
# ----------------
# Output comment and list of tags supported by the script
m4_defun([_LT_LIBTOOL_TAGS],
[_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl
available_tags="_LT_TAGS"dnl
])
# _LT_LIBTOOL_DECLARE(VARNAME, [TAG])
# -----------------------------------
# Extract the dictionary values for VARNAME (optionally with TAG) and
# expand to a commented shell variable setting:
#
# # Some comment about what VAR is for.
# visible_name=$lt_internal_name
m4_define([_LT_LIBTOOL_DECLARE],
[_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1],
[description])))[]dnl
m4_pushdef([_libtool_name],
m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl
m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])),
[0], [_libtool_name=[$]$1],
[1], [_libtool_name=$lt_[]$1],
[2], [_libtool_name=$lt_[]$1],
[_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl
m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl
])
# _LT_LIBTOOL_CONFIG_VARS
# -----------------------
# Produce commented declarations of non-tagged libtool config variables
# suitable for insertion in the LIBTOOL CONFIG section of the `libtool'
# script. Tagged libtool config variables (even for the LIBTOOL CONFIG
# section) are produced by _LT_LIBTOOL_TAG_VARS.
m4_defun([_LT_LIBTOOL_CONFIG_VARS],
[m4_foreach([_lt_var],
m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)),
[m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])])
# _LT_LIBTOOL_TAG_VARS(TAG)
# -------------------------
m4_define([_LT_LIBTOOL_TAG_VARS],
[m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames),
[m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])])
# _LT_TAGVAR(VARNAME, [TAGNAME])
# ------------------------------
m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])])
# _LT_CONFIG_COMMANDS
# -------------------
# Send accumulated output to $CONFIG_STATUS. Thanks to the lists of
# variables for single and double quote escaping we saved from calls
# to _LT_DECL, we can put quote escaped variables declarations
# into `config.status', and then the shell code to quote escape them in
# for loops in `config.status'. Finally, any additional code accumulated
# from calls to _LT_CONFIG_LIBTOOL_INIT is expanded.
m4_defun([_LT_CONFIG_COMMANDS],
[AC_PROVIDE_IFELSE([LT_OUTPUT],
dnl If the libtool generation code has been placed in $CONFIG_LT,
dnl instead of duplicating it all over again into config.status,
dnl then we will have config.status run $CONFIG_LT later, so it
dnl needs to know what name is stored there:
[AC_CONFIG_COMMANDS([libtool],
[$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])],
dnl If the libtool generation code is destined for config.status,
dnl expand the accumulated commands and init code now:
[AC_CONFIG_COMMANDS([libtool],
[_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])])
])#_LT_CONFIG_COMMANDS
# Initialize.
m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT],
[
# The HP-UX ksh and POSIX shell print the target directory to stdout
# if CDPATH is set.
(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
sed_quote_subst='$sed_quote_subst'
double_quote_subst='$double_quote_subst'
delay_variable_subst='$delay_variable_subst'
_LT_CONFIG_STATUS_DECLARATIONS
LTCC='$LTCC'
LTCFLAGS='$LTCFLAGS'
compiler='$compiler_DEFAULT'
# A function that is used when there is no print builtin or printf.
func_fallback_echo ()
{
eval 'cat <<_LTECHO_EOF
\$[]1
_LTECHO_EOF'
}
# Quote evaled strings.
for var in lt_decl_all_varnames([[ \
]], lt_decl_quote_varnames); do
case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
*[[\\\\\\\`\\"\\\$]]*)
eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
;;
*)
eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
;;
esac
done
# Double-quote double-evaled strings.
for var in lt_decl_all_varnames([[ \
]], lt_decl_dquote_varnames); do
case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
*[[\\\\\\\`\\"\\\$]]*)
eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
;;
*)
eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
;;
esac
done
_LT_OUTPUT_LIBTOOL_INIT
])
# _LT_GENERATED_FILE_INIT(FILE, [COMMENT])
# ------------------------------------
# Generate a child script FILE with all initialization necessary to
# reuse the environment learned by the parent script, and make the
# file executable. If COMMENT is supplied, it is inserted after the
# `#!' sequence but before initialization text begins. After this
# macro, additional text can be appended to FILE to form the body of
# the child script. The macro ends with non-zero status if the
# file could not be fully written (such as if the disk is full).
m4_ifdef([AS_INIT_GENERATED],
[m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])],
[m4_defun([_LT_GENERATED_FILE_INIT],
[m4_require([AS_PREPARE])]dnl
[m4_pushdef([AS_MESSAGE_LOG_FD])]dnl
[lt_write_fail=0
cat >$1 <<_ASEOF || lt_write_fail=1
#! $SHELL
# Generated by $as_me.
$2
SHELL=\${CONFIG_SHELL-$SHELL}
export SHELL
_ASEOF
cat >>$1 <<\_ASEOF || lt_write_fail=1
AS_SHELL_SANITIZE
_AS_PREPARE
exec AS_MESSAGE_FD>&1
_ASEOF
test $lt_write_fail = 0 && chmod +x $1[]dnl
m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT
# LT_OUTPUT
# ---------
# This macro allows early generation of the libtool script (before
# AC_OUTPUT is called), incase it is used in configure for compilation
# tests.
AC_DEFUN([LT_OUTPUT],
[: ${CONFIG_LT=./config.lt}
AC_MSG_NOTICE([creating $CONFIG_LT])
_LT_GENERATED_FILE_INIT(["$CONFIG_LT"],
[# Run this file to recreate a libtool stub with the current configuration.])
cat >>"$CONFIG_LT" <<\_LTEOF
lt_cl_silent=false
exec AS_MESSAGE_LOG_FD>>config.log
{
echo
AS_BOX([Running $as_me.])
} >&AS_MESSAGE_LOG_FD
lt_cl_help="\
\`$as_me' creates a local libtool stub from the current configuration,
for use in further configure time tests before the real libtool is
generated.
Usage: $[0] [[OPTIONS]]
-h, --help print this help, then exit
-V, --version print version number, then exit
-q, --quiet do not print progress messages
-d, --debug don't remove temporary files
Report bugs to ."
lt_cl_version="\
m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl
m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION])
configured by $[0], generated by m4_PACKAGE_STRING.
Copyright (C) 2011 Free Software Foundation, Inc.
This config.lt script is free software; the Free Software Foundation
gives unlimited permision to copy, distribute and modify it."
while test $[#] != 0
do
case $[1] in
--version | --v* | -V )
echo "$lt_cl_version"; exit 0 ;;
--help | --h* | -h )
echo "$lt_cl_help"; exit 0 ;;
--debug | --d* | -d )
debug=: ;;
--quiet | --q* | --silent | --s* | -q )
lt_cl_silent=: ;;
-*) AC_MSG_ERROR([unrecognized option: $[1]
Try \`$[0] --help' for more information.]) ;;
*) AC_MSG_ERROR([unrecognized argument: $[1]
Try \`$[0] --help' for more information.]) ;;
esac
shift
done
if $lt_cl_silent; then
exec AS_MESSAGE_FD>/dev/null
fi
_LTEOF
cat >>"$CONFIG_LT" <<_LTEOF
_LT_OUTPUT_LIBTOOL_COMMANDS_INIT
_LTEOF
cat >>"$CONFIG_LT" <<\_LTEOF
AC_MSG_NOTICE([creating $ofile])
_LT_OUTPUT_LIBTOOL_COMMANDS
AS_EXIT(0)
_LTEOF
chmod +x "$CONFIG_LT"
# configure is writing to config.log, but config.lt does its own redirection,
# appending to config.log, which fails on DOS, as config.log is still kept
# open by configure. Here we exec the FD to /dev/null, effectively closing
# config.log, so it can be properly (re)opened and appended to by config.lt.
lt_cl_success=:
test "$silent" = yes &&
lt_config_lt_args="$lt_config_lt_args --quiet"
exec AS_MESSAGE_LOG_FD>/dev/null
$SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false
exec AS_MESSAGE_LOG_FD>>config.log
$lt_cl_success || AS_EXIT(1)
])# LT_OUTPUT
# _LT_CONFIG(TAG)
# ---------------
# If TAG is the built-in tag, create an initial libtool script with a
# default configuration from the untagged config vars. Otherwise add code
# to config.status for appending the configuration named by TAG from the
# matching tagged config vars.
m4_defun([_LT_CONFIG],
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
_LT_CONFIG_SAVE_COMMANDS([
m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl
m4_if(_LT_TAG, [C], [
# See if we are running on zsh, and set the options which allow our
# commands through without removal of \ escapes.
if test -n "${ZSH_VERSION+set}" ; then
setopt NO_GLOB_SUBST
fi
cfgfile="${ofile}T"
trap "$RM \"$cfgfile\"; exit 1" 1 2 15
$RM "$cfgfile"
cat <<_LT_EOF >> "$cfgfile"
#! $SHELL
# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
# NOTE: Changes made to this file will be lost: look at ltmain.sh.
#
_LT_COPYING
_LT_LIBTOOL_TAGS
# ### BEGIN LIBTOOL CONFIG
_LT_LIBTOOL_CONFIG_VARS
_LT_LIBTOOL_TAG_VARS
# ### END LIBTOOL CONFIG
_LT_EOF
case $host_os in
aix3*)
cat <<\_LT_EOF >> "$cfgfile"
# AIX sometimes has problems with the GCC collect2 program. For some
# reason, if we set the COLLECT_NAMES environment variable, the problems
# vanish in a puff of smoke.
if test "X${COLLECT_NAMES+set}" != Xset; then
COLLECT_NAMES=
export COLLECT_NAMES
fi
_LT_EOF
;;
esac
_LT_PROG_LTMAIN
# We use sed instead of cat because bash on DJGPP gets confused if
# if finds mixed CR/LF and LF-only lines. Since sed operates in
# text mode, it properly converts lines to CR/LF. This bash problem
# is reportedly fixed, but why not run on old versions too?
sed '$q' "$ltmain" >> "$cfgfile" \
|| (rm -f "$cfgfile"; exit 1)
_LT_PROG_REPLACE_SHELLFNS
mv -f "$cfgfile" "$ofile" ||
(rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
chmod +x "$ofile"
],
[cat <<_LT_EOF >> "$ofile"
dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded
dnl in a comment (ie after a #).
# ### BEGIN LIBTOOL TAG CONFIG: $1
_LT_LIBTOOL_TAG_VARS(_LT_TAG)
# ### END LIBTOOL TAG CONFIG: $1
_LT_EOF
])dnl /m4_if
],
[m4_if([$1], [], [
PACKAGE='$PACKAGE'
VERSION='$VERSION'
TIMESTAMP='$TIMESTAMP'
RM='$RM'
ofile='$ofile'], [])
])dnl /_LT_CONFIG_SAVE_COMMANDS
])# _LT_CONFIG
# LT_SUPPORTED_TAG(TAG)
# ---------------------
# Trace this macro to discover what tags are supported by the libtool
# --tag option, using:
# autoconf --trace 'LT_SUPPORTED_TAG:$1'
AC_DEFUN([LT_SUPPORTED_TAG], [])
# C support is built-in for now
m4_define([_LT_LANG_C_enabled], [])
m4_define([_LT_TAGS], [])
# LT_LANG(LANG)
# -------------
# Enable libtool support for the given language if not already enabled.
AC_DEFUN([LT_LANG],
[AC_BEFORE([$0], [LT_OUTPUT])dnl
m4_case([$1],
[C], [_LT_LANG(C)],
[C++], [_LT_LANG(CXX)],
[Go], [_LT_LANG(GO)],
[Java], [_LT_LANG(GCJ)],
[Fortran 77], [_LT_LANG(F77)],
[Fortran], [_LT_LANG(FC)],
[Windows Resource], [_LT_LANG(RC)],
[m4_ifdef([_LT_LANG_]$1[_CONFIG],
[_LT_LANG($1)],
[m4_fatal([$0: unsupported language: "$1"])])])dnl
])# LT_LANG
# _LT_LANG(LANGNAME)
# ------------------
m4_defun([_LT_LANG],
[m4_ifdef([_LT_LANG_]$1[_enabled], [],
[LT_SUPPORTED_TAG([$1])dnl
m4_append([_LT_TAGS], [$1 ])dnl
m4_define([_LT_LANG_]$1[_enabled], [])dnl
_LT_LANG_$1_CONFIG($1)])dnl
])# _LT_LANG
m4_ifndef([AC_PROG_GO], [
############################################################
# NOTE: This macro has been submitted for inclusion into #
# GNU Autoconf as AC_PROG_GO. When it is available in #
# a released version of Autoconf we should remove this #
# macro and use it instead. #
############################################################
m4_defun([AC_PROG_GO],
[AC_LANG_PUSH(Go)dnl
AC_ARG_VAR([GOC], [Go compiler command])dnl
AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl
_AC_ARG_VAR_LDFLAGS()dnl
AC_CHECK_TOOL(GOC, gccgo)
if test -z "$GOC"; then
if test -n "$ac_tool_prefix"; then
AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo])
fi
fi
if test -z "$GOC"; then
AC_CHECK_PROG(GOC, gccgo, gccgo, false)
fi
])#m4_defun
])#m4_ifndef
# _LT_LANG_DEFAULT_CONFIG
# -----------------------
m4_defun([_LT_LANG_DEFAULT_CONFIG],
[AC_PROVIDE_IFELSE([AC_PROG_CXX],
[LT_LANG(CXX)],
[m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])])
AC_PROVIDE_IFELSE([AC_PROG_F77],
[LT_LANG(F77)],
[m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])])
AC_PROVIDE_IFELSE([AC_PROG_FC],
[LT_LANG(FC)],
[m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])])
dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal
dnl pulling things in needlessly.
AC_PROVIDE_IFELSE([AC_PROG_GCJ],
[LT_LANG(GCJ)],
[AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
[LT_LANG(GCJ)],
[AC_PROVIDE_IFELSE([LT_PROG_GCJ],
[LT_LANG(GCJ)],
[m4_ifdef([AC_PROG_GCJ],
[m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])])
m4_ifdef([A][M_PROG_GCJ],
[m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])])
m4_ifdef([LT_PROG_GCJ],
[m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])])
AC_PROVIDE_IFELSE([AC_PROG_GO],
[LT_LANG(GO)],
[m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])])
AC_PROVIDE_IFELSE([LT_PROG_RC],
[LT_LANG(RC)],
[m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])])
])# _LT_LANG_DEFAULT_CONFIG
# Obsolete macros:
AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)])
AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)])
AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)])
AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)])
AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_LIBTOOL_CXX], [])
dnl AC_DEFUN([AC_LIBTOOL_F77], [])
dnl AC_DEFUN([AC_LIBTOOL_FC], [])
dnl AC_DEFUN([AC_LIBTOOL_GCJ], [])
dnl AC_DEFUN([AC_LIBTOOL_RC], [])
# _LT_TAG_COMPILER
# ----------------
m4_defun([_LT_TAG_COMPILER],
[AC_REQUIRE([AC_PROG_CC])dnl
_LT_DECL([LTCC], [CC], [1], [A C compiler])dnl
_LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl
_LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl
_LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl
# If no C compiler was specified, use CC.
LTCC=${LTCC-"$CC"}
# If no C compiler flags were specified, use CFLAGS.
LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
# Allow CC to be a program name with arguments.
compiler=$CC
])# _LT_TAG_COMPILER
# _LT_COMPILER_BOILERPLATE
# ------------------------
# Check for compiler boilerplate output or warnings with
# the simple compiler test code.
m4_defun([_LT_COMPILER_BOILERPLATE],
[m4_require([_LT_DECL_SED])dnl
ac_outfile=conftest.$ac_objext
echo "$lt_simple_compile_test_code" >conftest.$ac_ext
eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
_lt_compiler_boilerplate=`cat conftest.err`
$RM conftest*
])# _LT_COMPILER_BOILERPLATE
# _LT_LINKER_BOILERPLATE
# ----------------------
# Check for linker boilerplate output or warnings with
# the simple link test code.
m4_defun([_LT_LINKER_BOILERPLATE],
[m4_require([_LT_DECL_SED])dnl
ac_outfile=conftest.$ac_objext
echo "$lt_simple_link_test_code" >conftest.$ac_ext
eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
_lt_linker_boilerplate=`cat conftest.err`
$RM -r conftest*
])# _LT_LINKER_BOILERPLATE
# _LT_REQUIRED_DARWIN_CHECKS
# -------------------------
m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[
case $host_os in
rhapsody* | darwin*)
AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
AC_CHECK_TOOL([LIPO], [lipo], [:])
AC_CHECK_TOOL([OTOOL], [otool], [:])
AC_CHECK_TOOL([OTOOL64], [otool64], [:])
_LT_DECL([], [DSYMUTIL], [1],
[Tool to manipulate archived DWARF debug symbol files on Mac OS X])
_LT_DECL([], [NMEDIT], [1],
[Tool to change global to local symbols on Mac OS X])
_LT_DECL([], [LIPO], [1],
[Tool to manipulate fat objects and archives on Mac OS X])
_LT_DECL([], [OTOOL], [1],
[ldd/readelf like tool for Mach-O binaries on Mac OS X])
_LT_DECL([], [OTOOL64], [1],
[ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4])
AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
[lt_cv_apple_cc_single_mod=no
if test -z "${LT_MULTI_MODULE}"; then
# By default we will add the -single_module flag. You can override
# by either setting the environment variable LT_MULTI_MODULE
# non-empty at configure time, or by adding -multi_module to the
# link flags.
rm -rf libconftest.dylib*
echo "int foo(void){return 1;}" > conftest.c
echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD
$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
-dynamiclib -Wl,-single_module conftest.c 2>conftest.err
_lt_result=$?
# If there is a non-empty error log, and "single_module"
# appears in it, assume the flag caused a linker warning
if test -s conftest.err && $GREP single_module conftest.err; then
cat conftest.err >&AS_MESSAGE_LOG_FD
# Otherwise, if the output was created with a 0 exit code from
# the compiler, it worked.
elif test -f libconftest.dylib && test $_lt_result -eq 0; then
lt_cv_apple_cc_single_mod=yes
else
cat conftest.err >&AS_MESSAGE_LOG_FD
fi
rm -rf libconftest.dylib*
rm -f conftest.*
fi])
AC_CACHE_CHECK([for -exported_symbols_list linker flag],
[lt_cv_ld_exported_symbols_list],
[lt_cv_ld_exported_symbols_list=no
save_LDFLAGS=$LDFLAGS
echo "_main" > conftest.sym
LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
[lt_cv_ld_exported_symbols_list=yes],
[lt_cv_ld_exported_symbols_list=no])
LDFLAGS="$save_LDFLAGS"
])
AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load],
[lt_cv_ld_force_load=no
cat > conftest.c << _LT_EOF
int forced_loaded() { return 2;}
_LT_EOF
echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD
$LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD
echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD
$AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD
echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD
$RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD
cat > conftest.c << _LT_EOF
int main() { return 0;}
_LT_EOF
echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD
$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
_lt_result=$?
if test -s conftest.err && $GREP force_load conftest.err; then
cat conftest.err >&AS_MESSAGE_LOG_FD
elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
lt_cv_ld_force_load=yes
else
cat conftest.err >&AS_MESSAGE_LOG_FD
fi
rm -f conftest.err libconftest.a conftest conftest.c
rm -rf conftest.dSYM
])
case $host_os in
rhapsody* | darwin1.[[012]])
_lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
darwin1.*)
_lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
darwin*) # darwin 5.x on
# if running on 10.5 or later, the deployment target defaults
# to the OS version, if on x86, and 10.4, the deployment
# target defaults to 10.4. Don't you love it?
case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
_lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
10.[[012]]*)
_lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
10.*)
_lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
esac
;;
esac
if test "$lt_cv_apple_cc_single_mod" = "yes"; then
_lt_dar_single_mod='$single_module'
fi
if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
_lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
else
_lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
fi
if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
_lt_dsymutil='~$DSYMUTIL $lib || :'
else
_lt_dsymutil=
fi
;;
esac
])
# _LT_DARWIN_LINKER_FEATURES([TAG])
# ---------------------------------
# Checks for linker and compiler features on darwin
m4_defun([_LT_DARWIN_LINKER_FEATURES],
[
m4_require([_LT_REQUIRED_DARWIN_CHECKS])
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_automatic, $1)=yes
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
if test "$lt_cv_ld_force_load" = "yes"; then
_LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes],
[FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes])
else
_LT_TAGVAR(whole_archive_flag_spec, $1)=''
fi
_LT_TAGVAR(link_all_deplibs, $1)=yes
_LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
case $cc_basename in
ifort*) _lt_dar_can_shared=yes ;;
*) _lt_dar_can_shared=$GCC ;;
esac
if test "$_lt_dar_can_shared" = "yes"; then
output_verbose_link_cmd=func_echo_all
_LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
_LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
_LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
_LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
m4_if([$1], [CXX],
[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then
_LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
_LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
fi
],[])
else
_LT_TAGVAR(ld_shlibs, $1)=no
fi
])
# _LT_SYS_MODULE_PATH_AIX([TAGNAME])
# ----------------------------------
# Links a minimal program and checks the executable
# for the system default hardcoded library path. In most cases,
# this is /usr/lib:/lib, but when the MPI compilers are used
# the location of the communication and MPI libs are included too.
# If we don't find anything, use the default library path according
# to the aix ld manual.
# Store the results from the different compilers for each TAGNAME.
# Allow to override them for all tags through lt_cv_aix_libpath.
m4_defun([_LT_SYS_MODULE_PATH_AIX],
[m4_require([_LT_DECL_SED])dnl
if test "${lt_cv_aix_libpath+set}" = set; then
aix_libpath=$lt_cv_aix_libpath
else
AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])],
[AC_LINK_IFELSE([AC_LANG_PROGRAM],[
lt_aix_libpath_sed='[
/Import File Strings/,/^$/ {
/^0/ {
s/^0 *\([^ ]*\) *$/\1/
p
}
}]'
_LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
# Check for a 64-bit object if we didn't find anything.
if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
_LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
fi],[])
if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then
_LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib"
fi
])
aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])
fi
])# _LT_SYS_MODULE_PATH_AIX
# _LT_SHELL_INIT(ARG)
# -------------------
m4_define([_LT_SHELL_INIT],
[m4_divert_text([M4SH-INIT], [$1
])])# _LT_SHELL_INIT
# _LT_PROG_ECHO_BACKSLASH
# -----------------------
# Find how we can fake an echo command that does not interpret backslash.
# In particular, with Autoconf 2.60 or later we add some code to the start
# of the generated configure script which will find a shell with a builtin
# printf (which we can use as an echo command).
m4_defun([_LT_PROG_ECHO_BACKSLASH],
[ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
AC_MSG_CHECKING([how to print strings])
# Test print first, because it will be a builtin if present.
if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
ECHO='print -r --'
elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
ECHO='printf %s\n'
else
# Use this function as a fallback that always works.
func_fallback_echo ()
{
eval 'cat <<_LTECHO_EOF
$[]1
_LTECHO_EOF'
}
ECHO='func_fallback_echo'
fi
# func_echo_all arg...
# Invoke $ECHO with all args, space-separated.
func_echo_all ()
{
$ECHO "$*"
}
case "$ECHO" in
printf*) AC_MSG_RESULT([printf]) ;;
print*) AC_MSG_RESULT([print -r]) ;;
*) AC_MSG_RESULT([cat]) ;;
esac
m4_ifdef([_AS_DETECT_SUGGESTED],
[_AS_DETECT_SUGGESTED([
test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || (
ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
PATH=/empty FPATH=/empty; export PATH FPATH
test "X`printf %s $ECHO`" = "X$ECHO" \
|| test "X`print -r -- $ECHO`" = "X$ECHO" )])])
_LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts])
_LT_DECL([], [ECHO], [1], [An echo program that protects backslashes])
])# _LT_PROG_ECHO_BACKSLASH
# _LT_WITH_SYSROOT
# ----------------
AC_DEFUN([_LT_WITH_SYSROOT],
[AC_MSG_CHECKING([for sysroot])
AC_ARG_WITH([sysroot],
[ --with-sysroot[=DIR] Search for dependent libraries within DIR
(or the compiler's sysroot if not specified).],
[], [with_sysroot=no])
dnl lt_sysroot will always be passed unquoted. We quote it here
dnl in case the user passed a directory name.
lt_sysroot=
case ${with_sysroot} in #(
yes)
if test "$GCC" = yes; then
lt_sysroot=`$CC --print-sysroot 2>/dev/null`
fi
;; #(
/*)
lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
;; #(
no|'')
;; #(
*)
AC_MSG_RESULT([${with_sysroot}])
AC_MSG_ERROR([The sysroot must be an absolute path.])
;;
esac
AC_MSG_RESULT([${lt_sysroot:-no}])
_LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl
[dependent libraries, and in which our libraries should be installed.])])
# _LT_ENABLE_LOCK
# ---------------
m4_defun([_LT_ENABLE_LOCK],
[AC_ARG_ENABLE([libtool-lock],
[AS_HELP_STRING([--disable-libtool-lock],
[avoid locking (might break parallel builds)])])
test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
# Some flags need to be propagated to the compiler or linker for good
# libtool support.
case $host in
ia64-*-hpux*)
# Find out which ABI we are using.
echo 'int i;' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
case `/usr/bin/file conftest.$ac_objext` in
*ELF-32*)
HPUX_IA64_MODE="32"
;;
*ELF-64*)
HPUX_IA64_MODE="64"
;;
esac
fi
rm -rf conftest*
;;
*-*-irix6*)
# Find out which ABI we are using.
echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
if test "$lt_cv_prog_gnu_ld" = yes; then
case `/usr/bin/file conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -melf32bsmip"
;;
*N32*)
LD="${LD-ld} -melf32bmipn32"
;;
*64-bit*)
LD="${LD-ld} -melf64bmip"
;;
esac
else
case `/usr/bin/file conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -32"
;;
*N32*)
LD="${LD-ld} -n32"
;;
*64-bit*)
LD="${LD-ld} -64"
;;
esac
fi
fi
rm -rf conftest*
;;
x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
# Find out which ABI we are using.
echo 'int i;' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
case `/usr/bin/file conftest.o` in
*32-bit*)
case $host in
x86_64-*kfreebsd*-gnu)
LD="${LD-ld} -m elf_i386_fbsd"
;;
x86_64-*linux*)
LD="${LD-ld} -m elf_i386"
;;
ppc64-*linux*|powerpc64-*linux*)
LD="${LD-ld} -m elf32ppclinux"
;;
s390x-*linux*)
LD="${LD-ld} -m elf_s390"
;;
sparc64-*linux*)
LD="${LD-ld} -m elf32_sparc"
;;
esac
;;
*64-bit*)
case $host in
x86_64-*kfreebsd*-gnu)
LD="${LD-ld} -m elf_x86_64_fbsd"
;;
x86_64-*linux*)
LD="${LD-ld} -m elf_x86_64"
;;
ppc*-*linux*|powerpc*-*linux*)
LD="${LD-ld} -m elf64ppc"
;;
s390*-*linux*|s390*-*tpf*)
LD="${LD-ld} -m elf64_s390"
;;
sparc*-*linux*)
LD="${LD-ld} -m elf64_sparc"
;;
esac
;;
esac
fi
rm -rf conftest*
;;
*-*-sco3.2v5*)
# On SCO OpenServer 5, we need -belf to get full-featured binaries.
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -belf"
AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
[AC_LANG_PUSH(C)
AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
AC_LANG_POP])
if test x"$lt_cv_cc_needs_belf" != x"yes"; then
# this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
CFLAGS="$SAVE_CFLAGS"
fi
;;
*-*solaris*)
# Find out which ABI we are using.
echo 'int i;' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
case `/usr/bin/file conftest.o` in
*64-bit*)
case $lt_cv_prog_gnu_ld in
yes*)
case $host in
i?86-*-solaris*)
LD="${LD-ld} -m elf_x86_64"
;;
sparc*-*-solaris*)
LD="${LD-ld} -m elf64_sparc"
;;
esac
# GNU ld 2.21 introduced _sol2 emulations. Use them if available.
if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
LD="${LD-ld}_sol2"
fi
;;
*)
if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
LD="${LD-ld} -64"
fi
;;
esac
;;
esac
fi
rm -rf conftest*
;;
esac
need_locks="$enable_libtool_lock"
])# _LT_ENABLE_LOCK
# _LT_PROG_AR
# -----------
m4_defun([_LT_PROG_AR],
[AC_CHECK_TOOLS(AR, [ar], false)
: ${AR=ar}
: ${AR_FLAGS=cru}
_LT_DECL([], [AR], [1], [The archiver])
_LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive])
AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file],
[lt_cv_ar_at_file=no
AC_COMPILE_IFELSE([AC_LANG_PROGRAM],
[echo conftest.$ac_objext > conftest.lst
lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD'
AC_TRY_EVAL([lt_ar_try])
if test "$ac_status" -eq 0; then
# Ensure the archiver fails upon bogus file names.
rm -f conftest.$ac_objext libconftest.a
AC_TRY_EVAL([lt_ar_try])
if test "$ac_status" -ne 0; then
lt_cv_ar_at_file=@
fi
fi
rm -f conftest.* libconftest.a
])
])
if test "x$lt_cv_ar_at_file" = xno; then
archiver_list_spec=
else
archiver_list_spec=$lt_cv_ar_at_file
fi
_LT_DECL([], [archiver_list_spec], [1],
[How to feed a file listing to the archiver])
])# _LT_PROG_AR
# _LT_CMD_OLD_ARCHIVE
# -------------------
m4_defun([_LT_CMD_OLD_ARCHIVE],
[_LT_PROG_AR
AC_CHECK_TOOL(STRIP, strip, :)
test -z "$STRIP" && STRIP=:
_LT_DECL([], [STRIP], [1], [A symbol stripping program])
AC_CHECK_TOOL(RANLIB, ranlib, :)
test -z "$RANLIB" && RANLIB=:
_LT_DECL([], [RANLIB], [1],
[Commands used to install an old-style archive])
# Determine commands to create old-style static archives.
old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
old_postinstall_cmds='chmod 644 $oldlib'
old_postuninstall_cmds=
if test -n "$RANLIB"; then
case $host_os in
openbsd*)
old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
;;
*)
old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
;;
esac
old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
fi
case $host_os in
darwin*)
lock_old_archive_extraction=yes ;;
*)
lock_old_archive_extraction=no ;;
esac
_LT_DECL([], [old_postinstall_cmds], [2])
_LT_DECL([], [old_postuninstall_cmds], [2])
_LT_TAGDECL([], [old_archive_cmds], [2],
[Commands used to build an old-style archive])
_LT_DECL([], [lock_old_archive_extraction], [0],
[Whether to use a lock for old archive extraction])
])# _LT_CMD_OLD_ARCHIVE
# _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
# [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE])
# ----------------------------------------------------------------
# Check whether the given compiler option works
AC_DEFUN([_LT_COMPILER_OPTION],
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
m4_require([_LT_DECL_SED])dnl
AC_CACHE_CHECK([$1], [$2],
[$2=no
m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
lt_compiler_flag="$3"
# Insert the option either (1) after the last *FLAGS variable, or
# (2) before a word containing "conftest.", or (3) at the end.
# Note that $ac_compile itself does not contain backslashes and begins
# with a dollar sign (not a hyphen), so the echo should work correctly.
# The option is referenced via a variable to avoid confusing sed.
lt_compile=`echo "$ac_compile" | $SED \
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&AS_MESSAGE_LOG_FD
echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
$ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
$SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
$2=yes
fi
fi
$RM conftest*
])
if test x"[$]$2" = xyes; then
m4_if([$5], , :, [$5])
else
m4_if([$6], , :, [$6])
fi
])# _LT_COMPILER_OPTION
# Old name:
AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [])
# _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS,
# [ACTION-SUCCESS], [ACTION-FAILURE])
# ----------------------------------------------------
# Check whether the given linker option works
AC_DEFUN([_LT_LINKER_OPTION],
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
m4_require([_LT_DECL_SED])dnl
AC_CACHE_CHECK([$1], [$2],
[$2=no
save_LDFLAGS="$LDFLAGS"
LDFLAGS="$LDFLAGS $3"
echo "$lt_simple_link_test_code" > conftest.$ac_ext
if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
# The linker can only warn and ignore the option if not recognized
# So say no if there are warnings
if test -s conftest.err; then
# Append any errors to the config.log.
cat conftest.err 1>&AS_MESSAGE_LOG_FD
$ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
$SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
if diff conftest.exp conftest.er2 >/dev/null; then
$2=yes
fi
else
$2=yes
fi
fi
$RM -r conftest*
LDFLAGS="$save_LDFLAGS"
])
if test x"[$]$2" = xyes; then
m4_if([$4], , :, [$4])
else
m4_if([$5], , :, [$5])
fi
])# _LT_LINKER_OPTION
# Old name:
AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [])
# LT_CMD_MAX_LEN
#---------------
AC_DEFUN([LT_CMD_MAX_LEN],
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
# find the maximum length of command line arguments
AC_MSG_CHECKING([the maximum length of command line arguments])
AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
i=0
teststring="ABCD"
case $build_os in
msdosdjgpp*)
# On DJGPP, this test can blow up pretty badly due to problems in libc
# (any single argument exceeding 2000 bytes causes a buffer overrun
# during glob expansion). Even if it were fixed, the result of this
# check would be larger than it should be.
lt_cv_sys_max_cmd_len=12288; # 12K is about right
;;
gnu*)
# Under GNU Hurd, this test is not required because there is
# no limit to the length of command line arguments.
# Libtool will interpret -1 as no limit whatsoever
lt_cv_sys_max_cmd_len=-1;
;;
cygwin* | mingw* | cegcc*)
# On Win9x/ME, this test blows up -- it succeeds, but takes
# about 5 minutes as the teststring grows exponentially.
# Worse, since 9x/ME are not pre-emptively multitasking,
# you end up with a "frozen" computer, even though with patience
# the test eventually succeeds (with a max line length of 256k).
# Instead, let's just punt: use the minimum linelength reported by
# all of the supported platforms: 8192 (on NT/2K/XP).
lt_cv_sys_max_cmd_len=8192;
;;
mint*)
# On MiNT this can take a long time and run out of memory.
lt_cv_sys_max_cmd_len=8192;
;;
amigaos*)
# On AmigaOS with pdksh, this test takes hours, literally.
# So we just punt and use a minimum line length of 8192.
lt_cv_sys_max_cmd_len=8192;
;;
netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
# This has been around since 386BSD, at least. Likely further.
if test -x /sbin/sysctl; then
lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
elif test -x /usr/sbin/sysctl; then
lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
else
lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
fi
# And add a safety zone
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
;;
interix*)
# We know the value 262144 and hardcode it with a safety zone (like BSD)
lt_cv_sys_max_cmd_len=196608
;;
os2*)
# The test takes a long time on OS/2.
lt_cv_sys_max_cmd_len=8192
;;
osf*)
# Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
# due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
# nice to cause kernel panics so lets avoid the loop below.
# First set a reasonable default.
lt_cv_sys_max_cmd_len=16384
#
if test -x /sbin/sysconfig; then
case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
*1*) lt_cv_sys_max_cmd_len=-1 ;;
esac
fi
;;
sco3.2v5*)
lt_cv_sys_max_cmd_len=102400
;;
sysv5* | sco5v6* | sysv4.2uw2*)
kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
if test -n "$kargmax"; then
lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'`
else
lt_cv_sys_max_cmd_len=32768
fi
;;
*)
lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
if test -n "$lt_cv_sys_max_cmd_len"; then
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
else
# Make teststring a little bigger before we do anything with it.
# a 1K string should be a reasonable start.
for i in 1 2 3 4 5 6 7 8 ; do
teststring=$teststring$teststring
done
SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
# If test is not a shell built-in, we'll probably end up computing a
# maximum length that is only half of the actual maximum length, but
# we can't tell.
while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
= "X$teststring$teststring"; } >/dev/null 2>&1 &&
test $i != 17 # 1/2 MB should be enough
do
i=`expr $i + 1`
teststring=$teststring$teststring
done
# Only check the string length outside the loop.
lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
teststring=
# Add a significant safety factor because C++ compilers can tack on
# massive amounts of additional arguments before passing them to the
# linker. It appears as though 1/2 is a usable value.
lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
fi
;;
esac
])
if test -n $lt_cv_sys_max_cmd_len ; then
AC_MSG_RESULT($lt_cv_sys_max_cmd_len)
else
AC_MSG_RESULT(none)
fi
max_cmd_len=$lt_cv_sys_max_cmd_len
_LT_DECL([], [max_cmd_len], [0],
[What is the maximum length of a command?])
])# LT_CMD_MAX_LEN
# Old name:
AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [])
# _LT_HEADER_DLFCN
# ----------------
m4_defun([_LT_HEADER_DLFCN],
[AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl
])# _LT_HEADER_DLFCN
# _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
# ----------------------------------------------------------------
m4_defun([_LT_TRY_DLOPEN_SELF],
[m4_require([_LT_HEADER_DLFCN])dnl
if test "$cross_compiling" = yes; then :
[$4]
else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<_LT_EOF
[#line $LINENO "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
#include
#endif
#include
#ifdef RTLD_GLOBAL
# define LT_DLGLOBAL RTLD_GLOBAL
#else
# ifdef DL_GLOBAL
# define LT_DLGLOBAL DL_GLOBAL
# else
# define LT_DLGLOBAL 0
# endif
#endif
/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
find out it does not work in some platform. */
#ifndef LT_DLLAZY_OR_NOW
# ifdef RTLD_LAZY
# define LT_DLLAZY_OR_NOW RTLD_LAZY
# else
# ifdef DL_LAZY
# define LT_DLLAZY_OR_NOW DL_LAZY
# else
# ifdef RTLD_NOW
# define LT_DLLAZY_OR_NOW RTLD_NOW
# else
# ifdef DL_NOW
# define LT_DLLAZY_OR_NOW DL_NOW
# else
# define LT_DLLAZY_OR_NOW 0
# endif
# endif
# endif
# endif
#endif
/* When -fvisbility=hidden is used, assume the code has been annotated
correspondingly for the symbols needed. */
#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
int fnord () __attribute__((visibility("default")));
#endif
int fnord () { return 42; }
int main ()
{
void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
int status = $lt_dlunknown;
if (self)
{
if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
else
{
if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
else puts (dlerror ());
}
/* dlclose (self); */
}
else
puts (dlerror ());
return status;
}]
_LT_EOF
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
(./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null
lt_status=$?
case x$lt_status in
x$lt_dlno_uscore) $1 ;;
x$lt_dlneed_uscore) $2 ;;
x$lt_dlunknown|x*) $3 ;;
esac
else :
# compilation failed
$3
fi
fi
rm -fr conftest*
])# _LT_TRY_DLOPEN_SELF
# LT_SYS_DLOPEN_SELF
# ------------------
AC_DEFUN([LT_SYS_DLOPEN_SELF],
[m4_require([_LT_HEADER_DLFCN])dnl
if test "x$enable_dlopen" != xyes; then
enable_dlopen=unknown
enable_dlopen_self=unknown
enable_dlopen_self_static=unknown
else
lt_cv_dlopen=no
lt_cv_dlopen_libs=
case $host_os in
beos*)
lt_cv_dlopen="load_add_on"
lt_cv_dlopen_libs=
lt_cv_dlopen_self=yes
;;
mingw* | pw32* | cegcc*)
lt_cv_dlopen="LoadLibrary"
lt_cv_dlopen_libs=
;;
cygwin*)
lt_cv_dlopen="dlopen"
lt_cv_dlopen_libs=
;;
darwin*)
# if libdl is installed we need to link against it
AC_CHECK_LIB([dl], [dlopen],
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[
lt_cv_dlopen="dyld"
lt_cv_dlopen_libs=
lt_cv_dlopen_self=yes
])
;;
*)
AC_CHECK_FUNC([shl_load],
[lt_cv_dlopen="shl_load"],
[AC_CHECK_LIB([dld], [shl_load],
[lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
[AC_CHECK_FUNC([dlopen],
[lt_cv_dlopen="dlopen"],
[AC_CHECK_LIB([dl], [dlopen],
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
[AC_CHECK_LIB([svld], [dlopen],
[lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
[AC_CHECK_LIB([dld], [dld_link],
[lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
])
])
])
])
])
;;
esac
if test "x$lt_cv_dlopen" != xno; then
enable_dlopen=yes
else
enable_dlopen=no
fi
case $lt_cv_dlopen in
dlopen)
save_CPPFLAGS="$CPPFLAGS"
test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
save_LDFLAGS="$LDFLAGS"
wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
save_LIBS="$LIBS"
LIBS="$lt_cv_dlopen_libs $LIBS"
AC_CACHE_CHECK([whether a program can dlopen itself],
lt_cv_dlopen_self, [dnl
_LT_TRY_DLOPEN_SELF(
lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
])
if test "x$lt_cv_dlopen_self" = xyes; then
wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
lt_cv_dlopen_self_static, [dnl
_LT_TRY_DLOPEN_SELF(
lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
])
fi
CPPFLAGS="$save_CPPFLAGS"
LDFLAGS="$save_LDFLAGS"
LIBS="$save_LIBS"
;;
esac
case $lt_cv_dlopen_self in
yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
*) enable_dlopen_self=unknown ;;
esac
case $lt_cv_dlopen_self_static in
yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
*) enable_dlopen_self_static=unknown ;;
esac
fi
_LT_DECL([dlopen_support], [enable_dlopen], [0],
[Whether dlopen is supported])
_LT_DECL([dlopen_self], [enable_dlopen_self], [0],
[Whether dlopen of programs is supported])
_LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0],
[Whether dlopen of statically linked programs is supported])
])# LT_SYS_DLOPEN_SELF
# Old name:
AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [])
# _LT_COMPILER_C_O([TAGNAME])
# ---------------------------
# Check to see if options -c and -o are simultaneously supported by compiler.
# This macro does not hard code the compiler like AC_PROG_CC_C_O.
m4_defun([_LT_COMPILER_C_O],
[m4_require([_LT_DECL_SED])dnl
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
m4_require([_LT_TAG_COMPILER])dnl
AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
[_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
[_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
$RM -r conftest 2>/dev/null
mkdir conftest
cd conftest
mkdir out
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
lt_compiler_flag="-o out/conftest2.$ac_objext"
# Insert the option either (1) after the last *FLAGS variable, or
# (2) before a word containing "conftest.", or (3) at the end.
# Note that $ac_compile itself does not contain backslashes and begins
# with a dollar sign (not a hyphen), so the echo should work correctly.
lt_compile=`echo "$ac_compile" | $SED \
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&AS_MESSAGE_LOG_FD
echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings
$ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
$SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
fi
fi
chmod u+w . 2>&AS_MESSAGE_LOG_FD
$RM conftest*
# SGI C++ compiler will create directory out/ii_files/ for
# template instantiation
test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
$RM out/* && rmdir out
cd ..
$RM -r conftest
$RM conftest*
])
_LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1],
[Does compiler simultaneously support -c and -o options?])
])# _LT_COMPILER_C_O
# _LT_COMPILER_FILE_LOCKS([TAGNAME])
# ----------------------------------
# Check to see if we can do hard links to lock some files if needed
m4_defun([_LT_COMPILER_FILE_LOCKS],
[m4_require([_LT_ENABLE_LOCK])dnl
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
_LT_COMPILER_C_O([$1])
hard_links="nottested"
if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then
# do not overwrite the value of need_locks provided by the user
AC_MSG_CHECKING([if we can lock with hard links])
hard_links=yes
$RM conftest*
ln conftest.a conftest.b 2>/dev/null && hard_links=no
touch conftest.a
ln conftest.a conftest.b 2>&5 || hard_links=no
ln conftest.a conftest.b 2>/dev/null && hard_links=no
AC_MSG_RESULT([$hard_links])
if test "$hard_links" = no; then
AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe])
need_locks=warn
fi
else
need_locks=no
fi
_LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?])
])# _LT_COMPILER_FILE_LOCKS
# _LT_CHECK_OBJDIR
# ----------------
m4_defun([_LT_CHECK_OBJDIR],
[AC_CACHE_CHECK([for objdir], [lt_cv_objdir],
[rm -f .libs 2>/dev/null
mkdir .libs 2>/dev/null
if test -d .libs; then
lt_cv_objdir=.libs
else
# MS-DOS does not allow filenames that begin with a dot.
lt_cv_objdir=_libs
fi
rmdir .libs 2>/dev/null])
objdir=$lt_cv_objdir
_LT_DECL([], [objdir], [0],
[The name of the directory that contains temporary libtool files])dnl
m4_pattern_allow([LT_OBJDIR])dnl
AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/",
[Define to the sub-directory in which libtool stores uninstalled libraries.])
])# _LT_CHECK_OBJDIR
# _LT_LINKER_HARDCODE_LIBPATH([TAGNAME])
# --------------------------------------
# Check hardcoding attributes.
m4_defun([_LT_LINKER_HARDCODE_LIBPATH],
[AC_MSG_CHECKING([how to hardcode library paths into programs])
_LT_TAGVAR(hardcode_action, $1)=
if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" ||
test -n "$_LT_TAGVAR(runpath_var, $1)" ||
test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then
# We can hardcode non-existent directories.
if test "$_LT_TAGVAR(hardcode_direct, $1)" != no &&
# If the only mechanism to avoid hardcoding is shlibpath_var, we
# have to relink, otherwise we might link with an installed library
# when we should be linking with a yet-to-be-installed one
## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no &&
test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then
# Linking always hardcodes the temporary library directory.
_LT_TAGVAR(hardcode_action, $1)=relink
else
# We can link without hardcoding, and we can hardcode nonexisting dirs.
_LT_TAGVAR(hardcode_action, $1)=immediate
fi
else
# We cannot hardcode anything, or else we can only hardcode existing
# directories.
_LT_TAGVAR(hardcode_action, $1)=unsupported
fi
AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)])
if test "$_LT_TAGVAR(hardcode_action, $1)" = relink ||
test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then
# Fast installation is not supported
enable_fast_install=no
elif test "$shlibpath_overrides_runpath" = yes ||
test "$enable_shared" = no; then
# Fast installation is not necessary
enable_fast_install=needless
fi
_LT_TAGDECL([], [hardcode_action], [0],
[How to hardcode a shared library path into an executable])
])# _LT_LINKER_HARDCODE_LIBPATH
# _LT_CMD_STRIPLIB
# ----------------
m4_defun([_LT_CMD_STRIPLIB],
[m4_require([_LT_DECL_EGREP])
striplib=
old_striplib=
AC_MSG_CHECKING([whether stripping libraries is possible])
if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
test -z "$striplib" && striplib="$STRIP --strip-unneeded"
AC_MSG_RESULT([yes])
else
# FIXME - insert some real tests, host_os isn't really good enough
case $host_os in
darwin*)
if test -n "$STRIP" ; then
striplib="$STRIP -x"
old_striplib="$STRIP -S"
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
fi
;;
*)
AC_MSG_RESULT([no])
;;
esac
fi
_LT_DECL([], [old_striplib], [1], [Commands to strip libraries])
_LT_DECL([], [striplib], [1])
])# _LT_CMD_STRIPLIB
# _LT_SYS_DYNAMIC_LINKER([TAG])
# -----------------------------
# PORTME Fill in your ld.so characteristics
m4_defun([_LT_SYS_DYNAMIC_LINKER],
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
m4_require([_LT_DECL_EGREP])dnl
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
m4_require([_LT_DECL_OBJDUMP])dnl
m4_require([_LT_DECL_SED])dnl
m4_require([_LT_CHECK_SHELL_FEATURES])dnl
AC_MSG_CHECKING([dynamic linker characteristics])
m4_if([$1],
[], [
if test "$GCC" = yes; then
case $host_os in
darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
*) lt_awk_arg="/^libraries:/" ;;
esac
case $host_os in
mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;;
*) lt_sed_strip_eq="s,=/,/,g" ;;
esac
lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
case $lt_search_path_spec in
*\;*)
# if the path contains ";" then we assume it to be the separator
# otherwise default to the standard path separator (i.e. ":") - it is
# assumed that no part of a normal pathname contains ";" but that should
# okay in the real world where ";" in dirpaths is itself problematic.
lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
;;
*)
lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
;;
esac
# Ok, now we have the path, separated by spaces, we can step through it
# and add multilib dir if necessary.
lt_tmp_lt_search_path_spec=
lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
for lt_sys_path in $lt_search_path_spec; do
if test -d "$lt_sys_path/$lt_multi_os_dir"; then
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
else
test -d "$lt_sys_path" && \
lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
fi
done
lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
BEGIN {RS=" "; FS="/|\n";} {
lt_foo="";
lt_count=0;
for (lt_i = NF; lt_i > 0; lt_i--) {
if ($lt_i != "" && $lt_i != ".") {
if ($lt_i == "..") {
lt_count++;
} else {
if (lt_count == 0) {
lt_foo="/" $lt_i lt_foo;
} else {
lt_count--;
}
}
}
}
if (lt_foo != "") { lt_freq[[lt_foo]]++; }
if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
}'`
# AWK program above erroneously prepends '/' to C:/dos/paths
# for these hosts.
case $host_os in
mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
$SED 's,/\([[A-Za-z]]:\),\1,g'` ;;
esac
sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
else
sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
fi])
library_names_spec=
libname_spec='lib$name'
soname_spec=
shrext_cmds=".so"
postinstall_cmds=
postuninstall_cmds=
finish_cmds=
finish_eval=
shlibpath_var=
shlibpath_overrides_runpath=unknown
version_type=none
dynamic_linker="$host_os ld.so"
sys_lib_dlsearch_path_spec="/lib /usr/lib"
need_lib_prefix=unknown
hardcode_into_libs=no
# when you set need_version to no, make sure it does not cause -set_version
# flags to be left without arguments
need_version=unknown
case $host_os in
aix3*)
version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
shlibpath_var=LIBPATH
# AIX 3 has no versioning support, so we append a major version to the name.
soname_spec='${libname}${release}${shared_ext}$major'
;;
aix[[4-9]]*)
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
hardcode_into_libs=yes
if test "$host_cpu" = ia64; then
# AIX 5 supports IA64
library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
shlibpath_var=LD_LIBRARY_PATH
else
# With GCC up to 2.95.x, collect2 would create an import file
# for dependence libraries. The import file would start with
# the line `#! .'. This would cause the generated library to
# depend on `.', always an invalid library. This was fixed in
# development snapshots of GCC prior to 3.0.
case $host_os in
aix4 | aix4.[[01]] | aix4.[[01]].*)
if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
echo ' yes '
echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
:
else
can_build_shared=no
fi
;;
esac
# AIX (on Power*) has no versioning support, so currently we can not hardcode correct
# soname into executable. Probably we can add versioning support to
# collect2, so additional links can be useful in future.
if test "$aix_use_runtimelinking" = yes; then
# If using run time linking (on AIX 4.2 or later) use lib.so
# instead of lib.a to let people know that these are not
# typical AIX shared libraries.
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
else
# We preserve .a as extension for shared libraries through AIX4.2
# and later when we are not doing run time linking.
library_names_spec='${libname}${release}.a $libname.a'
soname_spec='${libname}${release}${shared_ext}$major'
fi
shlibpath_var=LIBPATH
fi
;;
amigaos*)
case $host_cpu in
powerpc)
# Since July 2007 AmigaOS4 officially supports .so libraries.
# When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
;;
m68k)
library_names_spec='$libname.ixlibrary $libname.a'
# Create ${libname}_ixlibrary.a entries in /sys/libs.
finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
;;
esac
;;
beos*)
library_names_spec='${libname}${shared_ext}'
dynamic_linker="$host_os ld.so"
shlibpath_var=LIBRARY_PATH
;;
bsdi[[45]]*)
version_type=linux # correct to gnu/linux during the next big refactor
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
shlibpath_var=LD_LIBRARY_PATH
sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
# the default ld.so.conf also contains /usr/contrib/lib and
# /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
# libtool to hard-code these into programs
;;
cygwin* | mingw* | pw32* | cegcc*)
version_type=windows
shrext_cmds=".dll"
need_version=no
need_lib_prefix=no
case $GCC,$cc_basename in
yes,*)
# gcc
library_names_spec='$libname.dll.a'
# DLL is installed to $(libdir)/../bin by postinstall_cmds
postinstall_cmds='base_file=`basename \${file}`~
dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
dldir=$destdir/`dirname \$dlpath`~
test -d \$dldir || mkdir -p \$dldir~
$install_prog $dir/$dlname \$dldir/$dlname~
chmod a+x \$dldir/$dlname~
if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
fi'
postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
dlpath=$dir/\$dldll~
$RM \$dlpath'
shlibpath_overrides_runpath=yes
case $host_os in
cygwin*)
# Cygwin DLLs use 'cyg' prefix rather than 'lib'
soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
m4_if([$1], [],[
sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"])
;;
mingw* | cegcc*)
# MinGW DLLs use traditional 'lib' prefix
soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
;;
pw32*)
# pw32 DLLs use 'pw' prefix rather than 'lib'
library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
;;
esac
dynamic_linker='Win32 ld.exe'
;;
*,cl*)
# Native MSVC
libname_spec='$name'
soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}'
library_names_spec='${libname}.dll.lib'
case $build_os in
mingw*)
sys_lib_search_path_spec=
lt_save_ifs=$IFS
IFS=';'
for lt_path in $LIB
do
IFS=$lt_save_ifs
# Let DOS variable expansion print the short 8.3 style file name.
lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
done
IFS=$lt_save_ifs
# Convert to MSYS style.
sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'`
;;
cygwin*)
# Convert to unix form, then to dos form, then back to unix form
# but this time dos style (no spaces!) so that the unix form looks
# like /cygdrive/c/PROGRA~1:/cygdr...
sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
;;
*)
sys_lib_search_path_spec="$LIB"
if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then
# It is most probably a Windows format PATH.
sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
else
sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
fi
# FIXME: find the short name or the path components, as spaces are
# common. (e.g. "Program Files" -> "PROGRA~1")
;;
esac
# DLL is installed to $(libdir)/../bin by postinstall_cmds
postinstall_cmds='base_file=`basename \${file}`~
dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
dldir=$destdir/`dirname \$dlpath`~
test -d \$dldir || mkdir -p \$dldir~
$install_prog $dir/$dlname \$dldir/$dlname'
postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
dlpath=$dir/\$dldll~
$RM \$dlpath'
shlibpath_overrides_runpath=yes
dynamic_linker='Win32 link.exe'
;;
*)
# Assume MSVC wrapper
library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib'
dynamic_linker='Win32 ld.exe'
;;
esac
# FIXME: first we should search . and the directory the executable is in
shlibpath_var=PATH
;;
darwin* | rhapsody*)
dynamic_linker="$host_os dyld"
version_type=darwin
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
soname_spec='${libname}${release}${major}$shared_ext'
shlibpath_overrides_runpath=yes
shlibpath_var=DYLD_LIBRARY_PATH
shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
m4_if([$1], [],[
sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"])
sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
;;
dgux*)
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
;;
freebsd* | dragonfly*)
# DragonFly does not have aout. When/if they implement a new
# versioning mechanism, adjust this.
if test -x /usr/bin/objformat; then
objformat=`/usr/bin/objformat`
else
case $host_os in
freebsd[[23]].*) objformat=aout ;;
*) objformat=elf ;;
esac
fi
version_type=freebsd-$objformat
case $version_type in
freebsd-elf*)
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
need_version=no
need_lib_prefix=no
;;
freebsd-*)
library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
need_version=yes
;;
esac
shlibpath_var=LD_LIBRARY_PATH
case $host_os in
freebsd2.*)
shlibpath_overrides_runpath=yes
;;
freebsd3.[[01]]* | freebsdelf3.[[01]]*)
shlibpath_overrides_runpath=yes
hardcode_into_libs=yes
;;
freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
shlibpath_overrides_runpath=no
hardcode_into_libs=yes
;;
*) # from 4.6 on, and DragonFly
shlibpath_overrides_runpath=yes
hardcode_into_libs=yes
;;
esac
;;
gnu*)
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=no
hardcode_into_libs=yes
;;
haiku*)
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
dynamic_linker="$host_os runtime_loader"
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LIBRARY_PATH
shlibpath_overrides_runpath=yes
sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
hardcode_into_libs=yes
;;
hpux9* | hpux10* | hpux11*)
# Give a soname corresponding to the major version so that dld.sl refuses to
# link against other versions.
version_type=sunos
need_lib_prefix=no
need_version=no
case $host_cpu in
ia64*)
shrext_cmds='.so'
hardcode_into_libs=yes
dynamic_linker="$host_os dld.so"
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
if test "X$HPUX_IA64_MODE" = X32; then
sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
else
sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
fi
sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
;;
hppa*64*)
shrext_cmds='.sl'
hardcode_into_libs=yes
dynamic_linker="$host_os dld.sl"
shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
;;
*)
shrext_cmds='.sl'
dynamic_linker="$host_os dld.sl"
shlibpath_var=SHLIB_PATH
shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
;;
esac
# HP-UX runs *really* slowly unless shared libraries are mode 555, ...
postinstall_cmds='chmod 555 $lib'
# or fails outright, so override atomically:
install_override_mode=555
;;
interix[[3-9]]*)
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=no
hardcode_into_libs=yes
;;
irix5* | irix6* | nonstopux*)
case $host_os in
nonstopux*) version_type=nonstopux ;;
*)
if test "$lt_cv_prog_gnu_ld" = yes; then
version_type=linux # correct to gnu/linux during the next big refactor
else
version_type=irix
fi ;;
esac
need_lib_prefix=no
need_version=no
soname_spec='${libname}${release}${shared_ext}$major'
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
case $host_os in
irix5* | nonstopux*)
libsuff= shlibsuff=
;;
*)
case $LD in # libtool.m4 will add one of these switches to LD
*-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
libsuff= shlibsuff= libmagic=32-bit;;
*-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
libsuff=32 shlibsuff=N32 libmagic=N32;;
*-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
libsuff=64 shlibsuff=64 libmagic=64-bit;;
*) libsuff= shlibsuff= libmagic=never-match;;
esac
;;
esac
shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
shlibpath_overrides_runpath=no
sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
hardcode_into_libs=yes
;;
# No shared lib support for Linux oldld, aout, or coff.
linux*oldld* | linux*aout* | linux*coff*)
dynamic_linker=no
;;
# This must be glibc/ELF.
linux* | k*bsd*-gnu | kopensolaris*-gnu)
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=no
# Some binutils ld are patched to set DT_RUNPATH
AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath],
[lt_cv_shlibpath_overrides_runpath=no
save_LDFLAGS=$LDFLAGS
save_libdir=$libdir
eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \
LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\""
AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])],
[AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null],
[lt_cv_shlibpath_overrides_runpath=yes])])
LDFLAGS=$save_LDFLAGS
libdir=$save_libdir
])
shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
# This implies no fast_install, which is unacceptable.
# Some rework will be needed to allow for fast_install
# before this can be enabled.
hardcode_into_libs=yes
# Append ld.so.conf contents to the search path
if test -f /etc/ld.so.conf; then
lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
fi
# We used to test for /lib/ld.so.1 and disable shared libraries on
# powerpc, because MkLinux only supported shared libraries with the
# GNU dynamic linker. Since this was broken with cross compilers,
# most powerpc-linux boxes support dynamic linking these days and
# people can always --disable-shared, the test was removed, and we
# assume the GNU/Linux dynamic linker is in use.
dynamic_linker='GNU/Linux ld.so'
;;
netbsdelf*-gnu)
version_type=linux
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=no
hardcode_into_libs=yes
dynamic_linker='NetBSD ld.elf_so'
;;
netbsd*)
version_type=sunos
need_lib_prefix=no
need_version=no
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
dynamic_linker='NetBSD (a.out) ld.so'
else
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
dynamic_linker='NetBSD ld.elf_so'
fi
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=yes
hardcode_into_libs=yes
;;
newsos6)
version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=yes
;;
*nto* | *qnx*)
version_type=qnx
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=no
hardcode_into_libs=yes
dynamic_linker='ldqnx.so'
;;
openbsd*)
version_type=sunos
sys_lib_dlsearch_path_spec="/usr/lib"
need_lib_prefix=no
# Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
case $host_os in
openbsd3.3 | openbsd3.3.*) need_version=yes ;;
*) need_version=no ;;
esac
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
shlibpath_var=LD_LIBRARY_PATH
if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
case $host_os in
openbsd2.[[89]] | openbsd2.[[89]].*)
shlibpath_overrides_runpath=no
;;
*)
shlibpath_overrides_runpath=yes
;;
esac
else
shlibpath_overrides_runpath=yes
fi
;;
os2*)
libname_spec='$name'
shrext_cmds=".dll"
need_lib_prefix=no
library_names_spec='$libname${shared_ext} $libname.a'
dynamic_linker='OS/2 ld.exe'
shlibpath_var=LIBPATH
;;
osf3* | osf4* | osf5*)
version_type=osf
need_lib_prefix=no
need_version=no
soname_spec='${libname}${release}${shared_ext}$major'
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
shlibpath_var=LD_LIBRARY_PATH
sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
;;
rdos*)
dynamic_linker=no
;;
solaris*)
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=yes
hardcode_into_libs=yes
# ldd complains unless libraries are executable
postinstall_cmds='chmod +x $lib'
;;
sunos4*)
version_type=sunos
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=yes
if test "$with_gnu_ld" = yes; then
need_lib_prefix=no
fi
need_version=yes
;;
sysv4 | sysv4.3*)
version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
case $host_vendor in
sni)
shlibpath_overrides_runpath=no
need_lib_prefix=no
runpath_var=LD_RUN_PATH
;;
siemens)
need_lib_prefix=no
;;
motorola)
need_lib_prefix=no
need_version=no
shlibpath_overrides_runpath=no
sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
;;
esac
;;
sysv4*MP*)
if test -d /usr/nec ;then
version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
soname_spec='$libname${shared_ext}.$major'
shlibpath_var=LD_LIBRARY_PATH
fi
;;
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
version_type=freebsd-elf
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=yes
hardcode_into_libs=yes
if test "$with_gnu_ld" = yes; then
sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
else
sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
case $host_os in
sco3.2v5*)
sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
;;
esac
fi
sys_lib_dlsearch_path_spec='/usr/lib'
;;
tpf*)
# TPF is a cross-target only. Preferred cross-host = GNU/Linux.
version_type=linux # correct to gnu/linux during the next big refactor
need_lib_prefix=no
need_version=no
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=no
hardcode_into_libs=yes
;;
uts4*)
version_type=linux # correct to gnu/linux during the next big refactor
library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
soname_spec='${libname}${release}${shared_ext}$major'
shlibpath_var=LD_LIBRARY_PATH
;;
*)
dynamic_linker=no
;;
esac
AC_MSG_RESULT([$dynamic_linker])
test "$dynamic_linker" = no && can_build_shared=no
variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
if test "$GCC" = yes; then
variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
fi
if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
fi
if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
fi
_LT_DECL([], [variables_saved_for_relink], [1],
[Variables whose values should be saved in libtool wrapper scripts and
restored at link time])
_LT_DECL([], [need_lib_prefix], [0],
[Do we need the "lib" prefix for modules?])
_LT_DECL([], [need_version], [0], [Do we need a version for libraries?])
_LT_DECL([], [version_type], [0], [Library versioning type])
_LT_DECL([], [runpath_var], [0], [Shared library runtime path variable])
_LT_DECL([], [shlibpath_var], [0],[Shared library path variable])
_LT_DECL([], [shlibpath_overrides_runpath], [0],
[Is shlibpath searched before the hard-coded library search path?])
_LT_DECL([], [libname_spec], [1], [Format of library name prefix])
_LT_DECL([], [library_names_spec], [1],
[[List of archive names. First name is the real one, the rest are links.
The last name is the one that the linker finds with -lNAME]])
_LT_DECL([], [soname_spec], [1],
[[The coded name of the library, if different from the real name]])
_LT_DECL([], [install_override_mode], [1],
[Permission mode override for installation of shared libraries])
_LT_DECL([], [postinstall_cmds], [2],
[Command to use after installation of a shared archive])
_LT_DECL([], [postuninstall_cmds], [2],
[Command to use after uninstallation of a shared archive])
_LT_DECL([], [finish_cmds], [2],
[Commands used to finish a libtool library installation in a directory])
_LT_DECL([], [finish_eval], [1],
[[As "finish_cmds", except a single script fragment to be evaled but
not shown]])
_LT_DECL([], [hardcode_into_libs], [0],
[Whether we should hardcode library paths into libraries])
_LT_DECL([], [sys_lib_search_path_spec], [2],
[Compile-time system search path for libraries])
_LT_DECL([], [sys_lib_dlsearch_path_spec], [2],
[Run-time system search path for libraries])
])# _LT_SYS_DYNAMIC_LINKER
# _LT_PATH_TOOL_PREFIX(TOOL)
# --------------------------
# find a file program which can recognize shared library
AC_DEFUN([_LT_PATH_TOOL_PREFIX],
[m4_require([_LT_DECL_EGREP])dnl
AC_MSG_CHECKING([for $1])
AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
[case $MAGIC_CMD in
[[\\/*] | ?:[\\/]*])
lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
;;
*)
lt_save_MAGIC_CMD="$MAGIC_CMD"
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
dnl $ac_dummy forces splitting on constant user-supplied paths.
dnl POSIX.2 word splitting is done only on the output of word expansions,
dnl not every word. This closes a longstanding sh security hole.
ac_dummy="m4_if([$2], , $PATH, [$2])"
for ac_dir in $ac_dummy; do
IFS="$lt_save_ifs"
test -z "$ac_dir" && ac_dir=.
if test -f $ac_dir/$1; then
lt_cv_path_MAGIC_CMD="$ac_dir/$1"
if test -n "$file_magic_test_file"; then
case $deplibs_check_method in
"file_magic "*)
file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
$EGREP "$file_magic_regex" > /dev/null; then
:
else
cat <<_LT_EOF 1>&2
*** Warning: the command libtool uses to detect shared libraries,
*** $file_magic_cmd, produces output that libtool cannot recognize.
*** The result is that libtool may fail to recognize shared libraries
*** as such. This will affect the creation of libtool libraries that
*** depend on shared libraries, but programs linked with such libtool
*** libraries will work regardless of this problem. Nevertheless, you
*** may want to report the problem to your system manager and/or to
*** bug-libtool@gnu.org
_LT_EOF
fi ;;
esac
fi
break
fi
done
IFS="$lt_save_ifs"
MAGIC_CMD="$lt_save_MAGIC_CMD"
;;
esac])
MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
if test -n "$MAGIC_CMD"; then
AC_MSG_RESULT($MAGIC_CMD)
else
AC_MSG_RESULT(no)
fi
_LT_DECL([], [MAGIC_CMD], [0],
[Used to examine libraries when file_magic_cmd begins with "file"])dnl
])# _LT_PATH_TOOL_PREFIX
# Old name:
AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], [])
# _LT_PATH_MAGIC
# --------------
# find a file program which can recognize a shared library
m4_defun([_LT_PATH_MAGIC],
[_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
if test -z "$lt_cv_path_MAGIC_CMD"; then
if test -n "$ac_tool_prefix"; then
_LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH)
else
MAGIC_CMD=:
fi
fi
])# _LT_PATH_MAGIC
# LT_PATH_LD
# ----------
# find the pathname to the GNU or non-GNU linker
AC_DEFUN([LT_PATH_LD],
[AC_REQUIRE([AC_PROG_CC])dnl
AC_REQUIRE([AC_CANONICAL_HOST])dnl
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
m4_require([_LT_DECL_SED])dnl
m4_require([_LT_DECL_EGREP])dnl
m4_require([_LT_PROG_ECHO_BACKSLASH])dnl
AC_ARG_WITH([gnu-ld],
[AS_HELP_STRING([--with-gnu-ld],
[assume the C compiler uses GNU ld @<:@default=no@:>@])],
[test "$withval" = no || with_gnu_ld=yes],
[with_gnu_ld=no])dnl
ac_prog=ld
if test "$GCC" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
AC_MSG_CHECKING([for ld used by $CC])
case $host in
*-*-mingw*)
# gcc leaves a trailing carriage return which upsets mingw
ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
*)
ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
esac
case $ac_prog in
# Accept absolute paths.
[[\\/]]* | ?:[[\\/]]*)
re_direlt='/[[^/]][[^/]]*/\.\./'
# Canonicalize the pathname of ld
ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
done
test -z "$LD" && LD="$ac_prog"
;;
"")
# If it fails, then pretend we aren't using GCC.
ac_prog=ld
;;
*)
# If it is relative, then search for the first ld in PATH.
with_gnu_ld=unknown
;;
esac
elif test "$with_gnu_ld" = yes; then
AC_MSG_CHECKING([for GNU ld])
else
AC_MSG_CHECKING([for non-GNU ld])
fi
AC_CACHE_VAL(lt_cv_path_LD,
[if test -z "$LD"; then
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
for ac_dir in $PATH; do
IFS="$lt_save_ifs"
test -z "$ac_dir" && ac_dir=.
if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
lt_cv_path_LD="$ac_dir/$ac_prog"
# Check to see if the program is GNU ld. I'd rather use --version,
# but apparently some variants of GNU ld only accept -v.
# Break only if it was the GNU/non-GNU ld that we prefer.
case `"$lt_cv_path_LD" -v 2>&1 &1 /dev/null 2>&1; then
lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
lt_cv_file_magic_cmd='func_win32_libid'
else
# Keep this pattern in sync with the one in func_win32_libid.
lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
lt_cv_file_magic_cmd='$OBJDUMP -f'
fi
;;
cegcc*)
# use the weaker test based on 'objdump'. See mingw*.
lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
lt_cv_file_magic_cmd='$OBJDUMP -f'
;;
darwin* | rhapsody*)
lt_cv_deplibs_check_method=pass_all
;;
freebsd* | dragonfly*)
if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
case $host_cpu in
i*86 )
# Not sure whether the presence of OpenBSD here was a mistake.
# Let's accept both of them until this is cleared up.
lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library'
lt_cv_file_magic_cmd=/usr/bin/file
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
;;
esac
else
lt_cv_deplibs_check_method=pass_all
fi
;;
gnu*)
lt_cv_deplibs_check_method=pass_all
;;
haiku*)
lt_cv_deplibs_check_method=pass_all
;;
hpux10.20* | hpux11*)
lt_cv_file_magic_cmd=/usr/bin/file
case $host_cpu in
ia64*)
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64'
lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
;;
hppa*64*)
[lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]']
lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
;;
*)
lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library'
lt_cv_file_magic_test_file=/usr/lib/libc.sl
;;
esac
;;
interix[[3-9]]*)
# PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
;;
irix5* | irix6* | nonstopux*)
case $LD in
*-32|*"-32 ") libmagic=32-bit;;
*-n32|*"-n32 ") libmagic=N32;;
*-64|*"-64 ") libmagic=64-bit;;
*) libmagic=never-match;;
esac
lt_cv_deplibs_check_method=pass_all
;;
# This must be glibc/ELF.
linux* | k*bsd*-gnu | kopensolaris*-gnu)
lt_cv_deplibs_check_method=pass_all
;;
netbsd* | netbsdelf*-gnu)
if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
else
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$'
fi
;;
newos6*)
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
lt_cv_file_magic_cmd=/usr/bin/file
lt_cv_file_magic_test_file=/usr/lib/libnls.so
;;
*nto* | *qnx*)
lt_cv_deplibs_check_method=pass_all
;;
openbsd*)
if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$'
else
lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$'
fi
;;
osf3* | osf4* | osf5*)
lt_cv_deplibs_check_method=pass_all
;;
rdos*)
lt_cv_deplibs_check_method=pass_all
;;
solaris*)
lt_cv_deplibs_check_method=pass_all
;;
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
lt_cv_deplibs_check_method=pass_all
;;
sysv4 | sysv4.3*)
case $host_vendor in
motorola)
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]'
lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
;;
ncr)
lt_cv_deplibs_check_method=pass_all
;;
sequent)
lt_cv_file_magic_cmd='/bin/file'
lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
;;
sni)
lt_cv_file_magic_cmd='/bin/file'
lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
lt_cv_file_magic_test_file=/lib/libc.so
;;
siemens)
lt_cv_deplibs_check_method=pass_all
;;
pc)
lt_cv_deplibs_check_method=pass_all
;;
esac
;;
tpf*)
lt_cv_deplibs_check_method=pass_all
;;
esac
])
file_magic_glob=
want_nocaseglob=no
if test "$build" = "$host"; then
case $host_os in
mingw* | pw32*)
if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
want_nocaseglob=yes
else
file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"`
fi
;;
esac
fi
file_magic_cmd=$lt_cv_file_magic_cmd
deplibs_check_method=$lt_cv_deplibs_check_method
test -z "$deplibs_check_method" && deplibs_check_method=unknown
_LT_DECL([], [deplibs_check_method], [1],
[Method to check whether dependent libraries are shared objects])
_LT_DECL([], [file_magic_cmd], [1],
[Command to use when deplibs_check_method = "file_magic"])
_LT_DECL([], [file_magic_glob], [1],
[How to find potential files when deplibs_check_method = "file_magic"])
_LT_DECL([], [want_nocaseglob], [1],
[Find potential files using nocaseglob when deplibs_check_method = "file_magic"])
])# _LT_CHECK_MAGIC_METHOD
# LT_PATH_NM
# ----------
# find the pathname to a BSD- or MS-compatible name lister
AC_DEFUN([LT_PATH_NM],
[AC_REQUIRE([AC_PROG_CC])dnl
AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM,
[if test -n "$NM"; then
# Let the user override the test.
lt_cv_path_NM="$NM"
else
lt_nm_to_check="${ac_tool_prefix}nm"
if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
lt_nm_to_check="$lt_nm_to_check nm"
fi
for lt_tmp_nm in $lt_nm_to_check; do
lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
IFS="$lt_save_ifs"
test -z "$ac_dir" && ac_dir=.
tmp_nm="$ac_dir/$lt_tmp_nm"
if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
# Check to see if the nm accepts a BSD-compat flag.
# Adding the `sed 1q' prevents false positives on HP-UX, which says:
# nm: unknown option "B" ignored
# Tru64's nm complains that /dev/null is an invalid object file
case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
*/dev/null* | *'Invalid file or object type'*)
lt_cv_path_NM="$tmp_nm -B"
break
;;
*)
case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
*/dev/null*)
lt_cv_path_NM="$tmp_nm -p"
break
;;
*)
lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
continue # so that we can try to find one that supports BSD flags
;;
esac
;;
esac
fi
done
IFS="$lt_save_ifs"
done
: ${lt_cv_path_NM=no}
fi])
if test "$lt_cv_path_NM" != "no"; then
NM="$lt_cv_path_NM"
else
# Didn't find any BSD compatible name lister, look for dumpbin.
if test -n "$DUMPBIN"; then :
# Let the user override the test.
else
AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :)
case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
*COFF*)
DUMPBIN="$DUMPBIN -symbols"
;;
*)
DUMPBIN=:
;;
esac
fi
AC_SUBST([DUMPBIN])
if test "$DUMPBIN" != ":"; then
NM="$DUMPBIN"
fi
fi
test -z "$NM" && NM=nm
AC_SUBST([NM])
_LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl
AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface],
[lt_cv_nm_interface="BSD nm"
echo "int some_variable = 0;" > conftest.$ac_ext
(eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD)
(eval "$ac_compile" 2>conftest.err)
cat conftest.err >&AS_MESSAGE_LOG_FD
(eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD)
(eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
cat conftest.err >&AS_MESSAGE_LOG_FD
(eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD)
cat conftest.out >&AS_MESSAGE_LOG_FD
if $GREP 'External.*some_variable' conftest.out > /dev/null; then
lt_cv_nm_interface="MS dumpbin"
fi
rm -f conftest*])
])# LT_PATH_NM
# Old names:
AU_ALIAS([AM_PROG_NM], [LT_PATH_NM])
AU_ALIAS([AC_PROG_NM], [LT_PATH_NM])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AM_PROG_NM], [])
dnl AC_DEFUN([AC_PROG_NM], [])
# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
# --------------------------------
# how to determine the name of the shared library
# associated with a specific link library.
# -- PORTME fill in with the dynamic library characteristics
m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB],
[m4_require([_LT_DECL_EGREP])
m4_require([_LT_DECL_OBJDUMP])
m4_require([_LT_DECL_DLLTOOL])
AC_CACHE_CHECK([how to associate runtime and link libraries],
lt_cv_sharedlib_from_linklib_cmd,
[lt_cv_sharedlib_from_linklib_cmd='unknown'
case $host_os in
cygwin* | mingw* | pw32* | cegcc*)
# two different shell functions defined in ltmain.sh
# decide which to use based on capabilities of $DLLTOOL
case `$DLLTOOL --help 2>&1` in
*--identify-strict*)
lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
;;
*)
lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
;;
esac
;;
*)
# fallback: assume linklib IS sharedlib
lt_cv_sharedlib_from_linklib_cmd="$ECHO"
;;
esac
])
sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
_LT_DECL([], [sharedlib_from_linklib_cmd], [1],
[Command to associate shared and link libraries])
])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB
# _LT_PATH_MANIFEST_TOOL
# ----------------------
# locate the manifest tool
m4_defun([_LT_PATH_MANIFEST_TOOL],
[AC_CHECK_TOOL(MANIFEST_TOOL, mt, :)
test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool],
[lt_cv_path_mainfest_tool=no
echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD
$MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
cat conftest.err >&AS_MESSAGE_LOG_FD
if $GREP 'Manifest Tool' conftest.out > /dev/null; then
lt_cv_path_mainfest_tool=yes
fi
rm -f conftest*])
if test "x$lt_cv_path_mainfest_tool" != xyes; then
MANIFEST_TOOL=:
fi
_LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl
])# _LT_PATH_MANIFEST_TOOL
# LT_LIB_M
# --------
# check for math library
AC_DEFUN([LT_LIB_M],
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
LIBM=
case $host in
*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
# These system don't have libm, or don't need it
;;
*-ncr-sysv4.3*)
AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm")
;;
*)
AC_CHECK_LIB(m, cos, LIBM="-lm")
;;
esac
AC_SUBST([LIBM])
])# LT_LIB_M
# Old name:
AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_CHECK_LIBM], [])
# _LT_COMPILER_NO_RTTI([TAGNAME])
# -------------------------------
m4_defun([_LT_COMPILER_NO_RTTI],
[m4_require([_LT_TAG_COMPILER])dnl
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
if test "$GCC" = yes; then
case $cc_basename in
nvcc*)
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;;
*)
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;;
esac
_LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions],
lt_cv_prog_compiler_rtti_exceptions,
[-fno-rtti -fno-exceptions], [],
[_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"])
fi
_LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1],
[Compiler flag to turn off builtin functions])
])# _LT_COMPILER_NO_RTTI
# _LT_CMD_GLOBAL_SYMBOLS
# ----------------------
m4_defun([_LT_CMD_GLOBAL_SYMBOLS],
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
AC_REQUIRE([AC_PROG_CC])dnl
AC_REQUIRE([AC_PROG_AWK])dnl
AC_REQUIRE([LT_PATH_NM])dnl
AC_REQUIRE([LT_PATH_LD])dnl
m4_require([_LT_DECL_SED])dnl
m4_require([_LT_DECL_EGREP])dnl
m4_require([_LT_TAG_COMPILER])dnl
# Check for command to grab the raw symbol name followed by C symbol from nm.
AC_MSG_CHECKING([command to parse $NM output from $compiler object])
AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe],
[
# These are sane defaults that work on at least a few old systems.
# [They come from Ultrix. What could be older than Ultrix?!! ;)]
# Character class describing NM global symbol codes.
symcode='[[BCDEGRST]]'
# Regexp to match symbols that can be accessed directly from C.
sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
# Define system-specific variables.
case $host_os in
aix*)
symcode='[[BCDT]]'
;;
cygwin* | mingw* | pw32* | cegcc*)
symcode='[[ABCDGISTW]]'
;;
hpux*)
if test "$host_cpu" = ia64; then
symcode='[[ABCDEGRST]]'
fi
;;
irix* | nonstopux*)
symcode='[[BCDEGRST]]'
;;
osf*)
symcode='[[BCDEGQRST]]'
;;
solaris*)
symcode='[[BDRT]]'
;;
sco3.2v5*)
symcode='[[DT]]'
;;
sysv4.2uw2*)
symcode='[[DT]]'
;;
sysv5* | sco5v6* | unixware* | OpenUNIX*)
symcode='[[ABDT]]'
;;
sysv4)
symcode='[[DFNSTU]]'
;;
esac
# If we're using GNU nm, then use its standard symbol codes.
case `$NM -V 2>&1` in
*GNU* | *'with BFD'*)
symcode='[[ABCDGIRSTW]]' ;;
esac
# Transform an extracted symbol line into a proper C declaration.
# Some systems (esp. on ia64) link data and code symbols differently,
# so use this general approach.
lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
# Transform an extracted symbol line into symbol name and symbol address
lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'"
lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
# Handle CRLF in mingw tool chain
opt_cr=
case $build_os in
mingw*)
opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
;;
esac
# Try without a prefix underscore, then with it.
for ac_symprfx in "" "_"; do
# Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
symxfrm="\\1 $ac_symprfx\\2 \\2"
# Write the raw and C identifiers.
if test "$lt_cv_nm_interface" = "MS dumpbin"; then
# Fake it for dumpbin and say T for any non-static function
# and D for any global variable.
# Also find C++ and __fastcall symbols from MSVC++,
# which start with @ or ?.
lt_cv_sys_global_symbol_pipe="$AWK ['"\
" {last_section=section; section=\$ 3};"\
" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
" \$ 0!~/External *\|/{next};"\
" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
" {if(hide[section]) next};"\
" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
" s[1]~/^[@?]/{print s[1], s[1]; next};"\
" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
" ' prfx=^$ac_symprfx]"
else
lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
fi
lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
# Check to see that the pipe works correctly.
pipe_works=no
rm -f conftest*
cat > conftest.$ac_ext <<_LT_EOF
#ifdef __cplusplus
extern "C" {
#endif
char nm_test_var;
void nm_test_func(void);
void nm_test_func(void){}
#ifdef __cplusplus
}
#endif
int main(){nm_test_var='a';nm_test_func();return(0);}
_LT_EOF
if AC_TRY_EVAL(ac_compile); then
# Now try to grab the symbols.
nlist=conftest.nm
if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then
# Try sorting and uniquifying the output.
if sort "$nlist" | uniq > "$nlist"T; then
mv -f "$nlist"T "$nlist"
else
rm -f "$nlist"T
fi
# Make sure that we snagged all the symbols we need.
if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
cat <<_LT_EOF > conftest.$ac_ext
/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
/* DATA imports from DLLs on WIN32 con't be const, because runtime
relocations are performed -- see ld's documentation on pseudo-relocs. */
# define LT@&t@_DLSYM_CONST
#elif defined(__osf__)
/* This system does not cope well with relocations in const data. */
# define LT@&t@_DLSYM_CONST
#else
# define LT@&t@_DLSYM_CONST const
#endif
#ifdef __cplusplus
extern "C" {
#endif
_LT_EOF
# Now generate the symbol file.
eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
cat <<_LT_EOF >> conftest.$ac_ext
/* The mapping between symbol names and symbols. */
LT@&t@_DLSYM_CONST struct {
const char *name;
void *address;
}
lt__PROGRAM__LTX_preloaded_symbols[[]] =
{
{ "@PROGRAM@", (void *) 0 },
_LT_EOF
$SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
cat <<\_LT_EOF >> conftest.$ac_ext
{0, (void *) 0}
};
/* This works around a problem in FreeBSD linker */
#ifdef FREEBSD_WORKAROUND
static const void *lt_preloaded_setup() {
return lt__PROGRAM__LTX_preloaded_symbols;
}
#endif
#ifdef __cplusplus
}
#endif
_LT_EOF
# Now try linking the two files.
mv conftest.$ac_objext conftstm.$ac_objext
lt_globsym_save_LIBS=$LIBS
lt_globsym_save_CFLAGS=$CFLAGS
LIBS="conftstm.$ac_objext"
CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)"
if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
pipe_works=yes
fi
LIBS=$lt_globsym_save_LIBS
CFLAGS=$lt_globsym_save_CFLAGS
else
echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD
fi
else
echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD
fi
else
echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD
fi
else
echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD
cat conftest.$ac_ext >&5
fi
rm -rf conftest* conftst*
# Do not use the global_symbol_pipe unless it works.
if test "$pipe_works" = yes; then
break
else
lt_cv_sys_global_symbol_pipe=
fi
done
])
if test -z "$lt_cv_sys_global_symbol_pipe"; then
lt_cv_sys_global_symbol_to_cdecl=
fi
if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
AC_MSG_RESULT(failed)
else
AC_MSG_RESULT(ok)
fi
# Response file support.
if test "$lt_cv_nm_interface" = "MS dumpbin"; then
nm_file_list_spec='@'
elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then
nm_file_list_spec='@'
fi
_LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1],
[Take the output of nm and produce a listing of raw symbols and C names])
_LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1],
[Transform the output of nm in a proper C declaration])
_LT_DECL([global_symbol_to_c_name_address],
[lt_cv_sys_global_symbol_to_c_name_address], [1],
[Transform the output of nm in a C name address pair])
_LT_DECL([global_symbol_to_c_name_address_lib_prefix],
[lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1],
[Transform the output of nm in a C name address pair when lib prefix is needed])
_LT_DECL([], [nm_file_list_spec], [1],
[Specify filename containing input files for $NM])
]) # _LT_CMD_GLOBAL_SYMBOLS
# _LT_COMPILER_PIC([TAGNAME])
# ---------------------------
m4_defun([_LT_COMPILER_PIC],
[m4_require([_LT_TAG_COMPILER])dnl
_LT_TAGVAR(lt_prog_compiler_wl, $1)=
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
_LT_TAGVAR(lt_prog_compiler_static, $1)=
m4_if([$1], [CXX], [
# C++ specific cases for pic, static, wl, etc.
if test "$GXX" = yes; then
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
case $host_os in
aix*)
# All AIX code is PIC.
if test "$host_cpu" = ia64; then
# AIX 5 now supports IA64 processor
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
fi
;;
amigaos*)
case $host_cpu in
powerpc)
# see comment about AmigaOS4 .so support
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
;;
m68k)
# FIXME: we need at least 68020 code to build shared libraries, but
# adding the `-m68020' flag to GCC prevents building anything better,
# like `-m68040'.
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
;;
esac
;;
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
# PIC is the default for these OSes.
;;
mingw* | cygwin* | os2* | pw32* | cegcc*)
# This hack is so that the source file can tell whether it is being
# built for inclusion in a dll (and should export symbols for example).
# Although the cygwin gcc ignores -fPIC, still need this for old-style
# (--disable-auto-import) libraries
m4_if([$1], [GCJ], [],
[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
;;
darwin* | rhapsody*)
# PIC is the default on this platform
# Common symbols not allowed in MH_DYLIB files
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
;;
*djgpp*)
# DJGPP does not support shared libraries at all
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
;;
haiku*)
# PIC is the default for Haiku.
# The "-static" flag exists, but is broken.
_LT_TAGVAR(lt_prog_compiler_static, $1)=
;;
interix[[3-9]]*)
# Interix 3.x gcc -fpic/-fPIC options generate broken code.
# Instead, we relocate shared libraries at runtime.
;;
sysv4*MP*)
if test -d /usr/nec; then
_LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
fi
;;
hpux*)
# PIC is the default for 64-bit PA HP-UX, but not for 32-bit
# PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
# sets the default TLS model and affects inlining.
case $host_cpu in
hppa*64*)
;;
*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
;;
esac
;;
*qnx* | *nto*)
# QNX uses GNU C++, but need to define -shared option too, otherwise
# it will coredump.
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
;;
*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
;;
esac
else
case $host_os in
aix[[4-9]]*)
# All AIX code is PIC.
if test "$host_cpu" = ia64; then
# AIX 5 now supports IA64 processor
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
else
_LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
fi
;;
chorus*)
case $cc_basename in
cxch68*)
# Green Hills C++ Compiler
# _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
;;
esac
;;
mingw* | cygwin* | os2* | pw32* | cegcc*)
# This hack is so that the source file can tell whether it is being
# built for inclusion in a dll (and should export symbols for example).
m4_if([$1], [GCJ], [],
[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
;;
dgux*)
case $cc_basename in
ec++*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
;;
ghcx*)
# Green Hills C++ Compiler
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
;;
*)
;;
esac
;;
freebsd* | dragonfly*)
# FreeBSD uses GNU C++
;;
hpux9* | hpux10* | hpux11*)
case $cc_basename in
CC*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
if test "$host_cpu" != ia64; then
_LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
fi
;;
aCC*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
case $host_cpu in
hppa*64*|ia64*)
# +Z the default
;;
*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
;;
esac
;;
*)
;;
esac
;;
interix*)
# This is c89, which is MS Visual C++ (no shared libs)
# Anyone wants to do a port?
;;
irix5* | irix6* | nonstopux*)
case $cc_basename in
CC*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
# CC pic flag -KPIC is the default.
;;
*)
;;
esac
;;
linux* | k*bsd*-gnu | kopensolaris*-gnu)
case $cc_basename in
KCC*)
# KAI C++ Compiler
_LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
;;
ecpc* )
# old Intel C++ for x86_64 which still supported -KPIC.
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
;;
icpc* )
# Intel C++, used to be incompatible with GCC.
# ICC 10 doesn't accept -KPIC any more.
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
;;
pgCC* | pgcpp*)
# Portland Group C++ compiler
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
;;
cxx*)
# Compaq C++
# Make sure the PIC flag is empty. It appears that all Alpha
# Linux and Compaq Tru64 Unix objects are PIC.
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
;;
xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*)
# IBM XL 8.0, 9.0 on PPC and BlueGene
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
;;
*)
case `$CC -V 2>&1 | sed 5q` in
*Sun\ C*)
# Sun C++ 5.9
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
;;
esac
;;
esac
;;
lynxos*)
;;
m88k*)
;;
mvs*)
case $cc_basename in
cxx*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall'
;;
*)
;;
esac
;;
netbsd* | netbsdelf*-gnu)
;;
*qnx* | *nto*)
# QNX uses GNU C++, but need to define -shared option too, otherwise
# it will coredump.
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
;;
osf3* | osf4* | osf5*)
case $cc_basename in
KCC*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,'
;;
RCC*)
# Rational C++ 2.4.1
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
;;
cxx*)
# Digital/Compaq C++
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
# Make sure the PIC flag is empty. It appears that all Alpha
# Linux and Compaq Tru64 Unix objects are PIC.
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
;;
*)
;;
esac
;;
psos*)
;;
solaris*)
case $cc_basename in
CC* | sunCC*)
# Sun C++ 4.2, 5.x and Centerline C++
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
;;
gcx*)
# Green Hills C++ Compiler
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
;;
*)
;;
esac
;;
sunos4*)
case $cc_basename in
CC*)
# Sun C++ 4.x
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
;;
lcc*)
# Lucid
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
;;
*)
;;
esac
;;
sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
case $cc_basename in
CC*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
;;
esac
;;
tandem*)
case $cc_basename in
NCC*)
# NonStop-UX NCC 3.20
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
;;
*)
;;
esac
;;
vxworks*)
;;
*)
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
;;
esac
fi
],
[
if test "$GCC" = yes; then
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
case $host_os in
aix*)
# All AIX code is PIC.
if test "$host_cpu" = ia64; then
# AIX 5 now supports IA64 processor
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
fi
;;
amigaos*)
case $host_cpu in
powerpc)
# see comment about AmigaOS4 .so support
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
;;
m68k)
# FIXME: we need at least 68020 code to build shared libraries, but
# adding the `-m68020' flag to GCC prevents building anything better,
# like `-m68040'.
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
;;
esac
;;
beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
# PIC is the default for these OSes.
;;
mingw* | cygwin* | pw32* | os2* | cegcc*)
# This hack is so that the source file can tell whether it is being
# built for inclusion in a dll (and should export symbols for example).
# Although the cygwin gcc ignores -fPIC, still need this for old-style
# (--disable-auto-import) libraries
m4_if([$1], [GCJ], [],
[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
;;
darwin* | rhapsody*)
# PIC is the default on this platform
# Common symbols not allowed in MH_DYLIB files
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
;;
haiku*)
# PIC is the default for Haiku.
# The "-static" flag exists, but is broken.
_LT_TAGVAR(lt_prog_compiler_static, $1)=
;;
hpux*)
# PIC is the default for 64-bit PA HP-UX, but not for 32-bit
# PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
# sets the default TLS model and affects inlining.
case $host_cpu in
hppa*64*)
# +Z the default
;;
*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
;;
esac
;;
interix[[3-9]]*)
# Interix 3.x gcc -fpic/-fPIC options generate broken code.
# Instead, we relocate shared libraries at runtime.
;;
msdosdjgpp*)
# Just because we use GCC doesn't mean we suddenly get shared libraries
# on systems that don't support them.
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
enable_shared=no
;;
*nto* | *qnx*)
# QNX uses GNU C++, but need to define -shared option too, otherwise
# it will coredump.
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
;;
sysv4*MP*)
if test -d /usr/nec; then
_LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
fi
;;
*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
;;
esac
case $cc_basename in
nvcc*) # Cuda Compiler Driver 2.2
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker '
if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
_LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)"
fi
;;
esac
else
# PORTME Check for flag to pass linker flags through the system compiler.
case $host_os in
aix*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
if test "$host_cpu" = ia64; then
# AIX 5 now supports IA64 processor
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
else
_LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp'
fi
;;
mingw* | cygwin* | pw32* | os2* | cegcc*)
# This hack is so that the source file can tell whether it is being
# built for inclusion in a dll (and should export symbols for example).
m4_if([$1], [GCJ], [],
[_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'])
;;
hpux9* | hpux10* | hpux11*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
# PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
# not for PA HP-UX.
case $host_cpu in
hppa*64*|ia64*)
# +Z the default
;;
*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
;;
esac
# Is there a better lt_prog_compiler_static that works with the bundled CC?
_LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
;;
irix5* | irix6* | nonstopux*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
# PIC (with -KPIC) is the default.
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
;;
linux* | k*bsd*-gnu | kopensolaris*-gnu)
case $cc_basename in
# old Intel for x86_64 which still supported -KPIC.
ecc*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
;;
# icc used to be incompatible with GCC.
# ICC 10 doesn't accept -KPIC any more.
icc* | ifort*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
;;
# Lahey Fortran 8.1.
lf95*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared'
_LT_TAGVAR(lt_prog_compiler_static, $1)='--static'
;;
nagfor*)
# NAG Fortran compiler
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
;;
pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
# Portland Group compilers (*not* the Pentium gcc compiler,
# which looks to be a dead project)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
;;
ccc*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
# All Alpha code is PIC.
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
;;
xl* | bgxl* | bgf* | mpixl*)
# IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink'
;;
*)
case `$CC -V 2>&1 | sed 5q` in
*Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*)
# Sun Fortran 8.3 passes all unrecognized flags to the linker
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
_LT_TAGVAR(lt_prog_compiler_wl, $1)=''
;;
*Sun\ F* | *Sun*Fortran*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
;;
*Sun\ C*)
# Sun C 5.9
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
;;
*Intel*\ [[CF]]*Compiler*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-static'
;;
*Portland\ Group*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
;;
esac
;;
esac
;;
newsos6)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
;;
*nto* | *qnx*)
# QNX uses GNU C++, but need to define -shared option too, otherwise
# it will coredump.
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared'
;;
osf3* | osf4* | osf5*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
# All OSF/1 code is PIC.
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
;;
rdos*)
_LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
;;
solaris*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
case $cc_basename in
f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';;
*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';;
esac
;;
sunos4*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
;;
sysv4 | sysv4.2uw2* | sysv4.3*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
;;
sysv4*MP*)
if test -d /usr/nec ;then
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
fi
;;
sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
;;
unicos*)
_LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
;;
uts4*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic'
_LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
;;
*)
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
;;
esac
fi
])
case $host_os in
# For platforms which do not support PIC, -DPIC is meaningless:
*djgpp*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)=
;;
*)
_LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])"
;;
esac
AC_CACHE_CHECK([for $compiler option to produce PIC],
[_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)],
[_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)])
_LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)
#
# Check to make sure the PIC flag actually works.
#
if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then
_LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works],
[_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)],
[$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [],
[case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in
"" | " "*) ;;
*) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;;
esac],
[_LT_TAGVAR(lt_prog_compiler_pic, $1)=
_LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no])
fi
_LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1],
[Additional compiler flags for building library objects])
_LT_TAGDECL([wl], [lt_prog_compiler_wl], [1],
[How to pass a linker flag through the compiler])
#
# Check to make sure the static flag actually works.
#
wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\"
_LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
_LT_TAGVAR(lt_cv_prog_compiler_static_works, $1),
$lt_tmp_static_flag,
[],
[_LT_TAGVAR(lt_prog_compiler_static, $1)=])
_LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1],
[Compiler flag to prevent dynamic linking])
])# _LT_COMPILER_PIC
# _LT_LINKER_SHLIBS([TAGNAME])
# ----------------------------
# See if the linker supports building shared libraries.
m4_defun([_LT_LINKER_SHLIBS],
[AC_REQUIRE([LT_PATH_LD])dnl
AC_REQUIRE([LT_PATH_NM])dnl
m4_require([_LT_PATH_MANIFEST_TOOL])dnl
m4_require([_LT_FILEUTILS_DEFAULTS])dnl
m4_require([_LT_DECL_EGREP])dnl
m4_require([_LT_DECL_SED])dnl
m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl
m4_require([_LT_TAG_COMPILER])dnl
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
m4_if([$1], [CXX], [
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
_LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
case $host_os in
aix[[4-9]]*)
# If we're using GNU nm, then we don't want the "-C" option.
# -C means demangle to AIX nm, but means don't demangle with GNU nm
# Also, AIX nm treats weak defined symbols like other global defined
# symbols, whereas GNU nm marks them as "W".
if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
else
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
fi
;;
pw32*)
_LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
;;
cygwin* | mingw* | cegcc*)
case $cc_basename in
cl*)
_LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
;;
*)
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
_LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
;;
esac
;;
linux* | k*bsd*-gnu | gnu*)
_LT_TAGVAR(link_all_deplibs, $1)=no
;;
*)
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
;;
esac
], [
runpath_var=
_LT_TAGVAR(allow_undefined_flag, $1)=
_LT_TAGVAR(always_export_symbols, $1)=no
_LT_TAGVAR(archive_cmds, $1)=
_LT_TAGVAR(archive_expsym_cmds, $1)=
_LT_TAGVAR(compiler_needs_object, $1)=no
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
_LT_TAGVAR(hardcode_automatic, $1)=no
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
_LT_TAGVAR(hardcode_libdir_separator, $1)=
_LT_TAGVAR(hardcode_minus_L, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
_LT_TAGVAR(inherit_rpath, $1)=no
_LT_TAGVAR(link_all_deplibs, $1)=unknown
_LT_TAGVAR(module_cmds, $1)=
_LT_TAGVAR(module_expsym_cmds, $1)=
_LT_TAGVAR(old_archive_from_new_cmds, $1)=
_LT_TAGVAR(old_archive_from_expsyms_cmds, $1)=
_LT_TAGVAR(thread_safe_flag_spec, $1)=
_LT_TAGVAR(whole_archive_flag_spec, $1)=
# include_expsyms should be a list of space-separated symbols to be *always*
# included in the symbol list
_LT_TAGVAR(include_expsyms, $1)=
# exclude_expsyms can be an extended regexp of symbols to exclude
# it will be wrapped by ` (' and `)$', so one must not match beginning or
# end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
# as well as any symbol that contains `d'.
_LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
# Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
# platforms (ab)use it in PIC code, but their linkers get confused if
# the symbol is explicitly referenced. Since portable code cannot
# rely on this symbol name, it's probably fine to never include it in
# preloaded symbol tables.
# Exclude shared library initialization/finalization symbols.
dnl Note also adjust exclude_expsyms for C++ above.
extract_expsyms_cmds=
case $host_os in
cygwin* | mingw* | pw32* | cegcc*)
# FIXME: the MSVC++ port hasn't been tested in a loooong time
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
if test "$GCC" != yes; then
with_gnu_ld=no
fi
;;
interix*)
# we just hope/assume this is gcc and not c89 (= MSVC++)
with_gnu_ld=yes
;;
openbsd*)
with_gnu_ld=no
;;
linux* | k*bsd*-gnu | gnu*)
_LT_TAGVAR(link_all_deplibs, $1)=no
;;
esac
_LT_TAGVAR(ld_shlibs, $1)=yes
# On some targets, GNU ld is compatible enough with the native linker
# that we're better off using the native interface for both.
lt_use_gnu_ld_interface=no
if test "$with_gnu_ld" = yes; then
case $host_os in
aix*)
# The AIX port of GNU ld has always aspired to compatibility
# with the native linker. However, as the warning in the GNU ld
# block says, versions before 2.19.5* couldn't really create working
# shared libraries, regardless of the interface used.
case `$LD -v 2>&1` in
*\ \(GNU\ Binutils\)\ 2.19.5*) ;;
*\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;;
*\ \(GNU\ Binutils\)\ [[3-9]]*) ;;
*)
lt_use_gnu_ld_interface=yes
;;
esac
;;
*)
lt_use_gnu_ld_interface=yes
;;
esac
fi
if test "$lt_use_gnu_ld_interface" = yes; then
# If archive_cmds runs LD, not CC, wlarc should be empty
wlarc='${wl}'
# Set some defaults for GNU ld with shared library support. These
# are reset later if shared libraries are not supported. Putting them
# here allows them to be overridden if necessary.
runpath_var=LD_RUN_PATH
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
# ancient GNU ld didn't support --whole-archive et. al.
if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
_LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
else
_LT_TAGVAR(whole_archive_flag_spec, $1)=
fi
supports_anon_versioning=no
case `$LD -v 2>&1` in
*GNU\ gold*) supports_anon_versioning=yes ;;
*\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11
*\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
*\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
*\ 2.11.*) ;; # other 2.11 versions
*) supports_anon_versioning=yes ;;
esac
# See if GNU ld supports shared libraries.
case $host_os in
aix[[3-9]]*)
# On AIX/PPC, the GNU linker is very broken
if test "$host_cpu" != ia64; then
_LT_TAGVAR(ld_shlibs, $1)=no
cat <<_LT_EOF 1>&2
*** Warning: the GNU linker, at least up to release 2.19, is reported
*** to be unable to reliably create shared libraries on AIX.
*** Therefore, libtool is disabling shared libraries support. If you
*** really care for shared libraries, you may want to install binutils
*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
*** You will then need to restart the configuration process.
_LT_EOF
fi
;;
amigaos*)
case $host_cpu in
powerpc)
# see comment about AmigaOS4 .so support
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)=''
;;
m68k)
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_TAGVAR(hardcode_minus_L, $1)=yes
;;
esac
;;
beos*)
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
# Joseph Beckenbach says some releases of gcc
# support --undefined. This deserves some investigation. FIXME
_LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
else
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
cygwin* | mingw* | pw32* | cegcc*)
# _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
# as there is no search path for DLLs.
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
_LT_TAGVAR(always_export_symbols, $1)=no
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols'
_LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname']
if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
# If the export-symbols file already is a .def file (1st line
# is EXPORTS), use it as is; otherwise, prepend...
_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
cp $export_symbols $output_objdir/$soname.def;
else
echo EXPORTS > $output_objdir/$soname.def;
cat $export_symbols >> $output_objdir/$soname.def;
fi~
$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
else
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
haiku*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(link_all_deplibs, $1)=yes
;;
interix[[3-9]]*)
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
# Instead, shared libraries are loaded at an image base (0x10000000 by
# default) and relocated if they conflict, which is a slow very memory
# consuming and fragmenting process. To avoid this, we pick a random,
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
;;
gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
tmp_diet=no
if test "$host_os" = linux-dietlibc; then
case $cc_basename in
diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
esac
fi
if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
&& test "$tmp_diet" = no
then
tmp_addflag=' $pic_flag'
tmp_sharedflag='-shared'
case $cc_basename,$host_cpu in
pgcc*) # Portland Group C compiler
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
tmp_addflag=' $pic_flag'
;;
pgf77* | pgf90* | pgf95* | pgfortran*)
# Portland Group f77 and f90 compilers
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
tmp_addflag=' $pic_flag -Mnomain' ;;
ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
tmp_addflag=' -i_dynamic' ;;
efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
tmp_addflag=' -i_dynamic -nofor_main' ;;
ifc* | ifort*) # Intel Fortran compiler
tmp_addflag=' -nofor_main' ;;
lf95*) # Lahey Fortran 8.1
_LT_TAGVAR(whole_archive_flag_spec, $1)=
tmp_sharedflag='--shared' ;;
xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below)
tmp_sharedflag='-qmkshrobj'
tmp_addflag= ;;
nvcc*) # Cuda Compiler Driver 2.2
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
_LT_TAGVAR(compiler_needs_object, $1)=yes
;;
esac
case `$CC -V 2>&1 | sed 5q` in
*Sun\ C*) # Sun C 5.9
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
_LT_TAGVAR(compiler_needs_object, $1)=yes
tmp_sharedflag='-G' ;;
*Sun\ F*) # Sun Fortran 8.3
tmp_sharedflag='-G' ;;
esac
_LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
if test "x$supports_anon_versioning" = xyes; then
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
echo "local: *; };" >> $output_objdir/$libname.ver~
$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
fi
case $cc_basename in
xlf* | bgf* | bgxlf* | mpixlf*)
# IBM XL Fortran 10.1 on PPC cannot create shared libs itself
_LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
_LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
if test "x$supports_anon_versioning" = xyes; then
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
echo "local: *; };" >> $output_objdir/$libname.ver~
$LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
fi
;;
esac
else
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
netbsd* | netbsdelf*-gnu)
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
wlarc=
else
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
fi
;;
solaris*)
if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
_LT_TAGVAR(ld_shlibs, $1)=no
cat <<_LT_EOF 1>&2
*** Warning: The releases 2.8.* of the GNU linker cannot reliably
*** create shared libraries on Solaris systems. Therefore, libtool
*** is disabling shared libraries support. We urge you to upgrade GNU
*** binutils to release 2.9.1 or newer. Another option is to modify
*** your PATH or compiler configuration so that the native linker is
*** used, and then restart.
_LT_EOF
elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
else
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
case `$LD -v 2>&1` in
*\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
_LT_TAGVAR(ld_shlibs, $1)=no
cat <<_LT_EOF 1>&2
*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
*** reliably create shared libraries on SCO systems. Therefore, libtool
*** is disabling shared libraries support. We urge you to upgrade GNU
*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
*** your PATH or compiler configuration so that the native linker is
*** used, and then restart.
_LT_EOF
;;
*)
# For security reasons, it is highly recommended that you always
# use absolute paths for naming shared libraries, and exclude the
# DT_RUNPATH tag from executables and libraries. But doing so
# requires that you compile everything twice, which is a pain.
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
else
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
esac
;;
sunos4*)
_LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
wlarc=
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
*)
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
else
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
esac
if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then
runpath_var=
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
_LT_TAGVAR(whole_archive_flag_spec, $1)=
fi
else
# PORTME fill in a description of your system's linker (not GNU ld)
case $host_os in
aix3*)
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
_LT_TAGVAR(always_export_symbols, $1)=yes
_LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
# Note: this linker hardcodes the directories in LIBPATH if there
# are no directories specified by -L.
_LT_TAGVAR(hardcode_minus_L, $1)=yes
if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
# Neither direct hardcoding nor static linking is supported with a
# broken collect2.
_LT_TAGVAR(hardcode_direct, $1)=unsupported
fi
;;
aix[[4-9]]*)
if test "$host_cpu" = ia64; then
# On IA64, the linker does run time linking by default, so we don't
# have to do anything special.
aix_use_runtimelinking=no
exp_sym_flag='-Bexport'
no_entry_flag=""
else
# If we're using GNU nm, then we don't want the "-C" option.
# -C means demangle to AIX nm, but means don't demangle with GNU nm
# Also, AIX nm treats weak defined symbols like other global
# defined symbols, whereas GNU nm marks them as "W".
if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
else
_LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
fi
aix_use_runtimelinking=no
# Test if we are trying to use run time linking or normal
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
# need to do runtime linking.
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
for ld_flag in $LDFLAGS; do
if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
aix_use_runtimelinking=yes
break
fi
done
;;
esac
exp_sym_flag='-bexport'
no_entry_flag='-bnoentry'
fi
# When large executables or shared objects are built, AIX ld can
# have problems creating the table of contents. If linking a library
# or program results in "error TOC overflow" add -mminimal-toc to
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
_LT_TAGVAR(archive_cmds, $1)=''
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
_LT_TAGVAR(link_all_deplibs, $1)=yes
_LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
if test "$GCC" = yes; then
case $host_os in aix4.[[012]]|aix4.[[012]].*)
# We only want to do this on AIX 4.2 and lower, the check
# below for broken collect2 doesn't work under 4.3+
collect2name=`${CC} -print-prog-name=collect2`
if test -f "$collect2name" &&
strings "$collect2name" | $GREP resolve_lib_name >/dev/null
then
# We have reworked collect2
:
else
# We have old collect2
_LT_TAGVAR(hardcode_direct, $1)=unsupported
# It fails to find uninstalled libraries when the uninstalled
# path is not listed in the libpath. Setting hardcode_minus_L
# to unsupported forces relinking
_LT_TAGVAR(hardcode_minus_L, $1)=yes
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=
fi
;;
esac
shared_flag='-shared'
if test "$aix_use_runtimelinking" = yes; then
shared_flag="$shared_flag "'${wl}-G'
fi
_LT_TAGVAR(link_all_deplibs, $1)=no
else
# not using gcc
if test "$host_cpu" = ia64; then
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
# chokes on -Wl,-G. The following line is correct:
shared_flag='-G'
else
if test "$aix_use_runtimelinking" = yes; then
shared_flag='${wl}-G'
else
shared_flag='${wl}-bM:SRE'
fi
fi
fi
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
# It seems that -bexpall does not export symbols beginning with
# underscore (_), so it is better to generate a list of symbols to export.
_LT_TAGVAR(always_export_symbols, $1)=yes
if test "$aix_use_runtimelinking" = yes; then
# Warning - without using the other runtime loading flags (-brtl),
# -berok will link without error, but may produce a broken library.
_LT_TAGVAR(allow_undefined_flag, $1)='-berok'
# Determine the default libpath from the value encoded in an
# empty executable.
_LT_SYS_MODULE_PATH_AIX([$1])
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
else
if test "$host_cpu" = ia64; then
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
_LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
_LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
else
# Determine the default libpath from the value encoded in an
# empty executable.
_LT_SYS_MODULE_PATH_AIX([$1])
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
# Warning - without using the other run time loading flags,
# -berok will link without error, but may produce a broken library.
_LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
if test "$with_gnu_ld" = yes; then
# We only use this code for GNU lds that support --whole-archive.
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
else
# Exported symbols can be pulled into shared objects from archives
_LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
fi
_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
# This is similar to how AIX traditionally builds its shared libraries.
_LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
fi
fi
;;
amigaos*)
case $host_cpu in
powerpc)
# see comment about AmigaOS4 .so support
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)=''
;;
m68k)
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_TAGVAR(hardcode_minus_L, $1)=yes
;;
esac
;;
bsdi[[45]]*)
_LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic
;;
cygwin* | mingw* | pw32* | cegcc*)
# When not using gcc, we currently assume that we are using
# Microsoft Visual C++.
# hardcode_libdir_flag_spec is actually meaningless, as there is
# no search path for DLLs.
case $cc_basename in
cl*)
# Native MSVC
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
_LT_TAGVAR(always_export_symbols, $1)=yes
_LT_TAGVAR(file_list_spec, $1)='@'
# Tell ltmain to make .lib files, not .a files.
libext=lib
# Tell ltmain to make .dll files, not .so files.
shrext_cmds=".dll"
# FIXME: Setting linknames here is a bad hack.
_LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
else
sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
fi~
$CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
linknames='
# The linker will not automatically build a static lib if we build a DLL.
# _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
_LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
_LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
# Don't use ranlib
_LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
_LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
lt_tool_outputfile="@TOOL_OUTPUT@"~
case $lt_outputfile in
*.exe|*.EXE) ;;
*)
lt_outputfile="$lt_outputfile.exe"
lt_tool_outputfile="$lt_tool_outputfile.exe"
;;
esac~
if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
$MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
$RM "$lt_outputfile.manifest";
fi'
;;
*)
# Assume MSVC wrapper
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
# Tell ltmain to make .lib files, not .a files.
libext=lib
# Tell ltmain to make .dll files, not .so files.
shrext_cmds=".dll"
# FIXME: Setting linknames here is a bad hack.
_LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
# The linker will automatically build a .lib file if we build a DLL.
_LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
# FIXME: Should let the user specify the lib program.
_LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
;;
esac
;;
darwin* | rhapsody*)
_LT_DARWIN_LINKER_FEATURES($1)
;;
dgux*)
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
# FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
# support. Future versions do this automatically, but an explicit c++rt0.o
# does not break anything, and helps significantly (at the cost of a little
# extra space).
freebsd2.2*)
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
# Unfortunately, older versions of FreeBSD 2 do not have this feature.
freebsd2.*)
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_minus_L, $1)=yes
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
# FreeBSD 3 and greater uses gcc -shared to do shared libraries.
freebsd* | dragonfly*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
hpux9*)
if test "$GCC" = yes; then
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
else
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
fi
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
_LT_TAGVAR(hardcode_direct, $1)=yes
# hardcode_minus_L: Not really in the search PATH,
# but as the default location of the library.
_LT_TAGVAR(hardcode_minus_L, $1)=yes
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
;;
hpux10*)
if test "$GCC" = yes && test "$with_gnu_ld" = no; then
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
else
_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
fi
if test "$with_gnu_ld" = no; then
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
# hardcode_minus_L: Not really in the search PATH,
# but as the default location of the library.
_LT_TAGVAR(hardcode_minus_L, $1)=yes
fi
;;
hpux11*)
if test "$GCC" = yes && test "$with_gnu_ld" = no; then
case $host_cpu in
hppa*64*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
;;
ia64*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
;;
*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
;;
esac
else
case $host_cpu in
hppa*64*)
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
;;
ia64*)
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
;;
*)
m4_if($1, [], [
# Older versions of the 11.00 compiler do not understand -b yet
# (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
_LT_LINKER_OPTION([if $CC understands -b],
_LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b],
[_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'],
[_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])],
[_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'])
;;
esac
fi
if test "$with_gnu_ld" = no; then
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
case $host_cpu in
hppa*64*|ia64*)
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
*)
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
# hardcode_minus_L: Not really in the search PATH,
# but as the default location of the library.
_LT_TAGVAR(hardcode_minus_L, $1)=yes
;;
esac
fi
;;
irix5* | irix6* | nonstopux*)
if test "$GCC" = yes; then
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
# Try to use the -exported_symbol ld option, if it does not
# work, assume that -exports_file does not work either and
# implicitly export all symbols.
# This should be the same for all languages, so no per-tag cache variable.
AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol],
[lt_cv_irix_exported_symbol],
[save_LDFLAGS="$LDFLAGS"
LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
AC_LINK_IFELSE(
[AC_LANG_SOURCE(
[AC_LANG_CASE([C], [[int foo (void) { return 0; }]],
[C++], [[int foo (void) { return 0; }]],
[Fortran 77], [[
subroutine foo
end]],
[Fortran], [[
subroutine foo
end]])])],
[lt_cv_irix_exported_symbol=yes],
[lt_cv_irix_exported_symbol=no])
LDFLAGS="$save_LDFLAGS"])
if test "$lt_cv_irix_exported_symbol" = yes; then
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
fi
else
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
fi
_LT_TAGVAR(archive_cmds_need_lc, $1)='no'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
_LT_TAGVAR(inherit_rpath, $1)=yes
_LT_TAGVAR(link_all_deplibs, $1)=yes
;;
netbsd* | netbsdelf*-gnu)
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
else
_LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
fi
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
newsos6)
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
*nto* | *qnx*)
;;
openbsd*)
if test -f /usr/libexec/ld.so; then
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
else
case $host_os in
openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
;;
*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
;;
esac
fi
else
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
os2*)
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_TAGVAR(hardcode_minus_L, $1)=yes
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
_LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
_LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
;;
osf3*)
if test "$GCC" = yes; then
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
else
_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
fi
_LT_TAGVAR(archive_cmds_need_lc, $1)='no'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
;;
osf4* | osf5*) # as osf3* with the addition of -msym flag
if test "$GCC" = yes; then
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
else
_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
$CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
# Both c and cxx compiler support -rpath directly
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
fi
_LT_TAGVAR(archive_cmds_need_lc, $1)='no'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
;;
solaris*)
_LT_TAGVAR(no_undefined_flag, $1)=' -z defs'
if test "$GCC" = yes; then
wlarc='${wl}'
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
else
case `$CC -V 2>&1` in
*"Compilers 5.0"*)
wlarc=''
_LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
;;
*)
wlarc='${wl}'
_LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
$CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
;;
esac
fi
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
case $host_os in
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
*)
# The compiler driver will combine and reorder linker options,
# but understands `-z linker_flag'. GCC discards it without `$wl',
# but is careful enough not to reorder.
# Supported since Solaris 2.6 (maybe 2.5.1?)
if test "$GCC" = yes; then
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
else
_LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
fi
;;
esac
_LT_TAGVAR(link_all_deplibs, $1)=yes
;;
sunos4*)
if test "x$host_vendor" = xsequent; then
# Use $CC to link under sequent, because it throws in some extra .o
# files that make .init and .fini sections work.
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
else
_LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
fi
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_minus_L, $1)=yes
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
sysv4)
case $host_vendor in
sni)
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(hardcode_direct, $1)=yes # is this really true???
;;
siemens)
## LD is ld it makes a PLAMLIB
## CC just makes a GrossModule.
_LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs'
_LT_TAGVAR(hardcode_direct, $1)=no
;;
motorola)
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie
;;
esac
runpath_var='LD_RUN_PATH'
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
sysv4.3*)
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
_LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport'
;;
sysv4*MP*)
if test -d /usr/nec; then
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
runpath_var=LD_RUN_PATH
hardcode_runpath_var=yes
_LT_TAGVAR(ld_shlibs, $1)=yes
fi
;;
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
runpath_var='LD_RUN_PATH'
if test "$GCC" = yes; then
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
else
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
fi
;;
sysv5* | sco3.2v5* | sco5v6*)
# Note: We can NOT use -z defs as we might desire, because we do not
# link with -lc, and that would cause any symbols used from libc to
# always be unresolved, which means just about no library would
# ever link correctly. If we're not using GNU ld we use -z text
# though, which does catch some bad symbols but isn't as heavy-handed
# as -z defs.
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
_LT_TAGVAR(link_all_deplibs, $1)=yes
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
runpath_var='LD_RUN_PATH'
if test "$GCC" = yes; then
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
else
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
fi
;;
uts4*)
_LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
*)
_LT_TAGVAR(ld_shlibs, $1)=no
;;
esac
if test x$host_vendor = xsni; then
case $host in
sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym'
;;
esac
fi
fi
])
AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
_LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld
_LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl
_LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl
_LT_DECL([], [extract_expsyms_cmds], [2],
[The commands to extract the exported symbol list from a shared archive])
#
# Do we need to explicitly link libc?
#
case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in
x|xyes)
# Assume -lc should be added
_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
if test "$enable_shared" = yes && test "$GCC" = yes; then
case $_LT_TAGVAR(archive_cmds, $1) in
*'~'*)
# FIXME: we may have to deal with multi-command sequences.
;;
'$CC '*)
# Test whether the compiler implicitly links with -lc since on some
# systems, -lgcc has to come before -lc. If gcc already passes -lc
# to ld, don't add -lc before -lgcc.
AC_CACHE_CHECK([whether -lc should be explicitly linked in],
[lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1),
[$RM conftest*
echo "$lt_simple_compile_test_code" > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
soname=conftest
lib=conftest
libobjs=conftest.$ac_objext
deplibs=
wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1)
pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1)
compiler_flags=-v
linker_flags=-v
verstring=
output_objdir=.
libname=conftest
lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1)
_LT_TAGVAR(allow_undefined_flag, $1)=
if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1)
then
lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no
else
lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
fi
_LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag
else
cat conftest.err 1>&5
fi
$RM conftest*
])
_LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)
;;
esac
fi
;;
esac
_LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0],
[Whether or not to add -lc for building shared libraries])
_LT_TAGDECL([allow_libtool_libs_with_static_runtimes],
[enable_shared_with_static_runtimes], [0],
[Whether or not to disallow shared libs when runtime libs are static])
_LT_TAGDECL([], [export_dynamic_flag_spec], [1],
[Compiler flag to allow reflexive dlopens])
_LT_TAGDECL([], [whole_archive_flag_spec], [1],
[Compiler flag to generate shared objects directly from archives])
_LT_TAGDECL([], [compiler_needs_object], [1],
[Whether the compiler copes with passing no objects directly])
_LT_TAGDECL([], [old_archive_from_new_cmds], [2],
[Create an old-style archive from a shared archive])
_LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2],
[Create a temporary old-style archive to link instead of a shared archive])
_LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive])
_LT_TAGDECL([], [archive_expsym_cmds], [2])
_LT_TAGDECL([], [module_cmds], [2],
[Commands used to build a loadable module if different from building
a shared archive.])
_LT_TAGDECL([], [module_expsym_cmds], [2])
_LT_TAGDECL([], [with_gnu_ld], [1],
[Whether we are building with GNU ld or not])
_LT_TAGDECL([], [allow_undefined_flag], [1],
[Flag that allows shared libraries with undefined symbols to be built])
_LT_TAGDECL([], [no_undefined_flag], [1],
[Flag that enforces no undefined symbols])
_LT_TAGDECL([], [hardcode_libdir_flag_spec], [1],
[Flag to hardcode $libdir into a binary during linking.
This must work even if $libdir does not exist])
_LT_TAGDECL([], [hardcode_libdir_separator], [1],
[Whether we need a single "-rpath" flag with a separated argument])
_LT_TAGDECL([], [hardcode_direct], [0],
[Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
DIR into the resulting binary])
_LT_TAGDECL([], [hardcode_direct_absolute], [0],
[Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes
DIR into the resulting binary and the resulting library dependency is
"absolute", i.e impossible to change by setting ${shlibpath_var} if the
library is relocated])
_LT_TAGDECL([], [hardcode_minus_L], [0],
[Set to "yes" if using the -LDIR flag during linking hardcodes DIR
into the resulting binary])
_LT_TAGDECL([], [hardcode_shlibpath_var], [0],
[Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
into the resulting binary])
_LT_TAGDECL([], [hardcode_automatic], [0],
[Set to "yes" if building a shared library automatically hardcodes DIR
into the library and all subsequent libraries and executables linked
against it])
_LT_TAGDECL([], [inherit_rpath], [0],
[Set to yes if linker adds runtime paths of dependent libraries
to runtime path list])
_LT_TAGDECL([], [link_all_deplibs], [0],
[Whether libtool must link a program against all its dependency libraries])
_LT_TAGDECL([], [always_export_symbols], [0],
[Set to "yes" if exported symbols are required])
_LT_TAGDECL([], [export_symbols_cmds], [2],
[The commands to list exported symbols])
_LT_TAGDECL([], [exclude_expsyms], [1],
[Symbols that should not be listed in the preloaded symbols])
_LT_TAGDECL([], [include_expsyms], [1],
[Symbols that must always be exported])
_LT_TAGDECL([], [prelink_cmds], [2],
[Commands necessary for linking programs (against libraries) with templates])
_LT_TAGDECL([], [postlink_cmds], [2],
[Commands necessary for finishing linking programs])
_LT_TAGDECL([], [file_list_spec], [1],
[Specify filename containing input files])
dnl FIXME: Not yet implemented
dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1],
dnl [Compiler flag to generate thread safe objects])
])# _LT_LINKER_SHLIBS
# _LT_LANG_C_CONFIG([TAG])
# ------------------------
# Ensure that the configuration variables for a C compiler are suitably
# defined. These variables are subsequently used by _LT_CONFIG to write
# the compiler configuration to `libtool'.
m4_defun([_LT_LANG_C_CONFIG],
[m4_require([_LT_DECL_EGREP])dnl
lt_save_CC="$CC"
AC_LANG_PUSH(C)
# Source file extension for C test sources.
ac_ext=c
# Object file extension for compiled C test sources.
objext=o
_LT_TAGVAR(objext, $1)=$objext
# Code to be used in simple compile tests
lt_simple_compile_test_code="int some_variable = 0;"
# Code to be used in simple link tests
lt_simple_link_test_code='int main(){return(0);}'
_LT_TAG_COMPILER
# Save the default compiler, since it gets overwritten when the other
# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
compiler_DEFAULT=$CC
# save warnings/boilerplate of simple test code
_LT_COMPILER_BOILERPLATE
_LT_LINKER_BOILERPLATE
## CAVEAT EMPTOR:
## There is no encapsulation within the following macros, do not change
## the running order or otherwise move them around unless you know exactly
## what you are doing...
if test -n "$compiler"; then
_LT_COMPILER_NO_RTTI($1)
_LT_COMPILER_PIC($1)
_LT_COMPILER_C_O($1)
_LT_COMPILER_FILE_LOCKS($1)
_LT_LINKER_SHLIBS($1)
_LT_SYS_DYNAMIC_LINKER($1)
_LT_LINKER_HARDCODE_LIBPATH($1)
LT_SYS_DLOPEN_SELF
_LT_CMD_STRIPLIB
# Report which library types will actually be built
AC_MSG_CHECKING([if libtool supports shared libraries])
AC_MSG_RESULT([$can_build_shared])
AC_MSG_CHECKING([whether to build shared libraries])
test "$can_build_shared" = "no" && enable_shared=no
# On AIX, shared libraries and static libraries use the same namespace, and
# are all built from PIC.
case $host_os in
aix3*)
test "$enable_shared" = yes && enable_static=no
if test -n "$RANLIB"; then
archive_cmds="$archive_cmds~\$RANLIB \$lib"
postinstall_cmds='$RANLIB $lib'
fi
;;
aix[[4-9]]*)
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
test "$enable_shared" = yes && enable_static=no
fi
;;
esac
AC_MSG_RESULT([$enable_shared])
AC_MSG_CHECKING([whether to build static libraries])
# Make sure either enable_shared or enable_static is yes.
test "$enable_shared" = yes || enable_static=yes
AC_MSG_RESULT([$enable_static])
_LT_CONFIG($1)
fi
AC_LANG_POP
CC="$lt_save_CC"
])# _LT_LANG_C_CONFIG
# _LT_LANG_CXX_CONFIG([TAG])
# --------------------------
# Ensure that the configuration variables for a C++ compiler are suitably
# defined. These variables are subsequently used by _LT_CONFIG to write
# the compiler configuration to `libtool'.
m4_defun([_LT_LANG_CXX_CONFIG],
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
m4_require([_LT_DECL_EGREP])dnl
m4_require([_LT_PATH_MANIFEST_TOOL])dnl
if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
(test "X$CXX" != "Xg++"))) ; then
AC_PROG_CXXCPP
else
_lt_caught_CXX_error=yes
fi
AC_LANG_PUSH(C++)
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
_LT_TAGVAR(allow_undefined_flag, $1)=
_LT_TAGVAR(always_export_symbols, $1)=no
_LT_TAGVAR(archive_expsym_cmds, $1)=
_LT_TAGVAR(compiler_needs_object, $1)=no
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
_LT_TAGVAR(hardcode_libdir_separator, $1)=
_LT_TAGVAR(hardcode_minus_L, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
_LT_TAGVAR(hardcode_automatic, $1)=no
_LT_TAGVAR(inherit_rpath, $1)=no
_LT_TAGVAR(module_cmds, $1)=
_LT_TAGVAR(module_expsym_cmds, $1)=
_LT_TAGVAR(link_all_deplibs, $1)=unknown
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
_LT_TAGVAR(reload_flag, $1)=$reload_flag
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
_LT_TAGVAR(no_undefined_flag, $1)=
_LT_TAGVAR(whole_archive_flag_spec, $1)=
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
# Source file extension for C++ test sources.
ac_ext=cpp
# Object file extension for compiled C++ test sources.
objext=o
_LT_TAGVAR(objext, $1)=$objext
# No sense in running all these tests if we already determined that
# the CXX compiler isn't working. Some variables (like enable_shared)
# are currently assumed to apply to all compilers on this platform,
# and will be corrupted by setting them based on a non-working compiler.
if test "$_lt_caught_CXX_error" != yes; then
# Code to be used in simple compile tests
lt_simple_compile_test_code="int some_variable = 0;"
# Code to be used in simple link tests
lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
_LT_TAG_COMPILER
# save warnings/boilerplate of simple test code
_LT_COMPILER_BOILERPLATE
_LT_LINKER_BOILERPLATE
# Allow CC to be a program name with arguments.
lt_save_CC=$CC
lt_save_CFLAGS=$CFLAGS
lt_save_LD=$LD
lt_save_GCC=$GCC
GCC=$GXX
lt_save_with_gnu_ld=$with_gnu_ld
lt_save_path_LD=$lt_cv_path_LD
if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
else
$as_unset lt_cv_prog_gnu_ld
fi
if test -n "${lt_cv_path_LDCXX+set}"; then
lt_cv_path_LD=$lt_cv_path_LDCXX
else
$as_unset lt_cv_path_LD
fi
test -z "${LDCXX+set}" || LD=$LDCXX
CC=${CXX-"c++"}
CFLAGS=$CXXFLAGS
compiler=$CC
_LT_TAGVAR(compiler, $1)=$CC
_LT_CC_BASENAME([$compiler])
if test -n "$compiler"; then
# We don't want -fno-exception when compiling C++ code, so set the
# no_builtin_flag separately
if test "$GXX" = yes; then
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin'
else
_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=
fi
if test "$GXX" = yes; then
# Set up default GNU C++ configuration
LT_PATH_LD
# Check if GNU C++ uses GNU ld as the underlying linker, since the
# archiving commands below assume that GNU ld is being used.
if test "$with_gnu_ld" = yes; then
_LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
# If archive_cmds runs LD, not CC, wlarc should be empty
# XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
# investigate it a little bit more. (MM)
wlarc='${wl}'
# ancient GNU ld didn't support --whole-archive et. al.
if eval "`$CC -print-prog-name=ld` --help 2>&1" |
$GREP 'no-whole-archive' > /dev/null; then
_LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
else
_LT_TAGVAR(whole_archive_flag_spec, $1)=
fi
else
with_gnu_ld=no
wlarc=
# A generic and very simple default shared library creation
# command for GNU C++ for the case where it uses the native
# linker, instead of GNU ld. If possible, this setting should
# overridden to take advantage of the native linker features on
# the platform it is being used on.
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
fi
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
else
GXX=no
with_gnu_ld=no
wlarc=
fi
# PORTME: fill in a description of your system's C++ link characteristics
AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
_LT_TAGVAR(ld_shlibs, $1)=yes
case $host_os in
aix3*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
aix[[4-9]]*)
if test "$host_cpu" = ia64; then
# On IA64, the linker does run time linking by default, so we don't
# have to do anything special.
aix_use_runtimelinking=no
exp_sym_flag='-Bexport'
no_entry_flag=""
else
aix_use_runtimelinking=no
# Test if we are trying to use run time linking or normal
# AIX style linking. If -brtl is somewhere in LDFLAGS, we
# need to do runtime linking.
case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
for ld_flag in $LDFLAGS; do
case $ld_flag in
*-brtl*)
aix_use_runtimelinking=yes
break
;;
esac
done
;;
esac
exp_sym_flag='-bexport'
no_entry_flag='-bnoentry'
fi
# When large executables or shared objects are built, AIX ld can
# have problems creating the table of contents. If linking a library
# or program results in "error TOC overflow" add -mminimal-toc to
# CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
# enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
_LT_TAGVAR(archive_cmds, $1)=''
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
_LT_TAGVAR(link_all_deplibs, $1)=yes
_LT_TAGVAR(file_list_spec, $1)='${wl}-f,'
if test "$GXX" = yes; then
case $host_os in aix4.[[012]]|aix4.[[012]].*)
# We only want to do this on AIX 4.2 and lower, the check
# below for broken collect2 doesn't work under 4.3+
collect2name=`${CC} -print-prog-name=collect2`
if test -f "$collect2name" &&
strings "$collect2name" | $GREP resolve_lib_name >/dev/null
then
# We have reworked collect2
:
else
# We have old collect2
_LT_TAGVAR(hardcode_direct, $1)=unsupported
# It fails to find uninstalled libraries when the uninstalled
# path is not listed in the libpath. Setting hardcode_minus_L
# to unsupported forces relinking
_LT_TAGVAR(hardcode_minus_L, $1)=yes
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=
fi
esac
shared_flag='-shared'
if test "$aix_use_runtimelinking" = yes; then
shared_flag="$shared_flag "'${wl}-G'
fi
else
# not using gcc
if test "$host_cpu" = ia64; then
# VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
# chokes on -Wl,-G. The following line is correct:
shared_flag='-G'
else
if test "$aix_use_runtimelinking" = yes; then
shared_flag='${wl}-G'
else
shared_flag='${wl}-bM:SRE'
fi
fi
fi
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall'
# It seems that -bexpall does not export symbols beginning with
# underscore (_), so it is better to generate a list of symbols to
# export.
_LT_TAGVAR(always_export_symbols, $1)=yes
if test "$aix_use_runtimelinking" = yes; then
# Warning - without using the other runtime loading flags (-brtl),
# -berok will link without error, but may produce a broken library.
_LT_TAGVAR(allow_undefined_flag, $1)='-berok'
# Determine the default libpath from the value encoded in an empty
# executable.
_LT_SYS_MODULE_PATH_AIX([$1])
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
else
if test "$host_cpu" = ia64; then
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
_LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
_LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
else
# Determine the default libpath from the value encoded in an
# empty executable.
_LT_SYS_MODULE_PATH_AIX([$1])
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
# Warning - without using the other run time loading flags,
# -berok will link without error, but may produce a broken library.
_LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
if test "$with_gnu_ld" = yes; then
# We only use this code for GNU lds that support --whole-archive.
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
else
# Exported symbols can be pulled into shared objects from archives
_LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
fi
_LT_TAGVAR(archive_cmds_need_lc, $1)=yes
# This is similar to how AIX traditionally builds its shared
# libraries.
_LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
fi
fi
;;
beos*)
if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
# Joseph Beckenbach says some releases of gcc
# support --undefined. This deserves some investigation. FIXME
_LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
else
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
chorus*)
case $cc_basename in
*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
esac
;;
cygwin* | mingw* | pw32* | cegcc*)
case $GXX,$cc_basename in
,cl* | no,cl*)
# Native MSVC
# hardcode_libdir_flag_spec is actually meaningless, as there is
# no search path for DLLs.
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' '
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
_LT_TAGVAR(always_export_symbols, $1)=yes
_LT_TAGVAR(file_list_spec, $1)='@'
# Tell ltmain to make .lib files, not .a files.
libext=lib
# Tell ltmain to make .dll files, not .so files.
shrext_cmds=".dll"
# FIXME: Setting linknames here is a bad hack.
_LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
$SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
else
$SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
fi~
$CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
linknames='
# The linker will not automatically build a static lib if we build a DLL.
# _LT_TAGVAR(old_archive_from_new_cmds, $1)='true'
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
# Don't use ranlib
_LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
_LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
lt_tool_outputfile="@TOOL_OUTPUT@"~
case $lt_outputfile in
*.exe|*.EXE) ;;
*)
lt_outputfile="$lt_outputfile.exe"
lt_tool_outputfile="$lt_tool_outputfile.exe"
;;
esac~
func_to_tool_file "$lt_outputfile"~
if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
$MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
$RM "$lt_outputfile.manifest";
fi'
;;
*)
# g++
# _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
# as there is no search path for DLLs.
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols'
_LT_TAGVAR(allow_undefined_flag, $1)=unsupported
_LT_TAGVAR(always_export_symbols, $1)=no
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
# If the export-symbols file already is a .def file (1st line
# is EXPORTS), use it as is; otherwise, prepend...
_LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
cp $export_symbols $output_objdir/$soname.def;
else
echo EXPORTS > $output_objdir/$soname.def;
cat $export_symbols >> $output_objdir/$soname.def;
fi~
$CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
else
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
esac
;;
darwin* | rhapsody*)
_LT_DARWIN_LINKER_FEATURES($1)
;;
dgux*)
case $cc_basename in
ec++*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
ghcx*)
# Green Hills C++ Compiler
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
esac
;;
freebsd2.*)
# C++ shared libraries reported to be fairly broken before
# switch to ELF
_LT_TAGVAR(ld_shlibs, $1)=no
;;
freebsd-elf*)
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
;;
freebsd* | dragonfly*)
# FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
# conventions
_LT_TAGVAR(ld_shlibs, $1)=yes
;;
gnu*)
;;
haiku*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(link_all_deplibs, $1)=yes
;;
hpux9*)
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
# but as the default
# location of the library.
case $cc_basename in
CC*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
aCC*)
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
#
# There doesn't appear to be a way to prevent this compiler from
# explicitly linking system object files so we need to strip them
# from the output so that they don't get included in the library
# dependencies.
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
;;
*)
if test "$GXX" = yes; then
_LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
else
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
esac
;;
hpux10*|hpux11*)
if test $with_gnu_ld = no; then
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
case $host_cpu in
hppa*64*|ia64*)
;;
*)
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
;;
esac
fi
case $host_cpu in
hppa*64*|ia64*)
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
;;
*)
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
_LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
# but as the default
# location of the library.
;;
esac
case $cc_basename in
CC*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
aCC*)
case $host_cpu in
hppa*64*)
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
;;
ia64*)
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
;;
*)
_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
;;
esac
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
#
# There doesn't appear to be a way to prevent this compiler from
# explicitly linking system object files so we need to strip them
# from the output so that they don't get included in the library
# dependencies.
output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
;;
*)
if test "$GXX" = yes; then
if test $with_gnu_ld = no; then
case $host_cpu in
hppa*64*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
;;
ia64*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
;;
*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
;;
esac
fi
else
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
esac
;;
interix[[3-9]]*)
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
# Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
# Instead, shared libraries are loaded at an image base (0x10000000 by
# default) and relocated if they conflict, which is a slow very memory
# consuming and fragmenting process. To avoid this, we pick a random,
# 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
# time. Moving up from 0x10000000 also allows more sbrk(2) space.
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
;;
irix5* | irix6*)
case $cc_basename in
CC*)
# SGI C++
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
# Archives containing C++ object files must be created using
# "CC -ar", where "CC" is the IRIX C++ compiler. This is
# necessary to make sure instantiated templates are included
# in the archive.
_LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs'
;;
*)
if test "$GXX" = yes; then
if test "$with_gnu_ld" = no; then
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
else
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
fi
fi
_LT_TAGVAR(link_all_deplibs, $1)=yes
;;
esac
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
_LT_TAGVAR(inherit_rpath, $1)=yes
;;
linux* | k*bsd*-gnu | kopensolaris*-gnu)
case $cc_basename in
KCC*)
# Kuck and Associates, Inc. (KAI) C++ Compiler
# KCC will only create a shared library if the output file
# ends with ".so" (or ".sl" for HP-UX), so rename the library
# to its proper name (with version) after linking.
_LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
#
# There doesn't appear to be a way to prevent this compiler from
# explicitly linking system object files so we need to strip them
# from the output so that they don't get included in the library
# dependencies.
output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
# Archives containing C++ object files must be created using
# "CC -Bstatic", where "CC" is the KAI C++ compiler.
_LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs'
;;
icpc* | ecpc* )
# Intel C++
with_gnu_ld=yes
# version 8.0 and above of icpc choke on multiply defined symbols
# if we add $predep_objects and $postdep_objects, however 7.1 and
# earlier do not add the objects themselves.
case `$CC -V 2>&1` in
*"Version 7."*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
;;
*) # Version 8.0 or newer
tmp_idyn=
case $host_cpu in
ia64*) tmp_idyn=' -i_dynamic';;
esac
_LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
;;
esac
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
;;
pgCC* | pgcpp*)
# Portland Group C++ compiler
case `$CC -V` in
*pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*)
_LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~
rm -rf $tpldir~
$CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
_LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~
rm -rf $tpldir~
$CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
$RANLIB $oldlib'
_LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~
rm -rf $tpldir~
$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~
rm -rf $tpldir~
$CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
$CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
;;
*) # Version 6 and above use weak symbols
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
;;
esac
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
;;
cxx*)
# Compaq C++
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
runpath_var=LD_RUN_PATH
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
#
# There doesn't appear to be a way to prevent this compiler from
# explicitly linking system object files so we need to strip them
# from the output so that they don't get included in the library
# dependencies.
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
;;
xl* | mpixl* | bgxl*)
# IBM XL 8.0 on PPC, with GNU ld
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
_LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
if test "x$supports_anon_versioning" = xyes; then
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~
cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
echo "local: *; };" >> $output_objdir/$libname.ver~
$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
fi
;;
*)
case `$CC -V 2>&1 | sed 5q` in
*Sun\ C*)
# Sun C++ 5.9
_LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
_LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
_LT_TAGVAR(compiler_needs_object, $1)=yes
# Not sure whether something based on
# $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
# would be better.
output_verbose_link_cmd='func_echo_all'
# Archives containing C++ object files must be created using
# "CC -xar", where "CC" is the Sun C++ compiler. This is
# necessary to make sure instantiated templates are included
# in the archive.
_LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
;;
esac
;;
esac
;;
lynxos*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
m88k*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
mvs*)
case $cc_basename in
cxx*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
esac
;;
netbsd*)
if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
_LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
wlarc=
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
fi
# Workaround some broken pre-1.5 toolchains
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
;;
*nto* | *qnx*)
_LT_TAGVAR(ld_shlibs, $1)=yes
;;
openbsd2*)
# C++ shared libraries are fairly broken
_LT_TAGVAR(ld_shlibs, $1)=no
;;
openbsd*)
if test -f /usr/libexec/ld.so; then
_LT_TAGVAR(hardcode_direct, $1)=yes
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
_LT_TAGVAR(hardcode_direct_absolute, $1)=yes
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
_LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
fi
output_verbose_link_cmd=func_echo_all
else
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
osf3* | osf4* | osf5*)
case $cc_basename in
KCC*)
# Kuck and Associates, Inc. (KAI) C++ Compiler
# KCC will only create a shared library if the output file
# ends with ".so" (or ".sl" for HP-UX), so rename the library
# to its proper name (with version) after linking.
_LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
# Archives containing C++ object files must be created using
# the KAI C++ compiler.
case $host in
osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;;
*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;;
esac
;;
RCC*)
# Rational C++ 2.4.1
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
cxx*)
case $host in
osf3*)
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
;;
*)
_LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*'
_LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
echo "-hidden">> $lib.exp~
$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~
$RM $lib.exp'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir'
;;
esac
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
#
# There doesn't appear to be a way to prevent this compiler from
# explicitly linking system object files so we need to strip them
# from the output so that they don't get included in the library
# dependencies.
output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
;;
*)
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
_LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*'
case $host in
osf3*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
;;
*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
;;
esac
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=:
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
else
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
fi
;;
esac
;;
psos*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
sunos4*)
case $cc_basename in
CC*)
# Sun C++ 4.x
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
lcc*)
# Lucid
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
esac
;;
solaris*)
case $cc_basename in
CC* | sunCC*)
# Sun C++ 4.2, 5.x and Centerline C++
_LT_TAGVAR(archive_cmds_need_lc,$1)=yes
_LT_TAGVAR(no_undefined_flag, $1)=' -zdefs'
_LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
$CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
case $host_os in
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
*)
# The compiler driver will combine and reorder linker options,
# but understands `-z linker_flag'.
# Supported since Solaris 2.6 (maybe 2.5.1?)
_LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
;;
esac
_LT_TAGVAR(link_all_deplibs, $1)=yes
output_verbose_link_cmd='func_echo_all'
# Archives containing C++ object files must be created using
# "CC -xar", where "CC" is the Sun C++ compiler. This is
# necessary to make sure instantiated templates are included
# in the archive.
_LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
;;
gcx*)
# Green Hills C++ Compiler
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
# The C++ compiler must be used to create the archive.
_LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
;;
*)
# GNU C++ compiler with Solaris linker
if test "$GXX" = yes && test "$with_gnu_ld" = no; then
_LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs'
if $CC --version | $GREP -v '^2\.7' > /dev/null; then
_LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
$CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
else
# g++ 2.7 appears to require `-G' NOT `-shared' on this
# platform.
_LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
_LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
$CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
# linking a shared library.
output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
fi
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
case $host_os in
solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
*)
_LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
;;
esac
fi
;;
esac
;;
sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
runpath_var='LD_RUN_PATH'
case $cc_basename in
CC*)
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
;;
*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
;;
esac
;;
sysv5* | sco3.2v5* | sco5v6*)
# Note: We can NOT use -z defs as we might desire, because we do not
# link with -lc, and that would cause any symbols used from libc to
# always be unresolved, which means just about no library would
# ever link correctly. If we're not using GNU ld we use -z text
# though, which does catch some bad symbols but isn't as heavy-handed
# as -z defs.
_LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
_LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
_LT_TAGVAR(hardcode_shlibpath_var, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir'
_LT_TAGVAR(hardcode_libdir_separator, $1)=':'
_LT_TAGVAR(link_all_deplibs, $1)=yes
_LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
runpath_var='LD_RUN_PATH'
case $cc_basename in
CC*)
_LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~
'"$_LT_TAGVAR(old_archive_cmds, $1)"
_LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~
'"$_LT_TAGVAR(reload_cmds, $1)"
;;
*)
_LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
_LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
;;
esac
;;
tandem*)
case $cc_basename in
NCC*)
# NonStop-UX NCC 3.20
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
esac
;;
vxworks*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
*)
# FIXME: insert proper C++ library support
_LT_TAGVAR(ld_shlibs, $1)=no
;;
esac
AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)])
test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
_LT_TAGVAR(GCC, $1)="$GXX"
_LT_TAGVAR(LD, $1)="$LD"
## CAVEAT EMPTOR:
## There is no encapsulation within the following macros, do not change
## the running order or otherwise move them around unless you know exactly
## what you are doing...
_LT_SYS_HIDDEN_LIBDEPS($1)
_LT_COMPILER_PIC($1)
_LT_COMPILER_C_O($1)
_LT_COMPILER_FILE_LOCKS($1)
_LT_LINKER_SHLIBS($1)
_LT_SYS_DYNAMIC_LINKER($1)
_LT_LINKER_HARDCODE_LIBPATH($1)
_LT_CONFIG($1)
fi # test -n "$compiler"
CC=$lt_save_CC
CFLAGS=$lt_save_CFLAGS
LDCXX=$LD
LD=$lt_save_LD
GCC=$lt_save_GCC
with_gnu_ld=$lt_save_with_gnu_ld
lt_cv_path_LDCXX=$lt_cv_path_LD
lt_cv_path_LD=$lt_save_path_LD
lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
fi # test "$_lt_caught_CXX_error" != yes
AC_LANG_POP
])# _LT_LANG_CXX_CONFIG
# _LT_FUNC_STRIPNAME_CNF
# ----------------------
# func_stripname_cnf prefix suffix name
# strip PREFIX and SUFFIX off of NAME.
# PREFIX and SUFFIX must not contain globbing or regex special
# characters, hashes, percent signs, but SUFFIX may contain a leading
# dot (in which case that matches only a dot).
#
# This function is identical to the (non-XSI) version of func_stripname,
# except this one can be used by m4 code that may be executed by configure,
# rather than the libtool script.
m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl
AC_REQUIRE([_LT_DECL_SED])
AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])
func_stripname_cnf ()
{
case ${2} in
.*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
esac
} # func_stripname_cnf
])# _LT_FUNC_STRIPNAME_CNF
# _LT_SYS_HIDDEN_LIBDEPS([TAGNAME])
# ---------------------------------
# Figure out "hidden" library dependencies from verbose
# compiler output when linking a shared library.
# Parse the compiler output and extract the necessary
# objects, libraries and library flags.
m4_defun([_LT_SYS_HIDDEN_LIBDEPS],
[m4_require([_LT_FILEUTILS_DEFAULTS])dnl
AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl
# Dependencies to place before and after the object being linked:
_LT_TAGVAR(predep_objects, $1)=
_LT_TAGVAR(postdep_objects, $1)=
_LT_TAGVAR(predeps, $1)=
_LT_TAGVAR(postdeps, $1)=
_LT_TAGVAR(compiler_lib_search_path, $1)=
dnl we can't use the lt_simple_compile_test_code here,
dnl because it contains code intended for an executable,
dnl not a library. It's possible we should let each
dnl tag define a new lt_????_link_test_code variable,
dnl but it's only used here...
m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF
int a;
void foo (void) { a = 0; }
_LT_EOF
], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF
class Foo
{
public:
Foo (void) { a = 0; }
private:
int a;
};
_LT_EOF
], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF
subroutine foo
implicit none
integer*4 a
a=0
return
end
_LT_EOF
], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF
subroutine foo
implicit none
integer a
a=0
return
end
_LT_EOF
], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF
public class foo {
private int a;
public void bar (void) {
a = 0;
}
};
_LT_EOF
], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF
package foo
func foo() {
}
_LT_EOF
])
_lt_libdeps_save_CFLAGS=$CFLAGS
case "$CC $CFLAGS " in #(
*\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
*\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
*\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;;
esac
dnl Parse the compiler output and extract the necessary
dnl objects, libraries and library flags.
if AC_TRY_EVAL(ac_compile); then
# Parse the compiler output and extract the necessary
# objects, libraries and library flags.
# Sentinel used to keep track of whether or not we are before
# the conftest object file.
pre_test_object_deps_done=no
for p in `eval "$output_verbose_link_cmd"`; do
case ${prev}${p} in
-L* | -R* | -l*)
# Some compilers place space between "-{L,R}" and the path.
# Remove the space.
if test $p = "-L" ||
test $p = "-R"; then
prev=$p
continue
fi
# Expand the sysroot to ease extracting the directories later.
if test -z "$prev"; then
case $p in
-L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
-R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
-l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
esac
fi
case $p in
=*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
esac
if test "$pre_test_object_deps_done" = no; then
case ${prev} in
-L | -R)
# Internal compiler library paths should come after those
# provided the user. The postdeps already come after the
# user supplied libs so there is no need to process them.
if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then
_LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}"
else
_LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}"
fi
;;
# The "-l" case would never come before the object being
# linked, so don't bother handling this case.
esac
else
if test -z "$_LT_TAGVAR(postdeps, $1)"; then
_LT_TAGVAR(postdeps, $1)="${prev}${p}"
else
_LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}"
fi
fi
prev=
;;
*.lto.$objext) ;; # Ignore GCC LTO objects
*.$objext)
# This assumes that the test object file only shows up
# once in the compiler output.
if test "$p" = "conftest.$objext"; then
pre_test_object_deps_done=yes
continue
fi
if test "$pre_test_object_deps_done" = no; then
if test -z "$_LT_TAGVAR(predep_objects, $1)"; then
_LT_TAGVAR(predep_objects, $1)="$p"
else
_LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p"
fi
else
if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then
_LT_TAGVAR(postdep_objects, $1)="$p"
else
_LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p"
fi
fi
;;
*) ;; # Ignore the rest.
esac
done
# Clean up.
rm -f a.out a.exe
else
echo "libtool.m4: error: problem compiling $1 test program"
fi
$RM -f confest.$objext
CFLAGS=$_lt_libdeps_save_CFLAGS
# PORTME: override above test on systems where it is broken
m4_if([$1], [CXX],
[case $host_os in
interix[[3-9]]*)
# Interix 3.5 installs completely hosed .la files for C++, so rather than
# hack all around it, let's just trust "g++" to DTRT.
_LT_TAGVAR(predep_objects,$1)=
_LT_TAGVAR(postdep_objects,$1)=
_LT_TAGVAR(postdeps,$1)=
;;
linux*)
case `$CC -V 2>&1 | sed 5q` in
*Sun\ C*)
# Sun C++ 5.9
# The more standards-conforming stlport4 library is
# incompatible with the Cstd library. Avoid specifying
# it if it's in CXXFLAGS. Ignore libCrun as
# -library=stlport4 depends on it.
case " $CXX $CXXFLAGS " in
*" -library=stlport4 "*)
solaris_use_stlport4=yes
;;
esac
if test "$solaris_use_stlport4" != yes; then
_LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
fi
;;
esac
;;
solaris*)
case $cc_basename in
CC* | sunCC*)
# The more standards-conforming stlport4 library is
# incompatible with the Cstd library. Avoid specifying
# it if it's in CXXFLAGS. Ignore libCrun as
# -library=stlport4 depends on it.
case " $CXX $CXXFLAGS " in
*" -library=stlport4 "*)
solaris_use_stlport4=yes
;;
esac
# Adding this requires a known-good setup of shared libraries for
# Sun compiler versions before 5.6, else PIC objects from an old
# archive will be linked into the output, leading to subtle bugs.
if test "$solaris_use_stlport4" != yes; then
_LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
fi
;;
esac
;;
esac
])
case " $_LT_TAGVAR(postdeps, $1) " in
*" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;;
esac
_LT_TAGVAR(compiler_lib_search_dirs, $1)=
if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then
_LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
fi
_LT_TAGDECL([], [compiler_lib_search_dirs], [1],
[The directories searched by this compiler when creating a shared library])
_LT_TAGDECL([], [predep_objects], [1],
[Dependencies to place before and after the objects being linked to
create a shared library])
_LT_TAGDECL([], [postdep_objects], [1])
_LT_TAGDECL([], [predeps], [1])
_LT_TAGDECL([], [postdeps], [1])
_LT_TAGDECL([], [compiler_lib_search_path], [1],
[The library search path used internally by the compiler when linking
a shared library])
])# _LT_SYS_HIDDEN_LIBDEPS
# _LT_LANG_F77_CONFIG([TAG])
# --------------------------
# Ensure that the configuration variables for a Fortran 77 compiler are
# suitably defined. These variables are subsequently used by _LT_CONFIG
# to write the compiler configuration to `libtool'.
m4_defun([_LT_LANG_F77_CONFIG],
[AC_LANG_PUSH(Fortran 77)
if test -z "$F77" || test "X$F77" = "Xno"; then
_lt_disable_F77=yes
fi
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
_LT_TAGVAR(allow_undefined_flag, $1)=
_LT_TAGVAR(always_export_symbols, $1)=no
_LT_TAGVAR(archive_expsym_cmds, $1)=
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
_LT_TAGVAR(hardcode_libdir_separator, $1)=
_LT_TAGVAR(hardcode_minus_L, $1)=no
_LT_TAGVAR(hardcode_automatic, $1)=no
_LT_TAGVAR(inherit_rpath, $1)=no
_LT_TAGVAR(module_cmds, $1)=
_LT_TAGVAR(module_expsym_cmds, $1)=
_LT_TAGVAR(link_all_deplibs, $1)=unknown
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
_LT_TAGVAR(reload_flag, $1)=$reload_flag
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
_LT_TAGVAR(no_undefined_flag, $1)=
_LT_TAGVAR(whole_archive_flag_spec, $1)=
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
# Source file extension for f77 test sources.
ac_ext=f
# Object file extension for compiled f77 test sources.
objext=o
_LT_TAGVAR(objext, $1)=$objext
# No sense in running all these tests if we already determined that
# the F77 compiler isn't working. Some variables (like enable_shared)
# are currently assumed to apply to all compilers on this platform,
# and will be corrupted by setting them based on a non-working compiler.
if test "$_lt_disable_F77" != yes; then
# Code to be used in simple compile tests
lt_simple_compile_test_code="\
subroutine t
return
end
"
# Code to be used in simple link tests
lt_simple_link_test_code="\
program t
end
"
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
_LT_TAG_COMPILER
# save warnings/boilerplate of simple test code
_LT_COMPILER_BOILERPLATE
_LT_LINKER_BOILERPLATE
# Allow CC to be a program name with arguments.
lt_save_CC="$CC"
lt_save_GCC=$GCC
lt_save_CFLAGS=$CFLAGS
CC=${F77-"f77"}
CFLAGS=$FFLAGS
compiler=$CC
_LT_TAGVAR(compiler, $1)=$CC
_LT_CC_BASENAME([$compiler])
GCC=$G77
if test -n "$compiler"; then
AC_MSG_CHECKING([if libtool supports shared libraries])
AC_MSG_RESULT([$can_build_shared])
AC_MSG_CHECKING([whether to build shared libraries])
test "$can_build_shared" = "no" && enable_shared=no
# On AIX, shared libraries and static libraries use the same namespace, and
# are all built from PIC.
case $host_os in
aix3*)
test "$enable_shared" = yes && enable_static=no
if test -n "$RANLIB"; then
archive_cmds="$archive_cmds~\$RANLIB \$lib"
postinstall_cmds='$RANLIB $lib'
fi
;;
aix[[4-9]]*)
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
test "$enable_shared" = yes && enable_static=no
fi
;;
esac
AC_MSG_RESULT([$enable_shared])
AC_MSG_CHECKING([whether to build static libraries])
# Make sure either enable_shared or enable_static is yes.
test "$enable_shared" = yes || enable_static=yes
AC_MSG_RESULT([$enable_static])
_LT_TAGVAR(GCC, $1)="$G77"
_LT_TAGVAR(LD, $1)="$LD"
## CAVEAT EMPTOR:
## There is no encapsulation within the following macros, do not change
## the running order or otherwise move them around unless you know exactly
## what you are doing...
_LT_COMPILER_PIC($1)
_LT_COMPILER_C_O($1)
_LT_COMPILER_FILE_LOCKS($1)
_LT_LINKER_SHLIBS($1)
_LT_SYS_DYNAMIC_LINKER($1)
_LT_LINKER_HARDCODE_LIBPATH($1)
_LT_CONFIG($1)
fi # test -n "$compiler"
GCC=$lt_save_GCC
CC="$lt_save_CC"
CFLAGS="$lt_save_CFLAGS"
fi # test "$_lt_disable_F77" != yes
AC_LANG_POP
])# _LT_LANG_F77_CONFIG
# _LT_LANG_FC_CONFIG([TAG])
# -------------------------
# Ensure that the configuration variables for a Fortran compiler are
# suitably defined. These variables are subsequently used by _LT_CONFIG
# to write the compiler configuration to `libtool'.
m4_defun([_LT_LANG_FC_CONFIG],
[AC_LANG_PUSH(Fortran)
if test -z "$FC" || test "X$FC" = "Xno"; then
_lt_disable_FC=yes
fi
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
_LT_TAGVAR(allow_undefined_flag, $1)=
_LT_TAGVAR(always_export_symbols, $1)=no
_LT_TAGVAR(archive_expsym_cmds, $1)=
_LT_TAGVAR(export_dynamic_flag_spec, $1)=
_LT_TAGVAR(hardcode_direct, $1)=no
_LT_TAGVAR(hardcode_direct_absolute, $1)=no
_LT_TAGVAR(hardcode_libdir_flag_spec, $1)=
_LT_TAGVAR(hardcode_libdir_separator, $1)=
_LT_TAGVAR(hardcode_minus_L, $1)=no
_LT_TAGVAR(hardcode_automatic, $1)=no
_LT_TAGVAR(inherit_rpath, $1)=no
_LT_TAGVAR(module_cmds, $1)=
_LT_TAGVAR(module_expsym_cmds, $1)=
_LT_TAGVAR(link_all_deplibs, $1)=unknown
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
_LT_TAGVAR(reload_flag, $1)=$reload_flag
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
_LT_TAGVAR(no_undefined_flag, $1)=
_LT_TAGVAR(whole_archive_flag_spec, $1)=
_LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no
# Source file extension for fc test sources.
ac_ext=${ac_fc_srcext-f}
# Object file extension for compiled fc test sources.
objext=o
_LT_TAGVAR(objext, $1)=$objext
# No sense in running all these tests if we already determined that
# the FC compiler isn't working. Some variables (like enable_shared)
# are currently assumed to apply to all compilers on this platform,
# and will be corrupted by setting them based on a non-working compiler.
if test "$_lt_disable_FC" != yes; then
# Code to be used in simple compile tests
lt_simple_compile_test_code="\
subroutine t
return
end
"
# Code to be used in simple link tests
lt_simple_link_test_code="\
program t
end
"
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
_LT_TAG_COMPILER
# save warnings/boilerplate of simple test code
_LT_COMPILER_BOILERPLATE
_LT_LINKER_BOILERPLATE
# Allow CC to be a program name with arguments.
lt_save_CC="$CC"
lt_save_GCC=$GCC
lt_save_CFLAGS=$CFLAGS
CC=${FC-"f95"}
CFLAGS=$FCFLAGS
compiler=$CC
GCC=$ac_cv_fc_compiler_gnu
_LT_TAGVAR(compiler, $1)=$CC
_LT_CC_BASENAME([$compiler])
if test -n "$compiler"; then
AC_MSG_CHECKING([if libtool supports shared libraries])
AC_MSG_RESULT([$can_build_shared])
AC_MSG_CHECKING([whether to build shared libraries])
test "$can_build_shared" = "no" && enable_shared=no
# On AIX, shared libraries and static libraries use the same namespace, and
# are all built from PIC.
case $host_os in
aix3*)
test "$enable_shared" = yes && enable_static=no
if test -n "$RANLIB"; then
archive_cmds="$archive_cmds~\$RANLIB \$lib"
postinstall_cmds='$RANLIB $lib'
fi
;;
aix[[4-9]]*)
if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
test "$enable_shared" = yes && enable_static=no
fi
;;
esac
AC_MSG_RESULT([$enable_shared])
AC_MSG_CHECKING([whether to build static libraries])
# Make sure either enable_shared or enable_static is yes.
test "$enable_shared" = yes || enable_static=yes
AC_MSG_RESULT([$enable_static])
_LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu"
_LT_TAGVAR(LD, $1)="$LD"
## CAVEAT EMPTOR:
## There is no encapsulation within the following macros, do not change
## the running order or otherwise move them around unless you know exactly
## what you are doing...
_LT_SYS_HIDDEN_LIBDEPS($1)
_LT_COMPILER_PIC($1)
_LT_COMPILER_C_O($1)
_LT_COMPILER_FILE_LOCKS($1)
_LT_LINKER_SHLIBS($1)
_LT_SYS_DYNAMIC_LINKER($1)
_LT_LINKER_HARDCODE_LIBPATH($1)
_LT_CONFIG($1)
fi # test -n "$compiler"
GCC=$lt_save_GCC
CC=$lt_save_CC
CFLAGS=$lt_save_CFLAGS
fi # test "$_lt_disable_FC" != yes
AC_LANG_POP
])# _LT_LANG_FC_CONFIG
# _LT_LANG_GCJ_CONFIG([TAG])
# --------------------------
# Ensure that the configuration variables for the GNU Java Compiler compiler
# are suitably defined. These variables are subsequently used by _LT_CONFIG
# to write the compiler configuration to `libtool'.
m4_defun([_LT_LANG_GCJ_CONFIG],
[AC_REQUIRE([LT_PROG_GCJ])dnl
AC_LANG_SAVE
# Source file extension for Java test sources.
ac_ext=java
# Object file extension for compiled Java test sources.
objext=o
_LT_TAGVAR(objext, $1)=$objext
# Code to be used in simple compile tests
lt_simple_compile_test_code="class foo {}"
# Code to be used in simple link tests
lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }'
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
_LT_TAG_COMPILER
# save warnings/boilerplate of simple test code
_LT_COMPILER_BOILERPLATE
_LT_LINKER_BOILERPLATE
# Allow CC to be a program name with arguments.
lt_save_CC=$CC
lt_save_CFLAGS=$CFLAGS
lt_save_GCC=$GCC
GCC=yes
CC=${GCJ-"gcj"}
CFLAGS=$GCJFLAGS
compiler=$CC
_LT_TAGVAR(compiler, $1)=$CC
_LT_TAGVAR(LD, $1)="$LD"
_LT_CC_BASENAME([$compiler])
# GCJ did not exist at the time GCC didn't implicitly link libc in.
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
_LT_TAGVAR(reload_flag, $1)=$reload_flag
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
## CAVEAT EMPTOR:
## There is no encapsulation within the following macros, do not change
## the running order or otherwise move them around unless you know exactly
## what you are doing...
if test -n "$compiler"; then
_LT_COMPILER_NO_RTTI($1)
_LT_COMPILER_PIC($1)
_LT_COMPILER_C_O($1)
_LT_COMPILER_FILE_LOCKS($1)
_LT_LINKER_SHLIBS($1)
_LT_LINKER_HARDCODE_LIBPATH($1)
_LT_CONFIG($1)
fi
AC_LANG_RESTORE
GCC=$lt_save_GCC
CC=$lt_save_CC
CFLAGS=$lt_save_CFLAGS
])# _LT_LANG_GCJ_CONFIG
# _LT_LANG_GO_CONFIG([TAG])
# --------------------------
# Ensure that the configuration variables for the GNU Go compiler
# are suitably defined. These variables are subsequently used by _LT_CONFIG
# to write the compiler configuration to `libtool'.
m4_defun([_LT_LANG_GO_CONFIG],
[AC_REQUIRE([LT_PROG_GO])dnl
AC_LANG_SAVE
# Source file extension for Go test sources.
ac_ext=go
# Object file extension for compiled Go test sources.
objext=o
_LT_TAGVAR(objext, $1)=$objext
# Code to be used in simple compile tests
lt_simple_compile_test_code="package main; func main() { }"
# Code to be used in simple link tests
lt_simple_link_test_code='package main; func main() { }'
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
_LT_TAG_COMPILER
# save warnings/boilerplate of simple test code
_LT_COMPILER_BOILERPLATE
_LT_LINKER_BOILERPLATE
# Allow CC to be a program name with arguments.
lt_save_CC=$CC
lt_save_CFLAGS=$CFLAGS
lt_save_GCC=$GCC
GCC=yes
CC=${GOC-"gccgo"}
CFLAGS=$GOFLAGS
compiler=$CC
_LT_TAGVAR(compiler, $1)=$CC
_LT_TAGVAR(LD, $1)="$LD"
_LT_CC_BASENAME([$compiler])
# Go did not exist at the time GCC didn't implicitly link libc in.
_LT_TAGVAR(archive_cmds_need_lc, $1)=no
_LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
_LT_TAGVAR(reload_flag, $1)=$reload_flag
_LT_TAGVAR(reload_cmds, $1)=$reload_cmds
## CAVEAT EMPTOR:
## There is no encapsulation within the following macros, do not change
## the running order or otherwise move them around unless you know exactly
## what you are doing...
if test -n "$compiler"; then
_LT_COMPILER_NO_RTTI($1)
_LT_COMPILER_PIC($1)
_LT_COMPILER_C_O($1)
_LT_COMPILER_FILE_LOCKS($1)
_LT_LINKER_SHLIBS($1)
_LT_LINKER_HARDCODE_LIBPATH($1)
_LT_CONFIG($1)
fi
AC_LANG_RESTORE
GCC=$lt_save_GCC
CC=$lt_save_CC
CFLAGS=$lt_save_CFLAGS
])# _LT_LANG_GO_CONFIG
# _LT_LANG_RC_CONFIG([TAG])
# -------------------------
# Ensure that the configuration variables for the Windows resource compiler
# are suitably defined. These variables are subsequently used by _LT_CONFIG
# to write the compiler configuration to `libtool'.
m4_defun([_LT_LANG_RC_CONFIG],
[AC_REQUIRE([LT_PROG_RC])dnl
AC_LANG_SAVE
# Source file extension for RC test sources.
ac_ext=rc
# Object file extension for compiled RC test sources.
objext=o
_LT_TAGVAR(objext, $1)=$objext
# Code to be used in simple compile tests
lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
# Code to be used in simple link tests
lt_simple_link_test_code="$lt_simple_compile_test_code"
# ltmain only uses $CC for tagged configurations so make sure $CC is set.
_LT_TAG_COMPILER
# save warnings/boilerplate of simple test code
_LT_COMPILER_BOILERPLATE
_LT_LINKER_BOILERPLATE
# Allow CC to be a program name with arguments.
lt_save_CC="$CC"
lt_save_CFLAGS=$CFLAGS
lt_save_GCC=$GCC
GCC=
CC=${RC-"windres"}
CFLAGS=
compiler=$CC
_LT_TAGVAR(compiler, $1)=$CC
_LT_CC_BASENAME([$compiler])
_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
if test -n "$compiler"; then
:
_LT_CONFIG($1)
fi
GCC=$lt_save_GCC
AC_LANG_RESTORE
CC=$lt_save_CC
CFLAGS=$lt_save_CFLAGS
])# _LT_LANG_RC_CONFIG
# LT_PROG_GCJ
# -----------
AC_DEFUN([LT_PROG_GCJ],
[m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ],
[m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ],
[AC_CHECK_TOOL(GCJ, gcj,)
test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
AC_SUBST(GCJFLAGS)])])[]dnl
])
# Old name:
AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([LT_AC_PROG_GCJ], [])
# LT_PROG_GO
# ----------
AC_DEFUN([LT_PROG_GO],
[AC_CHECK_TOOL(GOC, gccgo,)
])
# LT_PROG_RC
# ----------
AC_DEFUN([LT_PROG_RC],
[AC_CHECK_TOOL(RC, windres,)
])
# Old name:
AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([LT_AC_PROG_RC], [])
# _LT_DECL_EGREP
# --------------
# If we don't have a new enough Autoconf to choose the best grep
# available, choose the one first in the user's PATH.
m4_defun([_LT_DECL_EGREP],
[AC_REQUIRE([AC_PROG_EGREP])dnl
AC_REQUIRE([AC_PROG_FGREP])dnl
test -z "$GREP" && GREP=grep
_LT_DECL([], [GREP], [1], [A grep program that handles long lines])
_LT_DECL([], [EGREP], [1], [An ERE matcher])
_LT_DECL([], [FGREP], [1], [A literal string matcher])
dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too
AC_SUBST([GREP])
])
# _LT_DECL_OBJDUMP
# --------------
# If we don't have a new enough Autoconf to choose the best objdump
# available, choose the one first in the user's PATH.
m4_defun([_LT_DECL_OBJDUMP],
[AC_CHECK_TOOL(OBJDUMP, objdump, false)
test -z "$OBJDUMP" && OBJDUMP=objdump
_LT_DECL([], [OBJDUMP], [1], [An object symbol dumper])
AC_SUBST([OBJDUMP])
])
# _LT_DECL_DLLTOOL
# ----------------
# Ensure DLLTOOL variable is set.
m4_defun([_LT_DECL_DLLTOOL],
[AC_CHECK_TOOL(DLLTOOL, dlltool, false)
test -z "$DLLTOOL" && DLLTOOL=dlltool
_LT_DECL([], [DLLTOOL], [1], [DLL creation program])
AC_SUBST([DLLTOOL])
])
# _LT_DECL_SED
# ------------
# Check for a fully-functional sed program, that truncates
# as few characters as possible. Prefer GNU sed if found.
m4_defun([_LT_DECL_SED],
[AC_PROG_SED
test -z "$SED" && SED=sed
Xsed="$SED -e 1s/^X//"
_LT_DECL([], [SED], [1], [A sed program that does not truncate output])
_LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"],
[Sed that helps us avoid accidentally triggering echo(1) options like -n])
])# _LT_DECL_SED
m4_ifndef([AC_PROG_SED], [
############################################################
# NOTE: This macro has been submitted for inclusion into #
# GNU Autoconf as AC_PROG_SED. When it is available in #
# a released version of Autoconf we should remove this #
# macro and use it instead. #
############################################################
m4_defun([AC_PROG_SED],
[AC_MSG_CHECKING([for a sed that does not truncate output])
AC_CACHE_VAL(lt_cv_path_SED,
[# Loop through the user's path and test for sed and gsed.
# Then use that list of sed's as ones to test for truncation.
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
test -z "$as_dir" && as_dir=.
for lt_ac_prog in sed gsed; do
for ac_exec_ext in '' $ac_executable_extensions; do
if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then
lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
fi
done
done
done
IFS=$as_save_IFS
lt_ac_max=0
lt_ac_count=0
# Add /usr/xpg4/bin/sed as it is typically found on Solaris
# along with /bin/sed that truncates output.
for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
test ! -f $lt_ac_sed && continue
cat /dev/null > conftest.in
lt_ac_count=0
echo $ECHO_N "0123456789$ECHO_C" >conftest.in
# Check for GNU sed and select it if it is found.
if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
lt_cv_path_SED=$lt_ac_sed
break
fi
while true; do
cat conftest.in conftest.in >conftest.tmp
mv conftest.tmp conftest.in
cp conftest.in conftest.nl
echo >>conftest.nl
$lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
cmp -s conftest.out conftest.nl || break
# 10000 chars as input seems more than enough
test $lt_ac_count -gt 10 && break
lt_ac_count=`expr $lt_ac_count + 1`
if test $lt_ac_count -gt $lt_ac_max; then
lt_ac_max=$lt_ac_count
lt_cv_path_SED=$lt_ac_sed
fi
done
done
])
SED=$lt_cv_path_SED
AC_SUBST([SED])
AC_MSG_RESULT([$SED])
])#AC_PROG_SED
])#m4_ifndef
# Old name:
AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([LT_AC_PROG_SED], [])
# _LT_CHECK_SHELL_FEATURES
# ------------------------
# Find out whether the shell is Bourne or XSI compatible,
# or has some other useful features.
m4_defun([_LT_CHECK_SHELL_FEATURES],
[AC_MSG_CHECKING([whether the shell understands some XSI constructs])
# Try some XSI features
xsi_shell=no
( _lt_dummy="a/b/c"
test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
= c,a/b,b/c, \
&& eval 'test $(( 1 + 1 )) -eq 2 \
&& test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
&& xsi_shell=yes
AC_MSG_RESULT([$xsi_shell])
_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell'])
AC_MSG_CHECKING([whether the shell understands "+="])
lt_shell_append=no
( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \
>/dev/null 2>&1 \
&& lt_shell_append=yes
AC_MSG_RESULT([$lt_shell_append])
_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append'])
if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
lt_unset=unset
else
lt_unset=false
fi
_LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl
# test EBCDIC or ASCII
case `echo X|tr X '\101'` in
A) # ASCII based system
# \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
lt_SP2NL='tr \040 \012'
lt_NL2SP='tr \015\012 \040\040'
;;
*) # EBCDIC based system
lt_SP2NL='tr \100 \n'
lt_NL2SP='tr \r\n \100\100'
;;
esac
_LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl
_LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl
])# _LT_CHECK_SHELL_FEATURES
# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY)
# ------------------------------------------------------
# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and
# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY.
m4_defun([_LT_PROG_FUNCTION_REPLACE],
[dnl {
sed -e '/^$1 ()$/,/^} # $1 /c\
$1 ()\
{\
m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1])
} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \
&& mv -f "$cfgfile.tmp" "$cfgfile" \
|| (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
test 0 -eq $? || _lt_function_replace_fail=:
])
# _LT_PROG_REPLACE_SHELLFNS
# -------------------------
# Replace existing portable implementations of several shell functions with
# equivalent extended shell implementations where those features are available..
m4_defun([_LT_PROG_REPLACE_SHELLFNS],
[if test x"$xsi_shell" = xyes; then
_LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl
case ${1} in
*/*) func_dirname_result="${1%/*}${2}" ;;
* ) func_dirname_result="${3}" ;;
esac])
_LT_PROG_FUNCTION_REPLACE([func_basename], [dnl
func_basename_result="${1##*/}"])
_LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl
case ${1} in
*/*) func_dirname_result="${1%/*}${2}" ;;
* ) func_dirname_result="${3}" ;;
esac
func_basename_result="${1##*/}"])
_LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl
# pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
# positional parameters, so assign one to ordinary parameter first.
func_stripname_result=${3}
func_stripname_result=${func_stripname_result#"${1}"}
func_stripname_result=${func_stripname_result%"${2}"}])
_LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl
func_split_long_opt_name=${1%%=*}
func_split_long_opt_arg=${1#*=}])
_LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl
func_split_short_opt_arg=${1#??}
func_split_short_opt_name=${1%"$func_split_short_opt_arg"}])
_LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl
case ${1} in
*.lo) func_lo2o_result=${1%.lo}.${objext} ;;
*) func_lo2o_result=${1} ;;
esac])
_LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo])
_LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))])
_LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}])
fi
if test x"$lt_shell_append" = xyes; then
_LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"])
_LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl
func_quote_for_eval "${2}"
dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \
eval "${1}+=\\\\ \\$func_quote_for_eval_result"])
# Save a `func_append' function call where possible by direct use of '+='
sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
&& mv -f "$cfgfile.tmp" "$cfgfile" \
|| (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
test 0 -eq $? || _lt_function_replace_fail=:
else
# Save a `func_append' function call even when '+=' is not available
sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
&& mv -f "$cfgfile.tmp" "$cfgfile" \
|| (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
test 0 -eq $? || _lt_function_replace_fail=:
fi
if test x"$_lt_function_replace_fail" = x":"; then
AC_MSG_WARN([Unable to substitute extended shell functions in $ofile])
fi
])
# _LT_PATH_CONVERSION_FUNCTIONS
# -----------------------------
# Determine which file name conversion functions should be used by
# func_to_host_file (and, implicitly, by func_to_host_path). These are needed
# for certain cross-compile configurations and native mingw.
m4_defun([_LT_PATH_CONVERSION_FUNCTIONS],
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
AC_REQUIRE([AC_CANONICAL_BUILD])dnl
AC_MSG_CHECKING([how to convert $build file names to $host format])
AC_CACHE_VAL(lt_cv_to_host_file_cmd,
[case $host in
*-*-mingw* )
case $build in
*-*-mingw* ) # actually msys
lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
;;
*-*-cygwin* )
lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
;;
* ) # otherwise, assume *nix
lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
;;
esac
;;
*-*-cygwin* )
case $build in
*-*-mingw* ) # actually msys
lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
;;
*-*-cygwin* )
lt_cv_to_host_file_cmd=func_convert_file_noop
;;
* ) # otherwise, assume *nix
lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
;;
esac
;;
* ) # unhandled hosts (and "normal" native builds)
lt_cv_to_host_file_cmd=func_convert_file_noop
;;
esac
])
to_host_file_cmd=$lt_cv_to_host_file_cmd
AC_MSG_RESULT([$lt_cv_to_host_file_cmd])
_LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd],
[0], [convert $build file names to $host format])dnl
AC_MSG_CHECKING([how to convert $build file names to toolchain format])
AC_CACHE_VAL(lt_cv_to_tool_file_cmd,
[#assume ordinary cross tools, or native build.
lt_cv_to_tool_file_cmd=func_convert_file_noop
case $host in
*-*-mingw* )
case $build in
*-*-mingw* ) # actually msys
lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
;;
esac
;;
esac
])
to_tool_file_cmd=$lt_cv_to_tool_file_cmd
AC_MSG_RESULT([$lt_cv_to_tool_file_cmd])
_LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd],
[0], [convert $build files to toolchain format])dnl
])# _LT_PATH_CONVERSION_FUNCTIONS
orc-0.4.18/m4/as-nano.m4 0000644 0001750 0001750 00000001171 11022604644 011425 0000000 0000000 dnl as-version.m4 0.1.0
dnl autostars m4 macro for versioning (modified)
dnl Thomas Vander Stichele
dnl David Schleef
dnl $Id: as-nano.m4,v 1.2 2007-03-16 23:30:02 ds Exp $
dnl AS_VERSION(ACTION-IF-NO-NANO, [ACTION-IF-NANO])
AC_DEFUN([AS_NANO],
[
AC_MSG_CHECKING(nano version)
NANO=$(echo AC_PACKAGE_VERSION | sed ['s/[0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\.*//'])
AC_SUBST(NANO)
if test x"$NANO" = x || test "x$NANO" = "x0" ; then
AC_MSG_RESULT([0 (release)])
NANO=0
ifelse([$1], , :, [$1])
else
AC_MSG_RESULT($NANO)
ifelse([$2], , :, [$2])
fi
])
orc-0.4.18/m4/gtk-doc.m4 0000644 0001750 0001750 00000004175 11551076053 011434 0000000 0000000 dnl -*- mode: autoconf -*-
# serial 1
dnl Usage:
dnl GTK_DOC_CHECK([minimum-gtk-doc-version])
AC_DEFUN([GTK_DOC_CHECK],
[
AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
dnl check for tools we added during development
AC_PATH_PROG([GTKDOC_CHECK],[gtkdoc-check])
AC_PATH_PROGS([GTKDOC_REBASE],[gtkdoc-rebase],[true])
AC_PATH_PROG([GTKDOC_MKPDF],[gtkdoc-mkpdf])
dnl for overriding the documentation installation directory
AC_ARG_WITH([html-dir],
AS_HELP_STRING([--with-html-dir=PATH], [path to installed docs]),,
[with_html_dir='${datadir}/gtk-doc/html'])
HTML_DIR="$with_html_dir"
AC_SUBST([HTML_DIR])
dnl enable/disable documentation building
AC_ARG_ENABLE([gtk-doc],
AS_HELP_STRING([--enable-gtk-doc],
[use gtk-doc to build documentation [[default=no]]]),,
[enable_gtk_doc=no])
if test x$enable_gtk_doc = xyes; then
ifelse([$1],[],
[PKG_CHECK_EXISTS([gtk-doc],,
AC_MSG_ERROR([gtk-doc not installed and --enable-gtk-doc requested]))],
[PKG_CHECK_EXISTS([gtk-doc >= $1],,
AC_MSG_ERROR([You need to have gtk-doc >= $1 installed to build $PACKAGE_NAME]))])
fi
AC_MSG_CHECKING([whether to build gtk-doc documentation])
AC_MSG_RESULT($enable_gtk_doc)
dnl enable/disable output formats
AC_ARG_ENABLE([gtk-doc-html],
AS_HELP_STRING([--enable-gtk-doc-html],
[build documentation in html format [[default=yes]]]),,
[enable_gtk_doc_html=yes])
AC_ARG_ENABLE([gtk-doc-pdf],
AS_HELP_STRING([--enable-gtk-doc-pdf],
[build documentation in pdf format [[default=no]]]),,
[enable_gtk_doc_pdf=no])
if test -z "$GTKDOC_MKPDF"; then
enable_gtk_doc_pdf=no
fi
AM_CONDITIONAL([ENABLE_GTK_DOC], [test x$enable_gtk_doc = xyes])
AM_CONDITIONAL([GTK_DOC_BUILD_HTML], [test x$enable_gtk_doc_html = xyes])
AM_CONDITIONAL([GTK_DOC_BUILD_PDF], [test x$enable_gtk_doc_pdf = xyes])
AM_CONDITIONAL([GTK_DOC_USE_LIBTOOL], [test -n "$LIBTOOL"])
AM_CONDITIONAL([GTK_DOC_USE_REBASE], [test -n "$GTKDOC_REBASE"])
])
orc-0.4.18/m4/ltoptions.m4 0000644 0001750 0001750 00000030073 12206165324 012131 0000000 0000000 # Helper functions for option handling. -*- Autoconf -*-
#
# Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation,
# Inc.
# Written by Gary V. Vaughan, 2004
#
# This file is free software; the Free Software Foundation gives
# unlimited permission to copy and/or distribute it, with or without
# modifications, as long as this notice is preserved.
# serial 7 ltoptions.m4
# This is to help aclocal find these macros, as it can't see m4_define.
AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])])
# _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME)
# ------------------------------------------
m4_define([_LT_MANGLE_OPTION],
[[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])])
# _LT_SET_OPTION(MACRO-NAME, OPTION-NAME)
# ---------------------------------------
# Set option OPTION-NAME for macro MACRO-NAME, and if there is a
# matching handler defined, dispatch to it. Other OPTION-NAMEs are
# saved as a flag.
m4_define([_LT_SET_OPTION],
[m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl
m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]),
_LT_MANGLE_DEFUN([$1], [$2]),
[m4_warning([Unknown $1 option `$2'])])[]dnl
])
# _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET])
# ------------------------------------------------------------
# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
m4_define([_LT_IF_OPTION],
[m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])])
# _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET)
# -------------------------------------------------------
# Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME
# are set.
m4_define([_LT_UNLESS_OPTIONS],
[m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
[m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option),
[m4_define([$0_found])])])[]dnl
m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3
])[]dnl
])
# _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST)
# ----------------------------------------
# OPTION-LIST is a space-separated list of Libtool options associated
# with MACRO-NAME. If any OPTION has a matching handler declared with
# LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about
# the unknown option and exit.
m4_defun([_LT_SET_OPTIONS],
[# Set options
m4_foreach([_LT_Option], m4_split(m4_normalize([$2])),
[_LT_SET_OPTION([$1], _LT_Option)])
m4_if([$1],[LT_INIT],[
dnl
dnl Simply set some default values (i.e off) if boolean options were not
dnl specified:
_LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no
])
_LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no
])
dnl
dnl If no reference was made to various pairs of opposing options, then
dnl we run the default mode handler for the pair. For example, if neither
dnl `shared' nor `disable-shared' was passed, we enable building of shared
dnl archives by default:
_LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED])
_LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC])
_LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC])
_LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install],
[_LT_ENABLE_FAST_INSTALL])
])
])# _LT_SET_OPTIONS
## --------------------------------- ##
## Macros to handle LT_INIT options. ##
## --------------------------------- ##
# _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME)
# -----------------------------------------
m4_define([_LT_MANGLE_DEFUN],
[[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])])
# LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE)
# -----------------------------------------------
m4_define([LT_OPTION_DEFINE],
[m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl
])# LT_OPTION_DEFINE
# dlopen
# ------
LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes
])
AU_DEFUN([AC_LIBTOOL_DLOPEN],
[_LT_SET_OPTION([LT_INIT], [dlopen])
AC_DIAGNOSE([obsolete],
[$0: Remove this warning and the call to _LT_SET_OPTION when you
put the `dlopen' option into LT_INIT's first parameter.])
])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], [])
# win32-dll
# ---------
# Declare package support for building win32 dll's.
LT_OPTION_DEFINE([LT_INIT], [win32-dll],
[enable_win32_dll=yes
case $host in
*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
AC_CHECK_TOOL(AS, as, false)
AC_CHECK_TOOL(DLLTOOL, dlltool, false)
AC_CHECK_TOOL(OBJDUMP, objdump, false)
;;
esac
test -z "$AS" && AS=as
_LT_DECL([], [AS], [1], [Assembler program])dnl
test -z "$DLLTOOL" && DLLTOOL=dlltool
_LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl
test -z "$OBJDUMP" && OBJDUMP=objdump
_LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl
])# win32-dll
AU_DEFUN([AC_LIBTOOL_WIN32_DLL],
[AC_REQUIRE([AC_CANONICAL_HOST])dnl
_LT_SET_OPTION([LT_INIT], [win32-dll])
AC_DIAGNOSE([obsolete],
[$0: Remove this warning and the call to _LT_SET_OPTION when you
put the `win32-dll' option into LT_INIT's first parameter.])
])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [])
# _LT_ENABLE_SHARED([DEFAULT])
# ----------------------------
# implement the --enable-shared flag, and supports the `shared' and
# `disable-shared' LT_INIT options.
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
m4_define([_LT_ENABLE_SHARED],
[m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl
AC_ARG_ENABLE([shared],
[AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@],
[build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])],
[p=${PACKAGE-default}
case $enableval in
yes) enable_shared=yes ;;
no) enable_shared=no ;;
*)
enable_shared=no
# Look at the argument we got. We use all the common list separators.
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
for pkg in $enableval; do
IFS="$lt_save_ifs"
if test "X$pkg" = "X$p"; then
enable_shared=yes
fi
done
IFS="$lt_save_ifs"
;;
esac],
[enable_shared=]_LT_ENABLE_SHARED_DEFAULT)
_LT_DECL([build_libtool_libs], [enable_shared], [0],
[Whether or not to build shared libraries])
])# _LT_ENABLE_SHARED
LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])])
LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])])
# Old names:
AC_DEFUN([AC_ENABLE_SHARED],
[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared])
])
AC_DEFUN([AC_DISABLE_SHARED],
[_LT_SET_OPTION([LT_INIT], [disable-shared])
])
AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AM_ENABLE_SHARED], [])
dnl AC_DEFUN([AM_DISABLE_SHARED], [])
# _LT_ENABLE_STATIC([DEFAULT])
# ----------------------------
# implement the --enable-static flag, and support the `static' and
# `disable-static' LT_INIT options.
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
m4_define([_LT_ENABLE_STATIC],
[m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl
AC_ARG_ENABLE([static],
[AS_HELP_STRING([--enable-static@<:@=PKGS@:>@],
[build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])],
[p=${PACKAGE-default}
case $enableval in
yes) enable_static=yes ;;
no) enable_static=no ;;
*)
enable_static=no
# Look at the argument we got. We use all the common list separators.
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
for pkg in $enableval; do
IFS="$lt_save_ifs"
if test "X$pkg" = "X$p"; then
enable_static=yes
fi
done
IFS="$lt_save_ifs"
;;
esac],
[enable_static=]_LT_ENABLE_STATIC_DEFAULT)
_LT_DECL([build_old_libs], [enable_static], [0],
[Whether or not to build static libraries])
])# _LT_ENABLE_STATIC
LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])])
LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])])
# Old names:
AC_DEFUN([AC_ENABLE_STATIC],
[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static])
])
AC_DEFUN([AC_DISABLE_STATIC],
[_LT_SET_OPTION([LT_INIT], [disable-static])
])
AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AM_ENABLE_STATIC], [])
dnl AC_DEFUN([AM_DISABLE_STATIC], [])
# _LT_ENABLE_FAST_INSTALL([DEFAULT])
# ----------------------------------
# implement the --enable-fast-install flag, and support the `fast-install'
# and `disable-fast-install' LT_INIT options.
# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'.
m4_define([_LT_ENABLE_FAST_INSTALL],
[m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl
AC_ARG_ENABLE([fast-install],
[AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@],
[optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])],
[p=${PACKAGE-default}
case $enableval in
yes) enable_fast_install=yes ;;
no) enable_fast_install=no ;;
*)
enable_fast_install=no
# Look at the argument we got. We use all the common list separators.
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
for pkg in $enableval; do
IFS="$lt_save_ifs"
if test "X$pkg" = "X$p"; then
enable_fast_install=yes
fi
done
IFS="$lt_save_ifs"
;;
esac],
[enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT)
_LT_DECL([fast_install], [enable_fast_install], [0],
[Whether or not to optimize for fast installation])dnl
])# _LT_ENABLE_FAST_INSTALL
LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])])
LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])])
# Old names:
AU_DEFUN([AC_ENABLE_FAST_INSTALL],
[_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install])
AC_DIAGNOSE([obsolete],
[$0: Remove this warning and the call to _LT_SET_OPTION when you put
the `fast-install' option into LT_INIT's first parameter.])
])
AU_DEFUN([AC_DISABLE_FAST_INSTALL],
[_LT_SET_OPTION([LT_INIT], [disable-fast-install])
AC_DIAGNOSE([obsolete],
[$0: Remove this warning and the call to _LT_SET_OPTION when you put
the `disable-fast-install' option into LT_INIT's first parameter.])
])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], [])
dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], [])
# _LT_WITH_PIC([MODE])
# --------------------
# implement the --with-pic flag, and support the `pic-only' and `no-pic'
# LT_INIT options.
# MODE is either `yes' or `no'. If omitted, it defaults to `both'.
m4_define([_LT_WITH_PIC],
[AC_ARG_WITH([pic],
[AS_HELP_STRING([--with-pic@<:@=PKGS@:>@],
[try to use only PIC/non-PIC objects @<:@default=use both@:>@])],
[lt_p=${PACKAGE-default}
case $withval in
yes|no) pic_mode=$withval ;;
*)
pic_mode=default
# Look at the argument we got. We use all the common list separators.
lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
for lt_pkg in $withval; do
IFS="$lt_save_ifs"
if test "X$lt_pkg" = "X$lt_p"; then
pic_mode=yes
fi
done
IFS="$lt_save_ifs"
;;
esac],
[pic_mode=default])
test -z "$pic_mode" && pic_mode=m4_default([$1], [default])
_LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl
])# _LT_WITH_PIC
LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])])
LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])])
# Old name:
AU_DEFUN([AC_LIBTOOL_PICMODE],
[_LT_SET_OPTION([LT_INIT], [pic-only])
AC_DIAGNOSE([obsolete],
[$0: Remove this warning and the call to _LT_SET_OPTION when you
put the `pic-only' option into LT_INIT's first parameter.])
])
dnl aclocal-1.4 backwards compatibility:
dnl AC_DEFUN([AC_LIBTOOL_PICMODE], [])
## ----------------- ##
## LTDL_INIT Options ##
## ----------------- ##
m4_define([_LTDL_MODE], [])
LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive],
[m4_define([_LTDL_MODE], [nonrecursive])])
LT_OPTION_DEFINE([LTDL_INIT], [recursive],
[m4_define([_LTDL_MODE], [recursive])])
LT_OPTION_DEFINE([LTDL_INIT], [subproject],
[m4_define([_LTDL_MODE], [subproject])])
m4_define([_LTDL_TYPE], [])
LT_OPTION_DEFINE([LTDL_INIT], [installable],
[m4_define([_LTDL_TYPE], [installable])])
LT_OPTION_DEFINE([LTDL_INIT], [convenience],
[m4_define([_LTDL_TYPE], [convenience])])
orc-0.4.18/m4/as-host-defines.m4 0000664 0001750 0001750 00000002736 12111024531 013063 0000000 0000000 dnl as-host-defines.m4 0.1.0
dnl autostars m4 macro for generating defines for various host architectures
dnl David Schleef
dnl $Id: as-host-defines.m4,v 1.3 2007-08-22 20:55:24 uid2631 Exp $
dnl AS_HOST_DEFINES()
AC_DEFUN([AS_HOST_DEFINES],
[
case "x${host_cpu}" in
xi?86 | k?)
HAVE_I386=yes
AC_DEFINE(HAVE_I386, 1, [Defined if host is i386])
;;
xx86_64|xamd64)
HAVE_AMD64=yes
AC_DEFINE(HAVE_AMD64, 1, [Defined if host is amd64])
;;
xpowerpc|xppc|xpowerpc64|xppc64)
HAVE_POWERPC=yes
AC_DEFINE(HAVE_POWERPC, 1, [Defined if host is powerpc])
;;
xarm*)
HAVE_ARM=yes
AC_DEFINE(HAVE_ARM, 1, [Defined if host is arm])
;;
xmipsel*)
HAVE_MIPSEL=yes
AC_DEFINE(HAVE_MIPSEL, 1, [Defined if host is mipsel])
esac
AM_CONDITIONAL(HAVE_I386, test "x$HAVE_I386" = "xyes")
AM_CONDITIONAL(HAVE_AMD64, test "x$HAVE_AMD64" = "xyes")
AM_CONDITIONAL(HAVE_POWERPC, test "x$HAVE_POWERPC" = "xyes")
AM_CONDITIONAL(HAVE_ARM, test "x$HAVE_ARM" = "xyes")
AM_CONDITIONAL(HAVE_MIPSEL, test "x$HAVE_MIPSEL" = "xyes")
case "${host_os}" in
mingw*)
HAVE_OS_WIN32=yes
AC_DEFINE(HAVE_OS_WIN32, 1, [Defined if host OS is MS Windows])
;;
linux*)
HAVE_OS_LINUX=yes
AC_DEFINE(HAVE_OS_LINUX, 1, [Defined if host OS is linux])
;;
esac
AM_CONDITIONAL(HAVE_OS_WIN32, test "$HAVE_OS_WIN32" = "yes")
AM_CONDITIONAL(HAVE_OS_LINUX, test "$HAVE_OS_LINUX" = "yes")
])
orc-0.4.18/m4/as-compiler-flag.m4 0000644 0001750 0001750 00000001354 11022604644 013216 0000000 0000000 dnl as-compiler-flag.m4 0.1.0
dnl autostars m4 macro for detection of compiler flags
dnl David Schleef
dnl $Id: as-compiler-flag.m4,v 1.1 2004-08-20 22:25:22 ds Exp $
dnl AS_COMPILER_FLAG(CFLAGS, ACTION-IF-ACCEPTED, [ACTION-IF-NOT-ACCEPTED])
dnl Tries to compile with the given CFLAGS.
dnl Runs ACTION-IF-ACCEPTED if the compiler can compile with the flags,
dnl and ACTION-IF-NOT-ACCEPTED otherwise.
AC_DEFUN([AS_COMPILER_FLAG],
[
AC_MSG_CHECKING([to see if compiler understands $1])
save_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS $1"
AC_TRY_COMPILE([ ], [], [flag_ok=yes], [flag_ok=no])
CFLAGS="$save_CFLAGS"
if test "X$flag_ok" = Xyes ; then
$2
true
else
$3
true
fi
AC_MSG_RESULT([$flag_ok])
])
orc-0.4.18/m4/lt~obsolete.m4 0000644 0001750 0001750 00000013756 12206165325 012462 0000000 0000000 # lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*-
#
# Copyright (C) 2004, 2005, 2007, 2009 Free Software Foundation, Inc.
# Written by Scott James Remnant, 2004.
#
# This file is free software; the Free Software Foundation gives
# unlimited permission to copy and/or distribute it, with or without
# modifications, as long as this notice is preserved.
# serial 5 lt~obsolete.m4
# These exist entirely to fool aclocal when bootstrapping libtool.
#
# In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN)
# which have later been changed to m4_define as they aren't part of the
# exported API, or moved to Autoconf or Automake where they belong.
#
# The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN
# in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us
# using a macro with the same name in our local m4/libtool.m4 it'll
# pull the old libtool.m4 in (it doesn't see our shiny new m4_define
# and doesn't know about Autoconf macros at all.)
#
# So we provide this file, which has a silly filename so it's always
# included after everything else. This provides aclocal with the
# AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything
# because those macros already exist, or will be overwritten later.
# We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6.
#
# Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here.
# Yes, that means every name once taken will need to remain here until
# we give up compatibility with versions before 1.7, at which point
# we need to keep only those names which we still refer to.
# This is to help aclocal find these macros, as it can't see m4_define.
AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])])
m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])])
m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])])
m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])])
m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])])
m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])])
m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])])
m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])])
m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])])
m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])])
m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])])
m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])])
m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])])
m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])])
m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])])
m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])])
m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])])
m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])])
m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])])
m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])])
m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])])
m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])])
m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])])
m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])])
m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])])
m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])])
m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])])
m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])])
m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])])
m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])])
m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])])
m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])])
m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])])
m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])])
m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])])
m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])])
m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])])
m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])])
m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])])
m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])])
m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])])
m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])])
m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])])
m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])])
m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])])
m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])])
m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])])
m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])])
m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])])
m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])])
m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])])
m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])])
m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])])
m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])])
m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])])
m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])])
m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])])
m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])])
m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])])
m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])])
m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])])
m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])])
orc-0.4.18/m4/ac_libtool_tags.m4 0000644 0001750 0001750 00000003177 11022604644 013226 0000000 0000000
# backported from libtool 1.6 by Paolo Bonzini
# When AC_LIBTOOL_TAGS is used, I redefine _LT_AC_TAGCONFIG
# to be more similar to the libtool 1.6 implementation, which
# uses an m4 loop and m4 case instead of a shell loop. This
# way the CXX/GCJ/F77/RC tests are not always expanded.
# AC_LIBTOOL_TAGS
# ---------------
# tags to enable
AC_DEFUN([AC_LIBTOOL_TAGS],
[m4_define([_LT_TAGS],[$1])
m4_define([_LT_AC_TAGCONFIG], [
if test -f "$ltmain"; then
if test ! -f "${ofile}"; then
AC_MSG_WARN([output file `$ofile' does not exist])
fi
if test -z "$LTCC"; then
eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
if test -z "$LTCC"; then
AC_MSG_WARN([output file `$ofile' does not look like a libtool script])
else
AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile'])
fi
fi
AC_FOREACH([_LT_TAG], _LT_TAGS,
[m4_case(_LT_TAG,
[CXX], [
if test -n "$CXX" && test "X$CXX" != "Xno"; then
AC_LIBTOOL_LANG_CXX_CONFIG
available_tags="$available_tags _LT_TAG"
fi],
[F77], [
if test -n "$F77" && test "X$F77" != "Xno"; then
AC_LIBTOOL_LANG_F77_CONFIG
available_tags="$available_tags _LT_TAG"
fi],
[GCJ], [
if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
AC_LIBTOOL_LANG_GCJ_CONFIG
available_tags="$available_tags _LT_TAG"
fi],
[RC], [
if test -n "$RC" && test "X$RC" != "Xno"; then
AC_LIBTOOL_LANG_RC_CONFIG
available_tags="$available_tags _LT_TAG"
fi],
[m4_errprintn(m4_location[: error: invalid tag name: ]"_LT_TAG")
m4_exit(1)])
])
fi
])dnl _LT_AC_TAG_CONFIG
])
orc-0.4.18/m4/ltsugar.m4 0000644 0001750 0001750 00000010424 12206165324 011555 0000000 0000000 # ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*-
#
# Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
# Written by Gary V. Vaughan, 2004
#
# This file is free software; the Free Software Foundation gives
# unlimited permission to copy and/or distribute it, with or without
# modifications, as long as this notice is preserved.
# serial 6 ltsugar.m4
# This is to help aclocal find these macros, as it can't see m4_define.
AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])])
# lt_join(SEP, ARG1, [ARG2...])
# -----------------------------
# Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their
# associated separator.
# Needed until we can rely on m4_join from Autoconf 2.62, since all earlier
# versions in m4sugar had bugs.
m4_define([lt_join],
[m4_if([$#], [1], [],
[$#], [2], [[$2]],
[m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])])
m4_define([_lt_join],
[m4_if([$#$2], [2], [],
[m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])])
# lt_car(LIST)
# lt_cdr(LIST)
# ------------
# Manipulate m4 lists.
# These macros are necessary as long as will still need to support
# Autoconf-2.59 which quotes differently.
m4_define([lt_car], [[$1]])
m4_define([lt_cdr],
[m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])],
[$#], 1, [],
[m4_dquote(m4_shift($@))])])
m4_define([lt_unquote], $1)
# lt_append(MACRO-NAME, STRING, [SEPARATOR])
# ------------------------------------------
# Redefine MACRO-NAME to hold its former content plus `SEPARATOR'`STRING'.
# Note that neither SEPARATOR nor STRING are expanded; they are appended
# to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked).
# No SEPARATOR is output if MACRO-NAME was previously undefined (different
# than defined and empty).
#
# This macro is needed until we can rely on Autoconf 2.62, since earlier
# versions of m4sugar mistakenly expanded SEPARATOR but not STRING.
m4_define([lt_append],
[m4_define([$1],
m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])])
# lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...])
# ----------------------------------------------------------
# Produce a SEP delimited list of all paired combinations of elements of
# PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list
# has the form PREFIXmINFIXSUFFIXn.
# Needed until we can rely on m4_combine added in Autoconf 2.62.
m4_define([lt_combine],
[m4_if(m4_eval([$# > 3]), [1],
[m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl
[[m4_foreach([_Lt_prefix], [$2],
[m4_foreach([_Lt_suffix],
]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[,
[_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])])
# lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ])
# -----------------------------------------------------------------------
# Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited
# by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ.
m4_define([lt_if_append_uniq],
[m4_ifdef([$1],
[m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1],
[lt_append([$1], [$2], [$3])$4],
[$5])],
[lt_append([$1], [$2], [$3])$4])])
# lt_dict_add(DICT, KEY, VALUE)
# -----------------------------
m4_define([lt_dict_add],
[m4_define([$1($2)], [$3])])
# lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE)
# --------------------------------------------
m4_define([lt_dict_add_subkey],
[m4_define([$1($2:$3)], [$4])])
# lt_dict_fetch(DICT, KEY, [SUBKEY])
# ----------------------------------
m4_define([lt_dict_fetch],
[m4_ifval([$3],
m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]),
m4_ifdef([$1($2)], [m4_defn([$1($2)])]))])
# lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE])
# -----------------------------------------------------------------
m4_define([lt_if_dict_fetch],
[m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4],
[$5],
[$6])])
# lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...])
# --------------------------------------------------------------
m4_define([lt_dict_filter],
[m4_if([$5], [], [],
[lt_join(m4_quote(m4_default([$4], [[, ]])),
lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]),
[lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl
])
orc-0.4.18/m4/pkg.m4 0000644 0001750 0001750 00000011223 11154067733 010661 0000000 0000000 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
#
# Copyright © 2004 Scott James Remnant .
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
# As a special exception to the GNU General Public License, if you
# distribute this file as part of a program that contains a
# configuration script generated by Autoconf, you may include it under
# the same distribution terms that you use for the rest of that program.
# PKG_PROG_PKG_CONFIG([MIN-VERSION])
# ----------------------------------
AC_DEFUN([PKG_PROG_PKG_CONFIG],
[m4_pattern_forbid([^_?PKG_[A-Z_]+$])
m4_pattern_allow([^PKG_CONFIG(_PATH)?$])
AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl
if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
AC_PATH_TOOL([PKG_CONFIG], [pkg-config])
fi
if test -n "$PKG_CONFIG"; then
_pkg_min_version=m4_ifval([$1], [$1], [0.9.0])
AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version])
if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
PKG_CONFIG=""
fi
fi[]dnl
])# PKG_PROG_PKG_CONFIG
# PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
#
# Check to see whether a particular set of modules exists. Similar
# to PKG_CHECK_MODULES(), but does not set variables or print errors.
#
#
# Similar to PKG_CHECK_MODULES, make sure that the first instance of
# this or PKG_CHECK_MODULES is called, or make sure to call
# PKG_CHECK_EXISTS manually
# --------------------------------------------------------------
AC_DEFUN([PKG_CHECK_EXISTS],
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
if test -n "$PKG_CONFIG" && \
AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then
m4_ifval([$2], [$2], [:])
m4_ifvaln([$3], [else
$3])dnl
fi])
# _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES])
# ---------------------------------------------
m4_define([_PKG_CONFIG],
[if test -n "$PKG_CONFIG"; then
if test -n "$$1"; then
pkg_cv_[]$1="$$1"
else
PKG_CHECK_EXISTS([$3],
[pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`],
[pkg_failed=yes])
fi
else
pkg_failed=untried
fi[]dnl
])# _PKG_CONFIG
# PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND],
# [ACTION-IF-NOT-FOUND])
#
#
# Note that if there is a possibility the first call to
# PKG_CHECK_MODULES might not happen, you should be sure to include an
# explicit call to PKG_PROG_PKG_CONFIG in your configure.ac
#
#
# --------------------------------------------------------------
AC_DEFUN([PKG_CHECK_MODULES],
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl
AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl
pkg_failed=no
AC_MSG_CHECKING([for $1])
_PKG_CONFIG([$1][_CFLAGS], [cflags], [$2])
_PKG_CONFIG([$1][_LIBS], [libs], [$2])
if test $pkg_failed = yes; then
$1[]_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"`
# Put the nasty error message in config.log where it belongs
echo "$$1[]_PKG_ERRORS" 1>&AS_MESSAGE_LOG_FD
ifelse([$4], , [AC_MSG_ERROR(dnl
[Package requirements ($2) were not met.
Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.
Alternatively you may set the $1_CFLAGS and $1_LIBS environment variables
to avoid the need to call pkg-config. See the pkg-config man page for
more details.])],
[$4])
elif test $pkg_failed = untried; then
ifelse([$4], , [AC_MSG_FAILURE(dnl
[The pkg-config script could not be found or is too old. Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.
Alternatively you may set the $1_CFLAGS and $1_LIBS environment variables
to avoid the need to call pkg-config. See the pkg-config man page for
more details.
To get pkg-config, see .])],
[$4])
else
$1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
$1[]_LIBS=$pkg_cv_[]$1[]_LIBS
AC_MSG_RESULT([yes])
ifelse([$3], , :, [$3])
fi[]dnl
])# PKG_CHECK_MODULES
orc-0.4.18/Makefile.in 0000664 0001750 0001750 00000070374 12206165330 011370 0000000 0000000 # Makefile.in generated by automake 1.11.6 from Makefile.am.
# @configure_input@
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
# Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
@SET_MAKE@
VPATH = @srcdir@
am__make_dryrun = \
{ \
am__dry=no; \
case $$MAKEFLAGS in \
*\\[\ \ ]*) \
echo 'am--echo: ; @echo "AM" OK' | $(MAKE) -f - 2>/dev/null \
| grep '^AM OK$$' >/dev/null || am__dry=yes;; \
*) \
for am__flg in $$MAKEFLAGS; do \
case $$am__flg in \
*=*|--*) ;; \
*n*) am__dry=yes; break;; \
esac; \
done;; \
esac; \
test $$am__dry = yes; \
}
pkgdatadir = $(datadir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkglibexecdir = $(libexecdir)/@PACKAGE@
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
subdir = .
DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
$(srcdir)/Makefile.in $(srcdir)/config.h.in \
$(srcdir)/orc-uninstalled.pc.in $(srcdir)/orc.pc.in \
$(top_srcdir)/configure COPYING TODO compile config.guess \
config.sub depcomp install-sh ltmain.sh missing
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ac_libtool_tags.m4 \
$(top_srcdir)/m4/as-compiler-flag.m4 \
$(top_srcdir)/m4/as-host-defines.m4 \
$(top_srcdir)/m4/as-nano.m4 $(top_srcdir)/m4/gtk-doc.m4 \
$(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
$(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
$(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
configure.lineno config.status.lineno
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = config.h
CONFIG_CLEAN_FILES = orc-uninstalled.pc orc.pc
CONFIG_CLEAN_VPATH_FILES =
SOURCES =
DIST_SOURCES =
RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
html-recursive info-recursive install-data-recursive \
install-dvi-recursive install-exec-recursive \
install-html-recursive install-info-recursive \
install-pdf-recursive install-ps-recursive install-recursive \
installcheck-recursive installdirs-recursive pdf-recursive \
ps-recursive uninstall-recursive
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
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 = f=`echo $$p | sed -e 's|^.*/||'`;
am__install_max = 40
am__nobase_strip_setup = \
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
am__nobase_strip = \
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
am__nobase_list = $(am__nobase_strip_setup); \
for p in $$list; do echo "$$p $$p"; done | \
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
if (++n[$$2] == $(am__install_max)) \
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
END { for (dir in files) print dir, files[dir] }'
am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
am__uninstall_files_from_dir = { \
test -z "$$files" \
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
am__installdirs = "$(DESTDIR)$(aclocaldir)" \
"$(DESTDIR)$(pkgconfigdir)"
DATA = $(aclocal_DATA) $(pkgconfig_DATA)
RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
distclean-recursive maintainer-clean-recursive
AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
distdir dist dist-all distcheck
ETAGS = etags
CTAGS = ctags
DIST_SUBDIRS = $(SUBDIRS)
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
distdir = $(PACKAGE)-$(VERSION)
top_distdir = $(distdir)
am__remove_distdir = \
if test -d "$(distdir)"; then \
find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \
&& rm -rf "$(distdir)" \
|| { sleep 5 && rm -rf "$(distdir)"; }; \
else :; fi
am__relativize = \
dir0=`pwd`; \
sed_first='s,^\([^/]*\)/.*$$,\1,'; \
sed_rest='s,^[^/]*/*,,'; \
sed_last='s,^.*/\([^/]*\)$$,\1,'; \
sed_butlast='s,/*[^/]*$$,,'; \
while test -n "$$dir1"; do \
first=`echo "$$dir1" | sed -e "$$sed_first"`; \
if test "$$first" != "."; then \
if test "$$first" = ".."; then \
dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
else \
first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
if test "$$first2" = "$$first"; then \
dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
else \
dir2="../$$dir2"; \
fi; \
dir0="$$dir0"/"$$first"; \
fi; \
fi; \
dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
done; \
reldir="$$dir2"
DIST_ARCHIVES = $(distdir).tar.gz
GZIP_ENV = --best
distuninstallcheck_listfiles = find . -type f -print
am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \
| sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$'
distcleancheck_listfiles = find . -type f -print
ACLOCAL = @ACLOCAL@
ACLOCAL_AMFLAGS = -I m4
AMTAR = @AMTAR@
AR = @AR@
AS = @AS@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCAS = @CCAS@
CCASDEPMODE = @CCASDEPMODE@
CCASFLAGS = @CCASFLAGS@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
DLLTOOL = @DLLTOOL@
DSYMUTIL = @DSYMUTIL@
DUMPBIN = @DUMPBIN@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
ERROR_CFLAGS = @ERROR_CFLAGS@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GREP = @GREP@
GTKDOC_CHECK = @GTKDOC_CHECK@
GTKDOC_MKPDF = @GTKDOC_MKPDF@
GTKDOC_REBASE = @GTKDOC_REBASE@
HTML_DIR = @HTML_DIR@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LD = @LD@
LDFLAGS = @LDFLAGS@
LIBM = @LIBM@
LIBOBJS = @LIBOBJS@
LIBRT = @LIBRT@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
LIPO = @LIPO@
LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@
MAKEINFO = @MAKEINFO@
MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
NANO = @NANO@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
OBJEXT = @OBJEXT@
ORC_CFLAGS = @ORC_CFLAGS@
ORC_LIBS = @ORC_LIBS@
ORC_LIBVERSION = @ORC_LIBVERSION@
ORC_MAJORMINOR = @ORC_MAJORMINOR@
OTOOL = @OTOOL@
OTOOL64 = @OTOOL64@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_URL = @PACKAGE_URL@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
PKG_CONFIG = @PKG_CONFIG@
PTHREAD_CFLAGS = @PTHREAD_CFLAGS@
PTHREAD_LIBS = @PTHREAD_LIBS@
RANLIB = @RANLIB@
SED = @SED@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
STRIP = @STRIP@
VERSION = @VERSION@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
ac_ct_AR = @ac_ct_AR@
ac_ct_CC = @ac_ct_CC@
ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
am__tar = @am__tar@
am__untar = @am__untar@
bindir = @bindir@
build = @build@
build_alias = @build_alias@
build_cpu = @build_cpu@
build_os = @build_os@
build_vendor = @build_vendor@
builddir = @builddir@
datadir = @datadir@
datarootdir = @datarootdir@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
host = @host@
host_alias = @host_alias@
host_cpu = @host_cpu@
host_os = @host_os@
host_vendor = @host_vendor@
htmldir = @htmldir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
pdfdir = @pdfdir@
pkgconfigdir = @pkgconfigdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
AUTOMAKE_OPTIONS = foreign
SUBDIRS = orc orc-test tools examples doc testsuite
EXTRA_DIST = COPYING autogen.sh gtk-doc.make orc.m4
DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc
pkgconfig_DATA = orc-$(ORC_MAJORMINOR).pc
BUILT_SOURCES = orc-$(ORC_MAJORMINOR)-uninstalled.pc
CLEANFILES = orc-$(ORC_MAJORMINOR).pc orc-$(ORC_MAJORMINOR)-uninstalled.pc
aclocaldir = $(datadir)/aclocal
aclocal_DATA = orc.m4
all: $(BUILT_SOURCES) config.h
$(MAKE) $(AM_MAKEFLAGS) all-recursive
.SUFFIXES:
am--refresh: Makefile
@:
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \
$(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \
&& exit 0; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --foreign Makefile
.PRECIOUS: Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
echo ' $(SHELL) ./config.status'; \
$(SHELL) ./config.status;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
$(SHELL) ./config.status --recheck
$(top_srcdir)/configure: $(am__configure_deps)
$(am__cd) $(srcdir) && $(AUTOCONF)
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
$(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
$(am__aclocal_m4_deps):
config.h: stamp-h1
@if test ! -f $@; then rm -f stamp-h1; else :; fi
@if test ! -f $@; then $(MAKE) $(AM_MAKEFLAGS) stamp-h1; else :; fi
stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status
@rm -f stamp-h1
cd $(top_builddir) && $(SHELL) ./config.status config.h
$(srcdir)/config.h.in: $(am__configure_deps)
($(am__cd) $(top_srcdir) && $(AUTOHEADER))
rm -f stamp-h1
touch $@
distclean-hdr:
-rm -f config.h stamp-h1
orc-uninstalled.pc: $(top_builddir)/config.status $(srcdir)/orc-uninstalled.pc.in
cd $(top_builddir) && $(SHELL) ./config.status $@
orc.pc: $(top_builddir)/config.status $(srcdir)/orc.pc.in
cd $(top_builddir) && $(SHELL) ./config.status $@
mostlyclean-libtool:
-rm -f *.lo
clean-libtool:
-rm -rf .libs _libs
distclean-libtool:
-rm -f libtool config.lt
install-aclocalDATA: $(aclocal_DATA)
@$(NORMAL_INSTALL)
@list='$(aclocal_DATA)'; test -n "$(aclocaldir)" || list=; \
if test -n "$$list"; then \
echo " $(MKDIR_P) '$(DESTDIR)$(aclocaldir)'"; \
$(MKDIR_P) "$(DESTDIR)$(aclocaldir)" || exit 1; \
fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
done | $(am__base_list) | \
while read files; do \
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(aclocaldir)'"; \
$(INSTALL_DATA) $$files "$(DESTDIR)$(aclocaldir)" || exit $$?; \
done
uninstall-aclocalDATA:
@$(NORMAL_UNINSTALL)
@list='$(aclocal_DATA)'; test -n "$(aclocaldir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
dir='$(DESTDIR)$(aclocaldir)'; $(am__uninstall_files_from_dir)
install-pkgconfigDATA: $(pkgconfig_DATA)
@$(NORMAL_INSTALL)
@list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \
if test -n "$$list"; then \
echo " $(MKDIR_P) '$(DESTDIR)$(pkgconfigdir)'"; \
$(MKDIR_P) "$(DESTDIR)$(pkgconfigdir)" || exit 1; \
fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
done | $(am__base_list) | \
while read files; do \
echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(pkgconfigdir)'"; \
$(INSTALL_DATA) $$files "$(DESTDIR)$(pkgconfigdir)" || exit $$?; \
done
uninstall-pkgconfigDATA:
@$(NORMAL_UNINSTALL)
@list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
dir='$(DESTDIR)$(pkgconfigdir)'; $(am__uninstall_files_from_dir)
# This directory's subdirectories are mostly independent; you can cd
# into them and run `make' without going through this Makefile.
# To change the values of `make' variables: instead of editing Makefiles,
# (1) if the variable is set in `config.status', edit `config.status'
# (which will cause the Makefiles to be regenerated when you run `make');
# (2) otherwise, pass the desired values on the `make' command line.
$(RECURSIVE_TARGETS):
@fail= failcom='exit 1'; \
for f in x $$MAKEFLAGS; do \
case $$f in \
*=* | --[!k]*);; \
*k*) failcom='fail=yes';; \
esac; \
done; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
list='$(SUBDIRS)'; for subdir in $$list; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
dot_seen=yes; \
local_target="$$target-am"; \
else \
local_target="$$target"; \
fi; \
($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| eval $$failcom; \
done; \
if test "$$dot_seen" = "no"; then \
$(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
fi; test -z "$$fail"
$(RECURSIVE_CLEAN_TARGETS):
@fail= failcom='exit 1'; \
for f in x $$MAKEFLAGS; do \
case $$f in \
*=* | --[!k]*);; \
*k*) failcom='fail=yes';; \
esac; \
done; \
dot_seen=no; \
case "$@" in \
distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
*) list='$(SUBDIRS)' ;; \
esac; \
rev=''; for subdir in $$list; do \
if test "$$subdir" = "."; then :; else \
rev="$$subdir $$rev"; \
fi; \
done; \
rev="$$rev ."; \
target=`echo $@ | sed s/-recursive//`; \
for subdir in $$rev; do \
echo "Making $$target in $$subdir"; \
if test "$$subdir" = "."; then \
local_target="$$target-am"; \
else \
local_target="$$target"; \
fi; \
($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
|| eval $$failcom; \
done && test -z "$$fail"
tags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
done
ctags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
done
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
mkid -fID $$unique
tags: TAGS
TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
set x; \
here=`pwd`; \
if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
include_option=--etags-include; \
empty_fix=.; \
else \
include_option=--include; \
empty_fix=; \
fi; \
list='$(SUBDIRS)'; for subdir in $$list; do \
if test "$$subdir" = .; then :; else \
test ! -f $$subdir/TAGS || \
set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
fi; \
done; \
list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
shift; \
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
if test $$# -gt 0; then \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
"$$@" $$unique; \
else \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$unique; \
fi; \
fi
ctags: CTAGS
CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
test -z "$(CTAGS_ARGS)$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$unique
GTAGS:
here=`$(am__cd) $(top_builddir) && pwd` \
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(DISTFILES)
$(am__remove_distdir)
test -d "$(distdir)" || mkdir "$(distdir)"
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d "$(distdir)/$$file"; then \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
|| exit 1; \
fi; \
done
@list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
if test "$$subdir" = .; then :; else \
$(am__make_dryrun) \
|| test -d "$(distdir)/$$subdir" \
|| $(MKDIR_P) "$(distdir)/$$subdir" \
|| exit 1; \
dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
$(am__relativize); \
new_distdir=$$reldir; \
dir1=$$subdir; dir2="$(top_distdir)"; \
$(am__relativize); \
new_top_distdir=$$reldir; \
echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
($(am__cd) $$subdir && \
$(MAKE) $(AM_MAKEFLAGS) \
top_distdir="$$new_top_distdir" \
distdir="$$new_distdir" \
am__remove_distdir=: \
am__skip_length_check=: \
am__skip_mode_fix=: \
distdir) \
|| exit 1; \
fi; \
done
-test -n "$(am__skip_mode_fix)" \
|| find "$(distdir)" -type d ! -perm -755 \
-exec chmod u+rwx,go+rx {} \; -o \
! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
! -type d ! -perm -400 -exec chmod a+r {} \; -o \
! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \
|| chmod -R a+r "$(distdir)"
dist-gzip: distdir
tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
$(am__remove_distdir)
dist-bzip2: distdir
tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2
$(am__remove_distdir)
dist-lzip: distdir
tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz
$(am__remove_distdir)
dist-lzma: distdir
tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma
$(am__remove_distdir)
dist-xz: distdir
tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz
$(am__remove_distdir)
dist-tarZ: distdir
tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
$(am__remove_distdir)
dist-shar: distdir
shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
$(am__remove_distdir)
dist-zip: distdir
-rm -f $(distdir).zip
zip -rq $(distdir).zip $(distdir)
$(am__remove_distdir)
dist dist-all: distdir
tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz
$(am__remove_distdir)
# This target untars the dist file and tries a VPATH configuration. Then
# it guarantees that the distribution is self-contained by making another
# tarfile.
distcheck: dist
case '$(DIST_ARCHIVES)' in \
*.tar.gz*) \
GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\
*.tar.bz2*) \
bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\
*.tar.lzma*) \
lzma -dc $(distdir).tar.lzma | $(am__untar) ;;\
*.tar.lz*) \
lzip -dc $(distdir).tar.lz | $(am__untar) ;;\
*.tar.xz*) \
xz -dc $(distdir).tar.xz | $(am__untar) ;;\
*.tar.Z*) \
uncompress -c $(distdir).tar.Z | $(am__untar) ;;\
*.shar.gz*) \
GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\
*.zip*) \
unzip $(distdir).zip ;;\
esac
chmod -R a-w $(distdir); chmod u+w $(distdir)
mkdir $(distdir)/_build
mkdir $(distdir)/_inst
chmod a-w $(distdir)
test -d $(distdir)/_build || exit 0; \
dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \
&& dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
&& am__cwd=`pwd` \
&& $(am__cd) $(distdir)/_build \
&& ../configure --srcdir=.. --prefix="$$dc_install_base" \
$(AM_DISTCHECK_CONFIGURE_FLAGS) \
$(DISTCHECK_CONFIGURE_FLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) dvi \
&& $(MAKE) $(AM_MAKEFLAGS) check \
&& $(MAKE) $(AM_MAKEFLAGS) install \
&& $(MAKE) $(AM_MAKEFLAGS) installcheck \
&& $(MAKE) $(AM_MAKEFLAGS) uninstall \
&& $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \
distuninstallcheck \
&& chmod -R a-w "$$dc_install_base" \
&& ({ \
(cd ../.. && umask 077 && mkdir "$$dc_destdir") \
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \
&& $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \
distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \
} || { rm -rf "$$dc_destdir"; exit 1; }) \
&& rm -rf "$$dc_destdir" \
&& $(MAKE) $(AM_MAKEFLAGS) dist \
&& rm -rf $(DIST_ARCHIVES) \
&& $(MAKE) $(AM_MAKEFLAGS) distcleancheck \
&& cd "$$am__cwd" \
|| exit 1
$(am__remove_distdir)
@(echo "$(distdir) archives ready for distribution: "; \
list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \
sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x'
distuninstallcheck:
@test -n '$(distuninstallcheck_dir)' || { \
echo 'ERROR: trying to run $@ with an empty' \
'$$(distuninstallcheck_dir)' >&2; \
exit 1; \
}; \
$(am__cd) '$(distuninstallcheck_dir)' || { \
echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \
exit 1; \
}; \
test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \
|| { echo "ERROR: files left after uninstall:" ; \
if test -n "$(DESTDIR)"; then \
echo " (check DESTDIR support)"; \
fi ; \
$(distuninstallcheck_listfiles) ; \
exit 1; } >&2
distcleancheck: distclean
@if test '$(srcdir)' = . ; then \
echo "ERROR: distcleancheck can only run from a VPATH build" ; \
exit 1 ; \
fi
@test `$(distcleancheck_listfiles) | wc -l` -eq 0 \
|| { echo "ERROR: files left in build directory after distclean:" ; \
$(distcleancheck_listfiles) ; \
exit 1; } >&2
check-am: all-am
check: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) check-recursive
all-am: Makefile $(DATA) config.h
installdirs: installdirs-recursive
installdirs-am:
for dir in "$(DESTDIR)$(aclocaldir)" "$(DESTDIR)$(pkgconfigdir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: $(BUILT_SOURCES)
$(MAKE) $(AM_MAKEFLAGS) install-recursive
install-exec: install-exec-recursive
install-data: install-data-recursive
uninstall: uninstall-recursive
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-recursive
install-strip:
if test -z '$(STRIP)'; then \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
install; \
else \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
fi
mostlyclean-generic:
clean-generic:
-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
distclean-generic:
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
-test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
clean: clean-recursive
clean-am: clean-generic clean-libtool mostlyclean-am
distclean: distclean-recursive
-rm -f $(am__CONFIG_DISTCLEAN_FILES)
-rm -f Makefile
distclean-am: clean-am distclean-generic distclean-hdr \
distclean-libtool distclean-tags
dvi: dvi-recursive
dvi-am:
html: html-recursive
html-am:
info: info-recursive
info-am:
install-data-am: install-aclocalDATA install-pkgconfigDATA
install-dvi: install-dvi-recursive
install-dvi-am:
install-exec-am:
install-html: install-html-recursive
install-html-am:
install-info: install-info-recursive
install-info-am:
install-man:
install-pdf: install-pdf-recursive
install-pdf-am:
install-ps: install-ps-recursive
install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-recursive
-rm -f $(am__CONFIG_DISTCLEAN_FILES)
-rm -rf $(top_srcdir)/autom4te.cache
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-recursive
mostlyclean-am: mostlyclean-generic mostlyclean-libtool
pdf: pdf-recursive
pdf-am:
ps: ps-recursive
ps-am:
uninstall-am: uninstall-aclocalDATA uninstall-pkgconfigDATA
.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) all check \
ctags-recursive install install-am install-strip \
tags-recursive
.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
all all-am am--refresh check check-am clean clean-generic \
clean-libtool ctags ctags-recursive dist dist-all dist-bzip2 \
dist-gzip dist-lzip dist-lzma dist-shar dist-tarZ dist-xz \
dist-zip distcheck distclean distclean-generic distclean-hdr \
distclean-libtool distclean-tags distcleancheck distdir \
distuninstallcheck dvi dvi-am html html-am info info-am \
install install-aclocalDATA 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-pkgconfigDATA install-ps install-ps-am install-strip \
installcheck installcheck-am installdirs installdirs-am \
maintainer-clean maintainer-clean-generic mostlyclean \
mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
tags tags-recursive uninstall uninstall-aclocalDATA \
uninstall-am uninstall-pkgconfigDATA
orc-$(ORC_MAJORMINOR).pc: orc.pc
cp orc.pc orc-$(ORC_MAJORMINOR).pc
orc-$(ORC_MAJORMINOR)-uninstalled.pc: orc-uninstalled.pc
cp orc-uninstalled.pc orc-$(ORC_MAJORMINOR)-uninstalled.pc
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
orc-0.4.18/config.h.in 0000664 0001750 0001750 00000010051 12206165327 011336 0000000 0000000 /* config.h.in. Generated from configure.ac by autoheader. */
/* Define if building universal (internal helper macro) */
#undef AC_APPLE_UNIVERSAL_BUILD
/* Enable Altivec backend */
#undef ENABLE_BACKEND_ALTIVEC
/* Enable c64x backend */
#undef ENABLE_BACKEND_C64X
/* Enable MIPS backend */
#undef ENABLE_BACKEND_MIPS
/* Enable MMX backend */
#undef ENABLE_BACKEND_MMX
/* Enable NEON backend */
#undef ENABLE_BACKEND_NEON
/* Enable SSE backend */
#undef ENABLE_BACKEND_SSE
/* Defined if host is amd64 */
#undef HAVE_AMD64
/* Defined if host is arm */
#undef HAVE_ARM
/* Defined if we have clock_gettime() */
#undef HAVE_CLOCK_GETTIME
/* Use malloc to allocate code for execution */
#undef HAVE_CODEMEM_MALLOC
/* Use mmap to allocate code for execution */
#undef HAVE_CODEMEM_MMAP
/* Use VirtualAlloc to allocate code for execution */
#undef HAVE_CODEMEM_VIRTUALALLOC
/* Define to 1 if you have the header file. */
#undef HAVE_DLFCN_H
/* Define to 1 if you have the `getpagesize' function. */
#undef HAVE_GETPAGESIZE
/* Define to 1 if you have the `gettimeofday' function. */
#undef HAVE_GETTIMEOFDAY
/* Defined if host is i386 */
#undef HAVE_I386
/* Define to 1 if you have the header file. */
#undef HAVE_INTTYPES_H
/* Define to 1 if you have the header file. */
#undef HAVE_MEMORY_H
/* Defined if host is mipsel */
#undef HAVE_MIPSEL
/* Define to 1 if you have a working `mmap' system call. */
#undef HAVE_MMAP
/* Defined if we have a monotonic clock */
#undef HAVE_MONOTONIC_CLOCK
/* Defined if host OS is linux */
#undef HAVE_OS_LINUX
/* Defined if host OS is MS Windows */
#undef HAVE_OS_WIN32
/* Define to 1 if you have the `posix_memalign' function. */
#undef HAVE_POSIX_MEMALIGN
/* Defined if host is powerpc */
#undef HAVE_POWERPC
/* Define to 1 if you have the `sigaction' function. */
#undef HAVE_SIGACTION
/* Define to 1 if you have the `sigsetjmp' function. */
#undef HAVE_SIGSETJMP
/* Define to 1 if you have the header file. */
#undef HAVE_STDINT_H
/* Define to 1 if you have the header file. */
#undef HAVE_STDLIB_H
/* Define to 1 if you have the header file. */
#undef HAVE_STRINGS_H
/* Define to 1 if you have the header file. */
#undef HAVE_STRING_H
/* Define to 1 if you have the header file. */
#undef HAVE_SYS_PARAM_H
/* Define to 1 if you have the header file. */
#undef HAVE_SYS_STAT_H
/* Define to 1 if you have the header file. */
#undef HAVE_SYS_TIME_H
/* Define to 1 if you have the header file. */
#undef HAVE_SYS_TYPES_H
/* Use pthread thread code */
#undef HAVE_THREAD_PTHREAD
/* Use Windows thread code */
#undef HAVE_THREAD_WIN32
/* Define to 1 if you have the header file. */
#undef HAVE_UNISTD_H
/* Define to 1 if you have the header file. */
#undef HAVE_VALGRIND_VALGRIND_H
/* Define to the sub-directory in which libtool stores uninstalled libraries.
*/
#undef LT_OBJDIR
/* Define to 1 if your C compiler doesn't accept -c and -o together. */
#undef NO_MINUS_C_MINUS_O
/* Defined for compiling internal code */
#undef ORC_EXPORTS
/* Name of package */
#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
/* Define to the full name of this package. */
#undef PACKAGE_NAME
/* Define to the full name and version of this package. */
#undef PACKAGE_STRING
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
/* Define to the home page for this package. */
#undef PACKAGE_URL
/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Version number of package */
#undef VERSION
/* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most
significant byte first (like Motorola and SPARC, unlike Intel). */
#if defined AC_APPLE_UNIVERSAL_BUILD
# if defined __BIG_ENDIAN__
# define WORDS_BIGENDIAN 1
# endif
#else
# ifndef WORDS_BIGENDIAN
# undef WORDS_BIGENDIAN
# endif
#endif
orc-0.4.18/configure.ac 0000664 0001750 0001750 00000013172 12206165123 011602 0000000 0000000 AC_PREREQ([2.58])
AC_INIT(orc,0.4.18)
dnl don't forget to update libversion
AS_NANO(ORC_GIT=no,ORC_GIT=yes)
AC_CANONICAL_HOST([])
AM_INIT_AUTOMAKE(1.6)
ORC_MAJORMINOR=0.4
AC_SUBST(ORC_MAJORMINOR)
AC_CONFIG_HEADER(config.h)
dnl CURRENT, REVISION, AGE
dnl - library source changed -> increment REVISION
dnl - interfaces added/removed/changed -> increment CURRENT, REVISION = 0
dnl - interfaces added -> increment AGE
dnl - interfaces removed -> AGE = 0
ORC_LIBVERSION="18:0:18"
AC_SUBST(ORC_LIBVERSION)
AC_LIBTOOL_WIN32_DLL
AC_LIBTOOL_TAGS([])
AC_PROG_LIBTOOL
AM_PROG_CC_C_O
AM_PROG_AS
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_SRCDIR([orc/orc.h])
ACLOCAL_AMFLAGS="-I m4 $ACLOCAL_AMFLAGS"
AC_SUBST(ACLOCAL_AMFLAGS)
AM_CONDITIONAL(CROSS_COMPILING, test "x$cross_compiling" = "xyes")
AC_CHECK_FUNCS([posix_memalign])
##################################################
# Check for gtk-doc.
##################################################
if test "x$cross_compiling" = "xyes" ; then
enable_gtk_doc=no
fi
GTK_DOC_CHECK([1.0])
AS_HOST_DEFINES()
AC_C_BIGENDIAN
AC_FUNC_MMAP()
AC_CHECK_HEADERS([inttypes.h])
AC_CHECK_HEADERS([sys/time.h])
AC_CHECK_HEADERS([unistd.h])
AC_CHECK_FUNCS([gettimeofday])
AC_CHECK_FUNCS([sigaction])
AC_CHECK_FUNCS([sigsetjmp])
AC_CHECK_LIBM
AC_SUBST(LIBM)
AC_CHECK_LIB(rt, clock_gettime,
AC_DEFINE(HAVE_CLOCK_GETTIME, 1, [Defined if we have clock_gettime()])
LIBRT=-lrt
)
AC_SUBST(LIBRT)
AC_CACHE_CHECK(for monotonic clocks,
orc_cv_monotonic_clock,AC_COMPILE_IFELSE([AC_LANG_SOURCE([[
#include
#include
int main() {
#if !(defined(_POSIX_MONOTONIC_CLOCK) && _POSIX_MONOTONIC_CLOCK >= 0 && defined(CLOCK_MONOTONIC))
#error No monotonic clock
#endif
return 0;
}
]])],orc_cv_monotonic_clock=yes,orc_cv_monotonic_clock=no))
if test "$orc_cv_monotonic_clock" = "yes"; then
AC_DEFINE(HAVE_MONOTONIC_CLOCK,1,[Defined if we have a monotonic clock])
fi
AC_CHECK_HEADERS([valgrind/valgrind.h])
AS_COMPILER_FLAG(-Wall, ORC_CFLAGS="$ORC_CFLAGS -Wall")
if test "x$ORC_GIT" = "xyes"
then
AS_COMPILER_FLAG(-Werror, ERROR_CFLAGS="-Werror")
fi
case "${host_os}" in
nobody_is_using_this_currently)
AC_DEFINE(HAVE_CODEMEM_MALLOC, 1, [Use malloc to allocate code for execution])
;;
mingw*|pw32*|cygwin*)
AC_DEFINE(HAVE_CODEMEM_VIRTUALALLOC, 1, [Use VirtualAlloc to allocate code for execution])
;;
linux*|darwin*|solaris*|netbsd*|freebsd*|openbsd*|kfreebsd*|dragonfly*|gnu*)
AC_DEFINE(HAVE_CODEMEM_MMAP, 1, [Use mmap to allocate code for execution])
;;
*)
AC_ERROR([no code allocation backend])
;;
esac
case "${host_os}" in
mingw*|pw32*|cygwin*)
AC_DEFINE(HAVE_THREAD_WIN32, 1, [Use Windows thread code])
;;
*android*)
AC_DEFINE(HAVE_THREAD_PTHREAD, 1, [Use pthread thread code])
PTHREAD_CFLAGS=
PTHREAD_LIBS=
;;
*)
AC_DEFINE(HAVE_THREAD_PTHREAD, 1, [Use pthread thread code])
PTHREAD_CFLAGS=
PTHREAD_LIBS=-lpthread
;;
esac
AC_SUBST(PTHREAD_CFLAGS)
AC_SUBST(PTHREAD_LIBS)
AC_ARG_ENABLE(backend,
AC_HELP_STRING([--enable-backend],[sse,mmx,neon,mips,all (default all)]),
[], [enable_backend=all])
case "${enable_backend}" in
sse)
ENABLE_BACKEND_SSE=yes
AC_DEFINE(ENABLE_BACKEND_SSE, 1, [Enable SSE backend])
;;
mmx)
ENABLE_BACKEND_MMX=yes
AC_DEFINE(ENABLE_BACKEND_MMX, 1, [Enable MMX backend])
;;
altivec)
ENABLE_BACKEND_ALTIVEC=yes
AC_DEFINE(ENABLE_BACKEND_ALTIVEC, 1, [Enable Altivec backend])
;;
neon)
ENABLE_BACKEND_NEON=yes
AC_DEFINE(ENABLE_BACKEND_NEON, 1, [Enable NEON backend])
;;
### ARM backend is disabled until it has decent coverage
# arm)
# ENABLE_BACKEND_ARM=yes
# AC_DEFINE(ENABLE_BACKEND_ARM, 1, [Enable Arm backend])
# ;;
c64x)
ENABLE_BACKEND_C64X=yes
AC_DEFINE(ENABLE_BACKEND_C64X, 1, [Enable c64x backend])
;;
mips)
ENABLE_BACKEND_MIPS=yes
AC_DEFINE(ENABLE_BACKEND_MIPS, 1, [Enable MIPS backend])
;;
all|auto)
ENABLE_BACKEND_SSE=yes
AC_DEFINE(ENABLE_BACKEND_SSE, 1, [Enable SSE backend])
ENABLE_BACKEND_MMX=yes
AC_DEFINE(ENABLE_BACKEND_MMX, 1, [Enable MMX backend])
ENABLE_BACKEND_ALTIVEC=yes
AC_DEFINE(ENABLE_BACKEND_ALTIVEC, 1, [Enable Altivec backend])
ENABLE_BACKEND_NEON=yes
AC_DEFINE(ENABLE_BACKEND_NEON, 1, [Enable NEON backend])
# ENABLE_BACKEND_ARM=yes
# AC_DEFINE(ENABLE_BACKEND_ARM, 1, [Enable Arm backend])
ENABLE_BACKEND_C64X=yes
AC_DEFINE(ENABLE_BACKEND_C64X, 1, [Enable c64x backend])
ENABLE_BACKEND_MIPS=yes
AC_DEFINE(ENABLE_BACKEND_MIPS, 1, [Enable MIPS backend])
;;
esac
AM_CONDITIONAL(ENABLE_BACKEND_SSE, test "x$ENABLE_BACKEND_SSE" = "xyes")
AM_CONDITIONAL(ENABLE_BACKEND_MMX, test "x$ENABLE_BACKEND_MMX" = "xyes")
AM_CONDITIONAL(ENABLE_BACKEND_ALTIVEC, test "x$ENABLE_BACKEND_ALTIVEC" = "xyes")
AM_CONDITIONAL(ENABLE_BACKEND_NEON, test "x$ENABLE_BACKEND_NEON" = "xyes")
AM_CONDITIONAL(ENABLE_BACKEND_ARM, test "x$ENABLE_BACKEND_ARM" = "xyes")
AM_CONDITIONAL(ENABLE_BACKEND_C64X, test "x$ENABLE_BACKEND_C64X" = "xyes")
AM_CONDITIONAL(ENABLE_BACKEND_MIPS, test "x$ENABLE_BACKEND_MIPS" = "xyes")
AC_DEFINE(ORC_EXPORTS, 1, [Defined for compiling internal code])
ORC_CFLAGS="$ORC_CFLAGS \$(ERROR_CFLAGS) -I\$(top_srcdir)"
AC_SUBST(ERROR_CFLAGS)
AC_SUBST(ORC_CFLAGS)
ORC_LIBS="\$(top_builddir)/orc/liborc-$ORC_MAJORMINOR.la $LIBM $LIBRT"
AC_SUBST(ORC_LIBS)
#CFLAGS=`echo $CFLAGS | sed s/O2/O0/`
pkgconfigdir="\$(libdir)/pkgconfig"
AC_SUBST(pkgconfigdir)
AC_CONFIG_FILES([
Makefile
doc/Makefile
doc/version.entities
orc/Makefile
orc-test/Makefile
testsuite/Makefile
testsuite/orcc/Makefile
testsuite/benchmorc/Makefile
examples/Makefile
tools/Makefile
orc-uninstalled.pc
orc.pc
])
AC_OUTPUT
orc-0.4.18/orc/ 0000775 0001750 0001750 00000000000 12206165373 010162 5 0000000 0000000 orc-0.4.18/orc/orccode.c 0000664 0001750 0001750 00000001065 12071634360 011663 0000000 0000000
#include "config.h"
#include
#include
#include
#include
#include
OrcCode *
orc_code_new (void)
{
OrcCode *code;
code = malloc(sizeof(OrcCode));
memset (code, 0, sizeof(OrcCode));
return code;
}
void
orc_code_free (OrcCode *code)
{
if (code->insns) {
free (code->insns);
code->insns = NULL;
}
if (code->vars) {
free (code->vars);
code->vars = NULL;
}
if (code->chunk) {
orc_code_chunk_free (code->chunk);
code->chunk = NULL;
}
free (code);
}
orc-0.4.18/orc/orconce.h 0000644 0001750 0001750 00000000455 11626334410 011700 0000000 0000000
#ifndef _ORC_ONCE_H_
#define _ORC_ONCE_H_
#include
ORC_BEGIN_DECLS
typedef struct _OrcMutex OrcMutex;
typedef struct _OrcOnce OrcOnce;
struct _OrcOnce {
int inited;
void *value;
};
void orc_once_mutex_lock (void);
void orc_once_mutex_unlock (void);
ORC_END_DECLS
#endif
orc-0.4.18/orc/orcutils.c 0000664 0001750 0001750 00000007565 12071634360 012124 0000000 0000000 /*
* ORC - Library of Optimized Inner Loops
* Copyright (c) 2003,2004 David A. Schleef
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include
#include
#include
#include
#include
#include
/**
* SECTION:orcutils
* @title: Utility functions
* @short_description: Orc utility functions
*/
char *
_strndup (const char *s, int n)
{
char *r;
r = malloc (n+1);
memcpy(r,s,n);
r[n]=0;
return r;
}
char **
strsplit (const char *s, char delimiter)
{
char **list = NULL;
const char *tok;
int n = 0;
while (*s == ' ') s++;
list = malloc (1 * sizeof(char *));
while (*s) {
tok = s;
while (*s && *s != delimiter) s++;
list[n] = _strndup (tok, s - tok);
while (*s && *s == delimiter) s++;
list = realloc (list, (n + 2) * sizeof(char *));
n++;
}
list[n] = NULL;
return list;
}
char *
get_tag_value (char *s, const char *tag)
{
char *flags;
char *end;
char *colon;
flags = strstr(s,tag);
if (flags == NULL) return NULL;
end = strchr(flags, '\n');
if (end == NULL) return NULL;
colon = strchr (flags, ':');
if (colon == NULL) return NULL;
colon++;
if(colon >= end) return NULL;
return _strndup (colon, end-colon);
}
orc_int64
_strtoll (const char *nptr, char **endptr, int base)
{
int neg = 0;
orc_int64 val = 0;
/* Skip all spaces */
while (isspace (*nptr))
nptr++;
if (!*nptr)
return val;
/* Get sign */
if (*nptr == '-') {
neg = 1;
nptr++;
} else if (*nptr == '+') {
nptr++;
}
if (!*nptr)
return val;
/* Try to detect the base if none was given */
if (base == 0) {
if (*nptr == '0' && (*(nptr + 1) == 'x' || *(nptr + 1) == 'X')) {
base = 16;
nptr += 2;
} else if (*nptr == '0') {
base = 8;
nptr++;
} else {
base = 10;
}
} else if (base == 16) {
if (*nptr == '0' && (*(nptr + 1) == 'x' || *(nptr + 1) == 'X'))
nptr += 2;
} else if (base == 8) {
if (*nptr == '0')
nptr++;
}
while (*nptr) {
int c = *nptr;
if (c >= '0' && c <= '9')
c = c - '0';
else if (c >= 'a' && c <= 'z')
c = 10 + c - 'a';
else if (c >= 'A' && c <= 'Z')
c = 10 + c - 'A';
else
break;
if (c >= base)
break;
if ((orc_uint64) val > ORC_UINT64_C(0xffffffffffffffff) / base ||
(orc_uint64) (val * base) > ORC_UINT64_C(0xffffffffffffffff) - c) {
val = ORC_UINT64_C(0xffffffffffffffff);
break;
}
val = val * base + c;
nptr++;
}
if (endptr)
*endptr = (char *) nptr;
return (neg) ? - val : val;
}
orc-0.4.18/orc/orcneon.h 0000644 0001750 0001750 00000003326 11563547254 011727 0000000 0000000
#ifndef _ORC_NEON_H_
#define _ORC_NEON_H_
#include
#include
ORC_BEGIN_DECLS
#ifdef ORC_ENABLE_UNSTABLE_API
const char *orc_neon_reg_name (int reg);
const char *orc_neon_reg_name_quad (int reg);
void orc_neon_loadb (OrcCompiler *compiler, OrcVariable *var, int update);
void orc_neon_loadw (OrcCompiler *compiler, OrcVariable *var, int update);
void orc_neon_loadl (OrcCompiler *compiler, OrcVariable *var, int update);
void orc_neon_loadq (OrcCompiler *compiler, int dest, int src1, int update, int is_aligned);
void orc_neon_load_vec_aligned (OrcCompiler *compiler, OrcVariable *var, int update);
void orc_neon_load_vec_unaligned (OrcCompiler *compiler, OrcVariable *var, int update);
void orc_neon_load_halfvec_unaligned (OrcCompiler *compiler, OrcVariable *var, int update);
void orc_neon_neg (OrcCompiler *compiler, int dest);
void orc_neon_storeb (OrcCompiler *compiler, int dest, int update, int src1, int is_aligned);
void orc_neon_storew (OrcCompiler *compiler, int dest, int update, int src1, int is_aligned);
void orc_neon_storel (OrcCompiler *compiler, int dest, int update, int src1, int is_aligned);
void orc_neon_storeq (OrcCompiler *compiler, int dest, int update, int src1, int is_aligned);
void orc_neon_emit_loadib (OrcCompiler *p, int reg, int value);
void orc_neon_emit_loadiw (OrcCompiler *p, int reg, int value);
void orc_neon_emit_loadil (OrcCompiler *p, int reg, int value);
void orc_neon_emit_loadpb (OrcCompiler *p, int reg, int param);
void orc_neon_emit_loadpw (OrcCompiler *p, int reg, int param);
void orc_neon_emit_loadpl (OrcCompiler *p, int reg, int param);
void orc_neon_preload (OrcCompiler *compiler, OrcVariable *var, int write,
int offset);
#endif
ORC_END_DECLS
#endif
orc-0.4.18/orc/generate-emulation.c 0000664 0001750 0001750 00000022154 12177015514 014035 0000000 0000000
#include "config.h"
#include
#include
#include
#include
#include
#include
void output_code_emulate (OrcProgram *p, FILE *output);
int verbose = 0;
int error = 0;
int compat;
char *target = "sse";
#define ORC_VERSION(a,b,c,d) ((a)*1000000 + (b)*10000 + (c)*100 + (d))
#define REQUIRE(a,b,c,d) do { \
if (ORC_VERSION((a),(b),(c),(d)) > compat) { \
fprintf(stderr, "Feature used that is incompatible with --compat\n"); \
exit (1); \
} \
} while (0)
void help (void)
{
printf("Usage:\n");
printf(" generate-emulation [OPTION...]\n");
printf("\n");
printf("Help Options:\n");
printf(" -h, --help Show help options\n");
printf("\n");
printf("Application Options:\n");
printf(" -o, --output FILE Write output to FILE\n");
printf(" --header Write header instead of .c file\n");
printf("\n");
exit (0);
}
int
main (int argc, char *argv[])
{
char *output_file = NULL;
char *input_file = NULL;
char *include_file = NULL;
FILE *output;
int i;
OrcOpcodeSet *opcode_set;
int output_header = FALSE;
orc_init ();
for(i=1;in_opcodes;i++){
OrcStaticOpcode *opcode = opcode_set->opcodes + i;
fprintf(output,
"void emulate_%s (OrcOpcodeExecutor *ex, int i, int n);\n",
opcode->name);
}
fprintf(output, "\n");
fprintf(output, "#endif\n");
fprintf(output, "\n");
} else {
fprintf(output, "#ifdef HAVE_CONFIG_H\n");
fprintf(output, "#include \"config.h\"\n");
fprintf(output, "#endif\n");
fprintf(output, "#include \n");
fprintf(output, "#include \n");
if (include_file) {
fprintf(output, "#include <%s>\n", include_file);
}
fprintf(output, "\n");
fprintf(output, "%s", orc_target_get_asm_preamble ("c"));
fprintf(output, "\n");
for(i=0;in_opcodes;i++){
char s[40];
OrcProgram *program;
OrcStaticOpcode *opcode = opcode_set->opcodes + i;
int args[4] = { -1, -1, -1, -1 };
int n_args = 0;
program = orc_program_new ();
sprintf(s, "emulate_%s", opcode->name);
orc_program_set_name (program, s);
if (opcode->dest_size[0] != 0) {
if (opcode->flags & ORC_STATIC_OPCODE_ACCUMULATOR) {
args[n_args++] =
orc_program_add_accumulator (program, opcode->dest_size[0], "d1");
} else {
args[n_args++] =
orc_program_add_destination (program, opcode->dest_size[0], "d1");
}
}
if (opcode->dest_size[1] != 0) {
args[n_args++] =
orc_program_add_destination (program, opcode->dest_size[1], "d2");
}
if (opcode->src_size[0] != 0) {
if (opcode->src_size[1] == 0 &&
opcode->flags & ORC_STATIC_OPCODE_SCALAR) {
args[n_args++] =
orc_program_add_parameter (program, opcode->src_size[0], "s1");
} else {
args[n_args++] =
orc_program_add_source (program, opcode->src_size[0], "s1");
}
}
if (opcode->src_size[1] != 0) {
if (opcode->flags & ORC_STATIC_OPCODE_SCALAR) {
args[n_args++] =
orc_program_add_parameter (program, opcode->src_size[1], "s2");
} else {
args[n_args++] =
orc_program_add_source (program, opcode->src_size[1], "s2");
}
}
if (opcode->src_size[2] != 0) {
if (opcode->flags & ORC_STATIC_OPCODE_SCALAR) {
args[n_args++] =
orc_program_add_parameter (program, opcode->src_size[2], "s3");
} else {
args[n_args++] =
orc_program_add_source (program, opcode->src_size[2], "s3");
}
}
orc_program_append_2 (program, opcode->name, 0, args[0], args[1],
args[2], args[3]);
output_code_emulate (program, output);
}
}
fclose (output);
if (error) exit(1);
return 0;
}
const char *varnames[] = {
"d1", "d2", "d3", "d4",
"s1", "s2", "s3", "s4",
"s5", "s6", "s7", "s8",
"a1", "a2", "a3", "d4",
"c1", "c2", "c3", "c4",
"c5", "c6", "c7", "c8",
"p1", "p2", "p3", "p4",
"p5", "p6", "p7", "p8",
"t1", "t2", "t3", "t4",
"t5", "t6", "t7", "t8",
"t9", "t10", "t11", "t12",
"t13", "t14", "t15", "t16"
};
const char *enumnames[] = {
"ORC_VAR_D1", "ORC_VAR_D2", "ORC_VAR_D3", "ORC_VAR_D4",
"ORC_VAR_S1", "ORC_VAR_S2", "ORC_VAR_S3", "ORC_VAR_S4",
"ORC_VAR_S5", "ORC_VAR_S6", "ORC_VAR_S7", "ORC_VAR_S8",
"ORC_VAR_A1", "ORC_VAR_A2", "ORC_VAR_A3", "ORC_VAR_A4",
"ORC_VAR_C1", "ORC_VAR_C2", "ORC_VAR_C3", "ORC_VAR_C4",
"ORC_VAR_C5", "ORC_VAR_C6", "ORC_VAR_C7", "ORC_VAR_C8",
"ORC_VAR_P1", "ORC_VAR_P2", "ORC_VAR_P3", "ORC_VAR_P4",
"ORC_VAR_P5", "ORC_VAR_P6", "ORC_VAR_P7", "ORC_VAR_P8",
"ORC_VAR_T1", "ORC_VAR_T2", "ORC_VAR_T3", "ORC_VAR_T4",
"ORC_VAR_T5", "ORC_VAR_T6", "ORC_VAR_T7", "ORC_VAR_T8",
"ORC_VAR_T9", "ORC_VAR_T10", "ORC_VAR_T11", "ORC_VAR_T12",
"ORC_VAR_T13", "ORC_VAR_T14", "ORC_VAR_T15", "ORC_VAR_T16"
};
#if 0
void
output_prototype (OrcProgram *p, FILE *output)
{
OrcVariable *var;
int i;
int need_comma;
fprintf(output, "%s (", p->name);
need_comma = FALSE;
for(i=0;i<4;i++){
var = &p->vars[ORC_VAR_D1 + i];
if (var->size) {
if (need_comma) fprintf(output, ", ");
if (var->type_name) {
fprintf(output, "%s * %s", var->type_name,
varnames[ORC_VAR_D1 + i]);
} else {
fprintf(output, "orc_uint%d * %s", var->size*8,
varnames[ORC_VAR_D1 + i]);
}
if (p->is_2d) {
fprintf(output, ", int %s_stride", varnames[ORC_VAR_D1 + i]);
}
need_comma = TRUE;
}
}
for(i=0;i<4;i++){
var = &p->vars[ORC_VAR_A1 + i];
if (var->size) {
if (need_comma) fprintf(output, ", ");
if (var->type_name) {
fprintf(output, "%s * %s", var->type_name,
varnames[ORC_VAR_A1 + i]);
} else {
fprintf(output, "orc_uint%d * %s", var->size*8,
varnames[ORC_VAR_A1 + i]);
}
need_comma = TRUE;
}
}
for(i=0;i<8;i++){
var = &p->vars[ORC_VAR_S1 + i];
if (var->size) {
if (need_comma) fprintf(output, ", ");
if (var->type_name) {
fprintf(output, "const %s * %s", var->type_name,
varnames[ORC_VAR_S1 + i]);
} else {
fprintf(output, "const orc_uint%d * %s", var->size*8,
varnames[ORC_VAR_S1 + i]);
}
if (p->is_2d) {
fprintf(output, ", int %s_stride", varnames[ORC_VAR_S1 + i]);
}
need_comma = TRUE;
}
}
for(i=0;i<8;i++){
var = &p->vars[ORC_VAR_P1 + i];
if (var->size) {
if (need_comma) fprintf(output, ", ");
if (var->is_float_param) {
REQUIRE(0,4,5,1);
}
fprintf(output, "%s %s",
var->is_float_param ? "float" : "int",
varnames[ORC_VAR_P1 + i]);
need_comma = TRUE;
}
}
if (p->constant_n == 0) {
if (need_comma) fprintf(output, ", ");
fprintf(output, "int n");
need_comma = TRUE;
}
if (p->is_2d && p->constant_m == 0) {
if (need_comma) fprintf(output, ", ");
fprintf(output, "int m");
}
fprintf(output, ")");
}
void
output_code_header (OrcProgram *p, FILE *output)
{
fprintf(output, "void ");
output_prototype (p, output);
fprintf(output, ";\n");
}
#endif
void
output_code_emulate (OrcProgram *p, FILE *output)
{
fprintf(output, "void\n");
if (p->constant_n) {
fprintf(output, "%s (OrcOpcodeExecutor *ex, int offset)\n", p->name);
} else {
fprintf(output, "%s (OrcOpcodeExecutor *ex, int offset, int n)\n", p->name);
}
fprintf(output, "{\n");
{
OrcCompileResult result;
result = orc_program_compile_full (p, orc_target_get_by_name("c"),
ORC_TARGET_C_BARE | ORC_TARGET_C_OPCODE);
if (ORC_COMPILE_RESULT_IS_SUCCESSFUL(result)) {
fprintf(output, "%s\n", orc_program_get_asm_code (p));
} else {
printf("Failed to compile %s\n", p->name);
error = TRUE;
}
}
fprintf(output, "}\n");
fprintf(output, "\n");
}
orc-0.4.18/orc/orcprogram-mips.c 0000664 0001750 0001750 00000064630 12111024531 013361 0000000 0000000 /*
Copyright 2002 - 2009 David A. Schleef
Copyright 2012 MIPS Technologies, Inc.
Author: Guillaume Emont
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
*/
#include
#include
#include
#include
#include "config.h"
unsigned int orc_compiler_orc_mips_get_default_flags (void);
void orc_compiler_orc_mips_init (OrcCompiler *compiler);
void orc_compiler_orc_mips_assemble (OrcCompiler *compiler);
const char * orc_compiler_orc_mips_get_asm_preamble (void);
void orc_mips_flush_cache (OrcCode *code);
/* in orcrules-mips.c */
void orc_compiler_orc_mips_register_rules (OrcTarget *target);
static OrcTarget orc_mips_target = {
"mips",
#ifdef HAVE_MIPSEL
TRUE,
#else
FALSE,
#endif
ORC_GP_REG_BASE,
orc_compiler_orc_mips_get_default_flags,
orc_compiler_orc_mips_init,
orc_compiler_orc_mips_assemble,
{ { 0 } },
0,
orc_compiler_orc_mips_get_asm_preamble,
NULL,
NULL,
orc_mips_flush_cache,
};
enum {
LABEL_REGION0_LOOP = 1,
LABEL_REGION1,
LABEL_REGION1_LOOP,
LABEL_REGION2,
LABEL_REGION2_LOOP, /* 5 */
LABEL_REGION2_LOOP_END,
LABEL_OUTER_LOOP,
LABEL_END
};
#define LAST_LABEL LABEL_END
void
orc_mips_init (void)
{
orc_target_register (&orc_mips_target);
orc_compiler_orc_mips_register_rules (&orc_mips_target);
}
unsigned int
orc_compiler_orc_mips_get_default_flags (void)
{
unsigned int flags = 0;
if (_orc_compiler_flag_debug) {
flags |= ORC_TARGET_MIPS_FRAME_POINTER;
}
return flags;
}
void
orc_compiler_orc_mips_init (OrcCompiler *compiler)
{
int i;
if (compiler->target_flags & ORC_TARGET_MIPS_FRAME_POINTER)
compiler->use_frame_pointer = TRUE;
for (i=ORC_GP_REG_BASE; ivalid_regs[i] = 1;
compiler->valid_regs[ORC_MIPS_ZERO] = 0; /* always 0 */
compiler->valid_regs[ORC_MIPS_AT] = 0; /* we shouldn't touch that (assembler
temporary) */
compiler->exec_reg = ORC_MIPS_A0;
compiler->valid_regs[ORC_MIPS_A0] = 0; /* first (and in our case only)
function argument */
compiler->valid_regs[ORC_MIPS_T0] = 0; /* $t0, $t1 and $t2 are used as loop */
compiler->valid_regs[ORC_MIPS_T1] = 0; /* counters */
compiler->valid_regs[ORC_MIPS_T2] = 0;
compiler->valid_regs[ORC_MIPS_T3] = 0;
compiler->valid_regs[ORC_MIPS_T4] = 0;
compiler->valid_regs[ORC_MIPS_T5] = 0;
compiler->valid_regs[ORC_MIPS_K0] = 0; /* for kernel/interupts */
compiler->valid_regs[ORC_MIPS_K1] = 0; /* for kernel/interupts */
compiler->valid_regs[ORC_MIPS_GP] = 0; /* global pointer */
compiler->valid_regs[ORC_MIPS_SP] = 0; /* stack pointer */
compiler->valid_regs[ORC_MIPS_FP] = 0; /* frame pointer */
compiler->valid_regs[ORC_MIPS_RA] = 0; /* return address */
for (i=0;ialloc_regs[i] = 0;
compiler->used_regs[i] = 0;
compiler->save_regs[i] = 0;
}
compiler->save_regs[ORC_MIPS_V0] = 1;
compiler->save_regs[ORC_MIPS_V1] = 1;
for (i=ORC_MIPS_S0; i<= ORC_MIPS_S7; i++)
compiler->save_regs[i] = 1;
switch (compiler->max_var_size) {
case 1:
compiler->loop_shift = 2;
break;
case 2:
compiler->loop_shift = 1;
break;
case 4:
compiler->loop_shift = 0;
break;
default:
ORC_ERROR("unhandled variable size %d", compiler->max_var_size);
}
/* Empirical evidence in a colorspace conversion benchmark shows that 3 is
* the best unroll shift. */
compiler->unroll_shift = 3;
compiler->unroll_index = 0;
for(i=0;in_insns;i++){
OrcInstruction *insn = compiler->insns + i;
OrcStaticOpcode *opcode = insn->opcode;
if ((strcmp (opcode->name, "loadupib") == 0)
|| (strcmp (opcode->name, "loadupdb") == 0)) {
compiler->vars[insn->src_args[0]].need_offset_reg = TRUE;
}
}
}
const char *
orc_compiler_orc_mips_get_asm_preamble (void)
{
return "\n"
"/* begin Orc MIPS target preamble */\n"
".abicalls\n" /* not exactly sure what this is, but linker complains
without it */
".set noreorder\n"
"/* end Orc MIPS target preamble */\n\n";
}
int
orc_mips_emit_prologue (OrcCompiler *compiler)
{
int i, stack_size;
unsigned int stack_increment;
if (compiler->use_frame_pointer) {
stack_size = 12; /* we stack at least fp and a0 and start at stack_increment 4 */
stack_increment = 4;
} else {
stack_size = 0;
stack_increment = 0;
}
orc_compiler_append_code(compiler,".globl %s\n", compiler->program->name);
orc_compiler_append_code(compiler,"%s:\n", compiler->program->name);
/* push registers we need to save */
for(i=0; i<32; i++)
if (compiler->used_regs[ORC_GP_REG_BASE + i] &&
compiler->save_regs[ORC_GP_REG_BASE + i])
stack_size += 4;
if (stack_size) {
orc_mips_emit_addiu (compiler, ORC_MIPS_SP, ORC_MIPS_SP, -stack_size);
if (compiler->use_frame_pointer) {
orc_mips_emit_sw (compiler, ORC_MIPS_FP, ORC_MIPS_SP, stack_increment);
stack_increment += 4;
orc_mips_emit_move (compiler, ORC_MIPS_FP, ORC_MIPS_SP);
orc_mips_emit_sw (compiler, ORC_MIPS_A0, ORC_MIPS_SP, stack_increment);
stack_increment += 4;
}
for(i=0; i<32; i++){
if (compiler->used_regs[ORC_GP_REG_BASE + i] &&
compiler->save_regs[ORC_GP_REG_BASE + i]) {
orc_mips_emit_sw (compiler, ORC_GP_REG_BASE+i,
ORC_MIPS_SP, stack_increment);
stack_increment +=4;
}
}
}
return stack_size;
}
void orc_mips_emit_epilogue (OrcCompiler *compiler, int stack_size)
{
int i;
/* pop saved registers */
if (stack_size) {
unsigned int stack_increment = 0;
if (compiler->use_frame_pointer)
stack_increment = 8;
for(i=0; i<32; i++){
if (compiler->used_regs[ORC_GP_REG_BASE + i] &&
compiler->save_regs[ORC_GP_REG_BASE + i]) {
orc_mips_emit_lw (compiler, ORC_GP_REG_BASE+i,
ORC_MIPS_SP, stack_increment);
stack_increment +=4;
}
}
if (compiler->use_frame_pointer)
orc_mips_emit_lw (compiler, ORC_MIPS_FP, ORC_MIPS_SP, 4);
orc_mips_emit_addiu (compiler, ORC_MIPS_SP, ORC_MIPS_SP, stack_size);
}
orc_mips_emit_jr (compiler, ORC_MIPS_RA);
orc_mips_emit_nop (compiler);
if (compiler->target_flags & ORC_TARGET_CLEAN_COMPILE) {
/* we emit some padding nops at the end to align to 16 bytes because that's
* what gnu as does (not sure why) and we want to generate the same code
* for testing purposes */
orc_mips_emit_align (compiler, 4);
}
}
void
orc_mips_load_constants_inner (OrcCompiler *compiler)
{
int i;
for(i=0;ivars + i;
if (var->name == NULL) continue;
switch (var->vartype) {
case ORC_VAR_TYPE_CONST:
case ORC_VAR_TYPE_PARAM:
break;
case ORC_VAR_TYPE_SRC:
case ORC_VAR_TYPE_DEST:
orc_mips_emit_lw (compiler,
var->ptr_register,
compiler->exec_reg, ORC_MIPS_EXECUTOR_OFFSET_ARRAYS(i));
break;
default:
break;
}
if (var->ptr_offset)
orc_mips_emit_move (compiler, var->ptr_offset, ORC_MIPS_ZERO);
}
for(i=0;in_insns;i++){
OrcInstruction *insn = compiler->insns + i;
OrcStaticOpcode *opcode = insn->opcode;
OrcRule *rule;
if (!(insn->flags & ORC_INSN_FLAG_INVARIANT)) continue;
ORC_ASM_CODE(compiler,"# %d: %s\n", i, insn->opcode->name);
compiler->insn_shift = compiler->loop_shift;
if (insn->flags & ORC_INSTRUCTION_FLAG_X2) {
compiler->insn_shift += 1;
}
if (insn->flags & ORC_INSTRUCTION_FLAG_X4) {
compiler->insn_shift += 2;
}
rule = insn->rule;
if (rule && rule->emit) {
rule->emit (compiler, rule->emit_user, insn);
} else {
ORC_COMPILER_ERROR(compiler,"No rule for: %s", opcode->name);
}
}
}
#define CACHE_LINE_SIZE 32
void
orc_mips_emit_var_pref (OrcCompiler *compiler, int iter_offset, int total_shift)
{
int i, j;
int offset = 0;
/* prefetch stuff into cache */
for (i=0; ivars + i;
if (var->name == NULL) continue;
if (var->update_type == 0) {
offset = 0;
} else if (var->update_type == 1) {
offset = (var->size << total_shift) >> 1;
} else {
offset = var->size << total_shift;
}
if (var->vartype == ORC_VAR_TYPE_SRC) {
for (j = iter_offset*offset; j < (iter_offset+1)*offset; j+=CACHE_LINE_SIZE)
orc_mips_emit_pref (compiler, 4 /* load-streamed */,
var->ptr_register, j);
} else if (var->vartype == ORC_VAR_TYPE_DEST) {
for (j = iter_offset*offset; j < (iter_offset+1)*offset; j+=CACHE_LINE_SIZE)
orc_mips_emit_pref (compiler, 5 /* store-streamed */,
var->ptr_register, j);
}
}
}
static int
uses_register (OrcCompiler *compiler,
OrcInstruction *insn,
OrcMipsRegister reg)
{
int i;
for (i=0; ivars + insn->dest_args[i];
if (var->alloc == reg || var->ptr_register == reg)
return TRUE;
}
for (i=0; ivars + insn->src_args[i];
if (var->alloc == reg || var->ptr_register == reg)
return TRUE;
}
return FALSE;
}
static void
do_swap (int *tab, int i, int j)
{
int tmp = tab[i];
tab[i] = tab[j];
tab[j] = tmp;
}
/* Assumes that the instruction at indexes[i] is a load instruction */
static int
can_raise (OrcCompiler *compiler, int *indexes, int i)
{
OrcMipsRegister reg;
OrcInstruction *insn, *previous_insn;
if (i==0)
return FALSE;
insn = compiler->insns + indexes[i];
previous_insn = compiler->insns + indexes[i-1];
/* Register where the load operation will put the data */
reg = compiler->vars[insn->dest_args[0]].alloc;
return ! uses_register (compiler, previous_insn, reg);
}
/* Recursive. */
static void
try_raise (OrcCompiler *compiler, int *indexes, int i)
{
if (can_raise (compiler, indexes, i)) {
do_swap (indexes, i-1, i);
try_raise (compiler, indexes, i-1);
}
}
/*
Do a kind of bubble sort, though it might not exactly be a sort. It only
moves load instructions up until they reach an operation above which they
cannot go.
FIXME: also push store instructions down.
*/
static void
optimise_order (OrcCompiler *compiler, int *indexes)
{
int i;
for (i=0; in_insns; i++) {
OrcInstruction *insn = compiler->insns + indexes[i];
if (insn->opcode->flags & ORC_STATIC_OPCODE_LOAD)
try_raise (compiler, indexes, i);
}
}
static int *
get_optimised_instruction_order (OrcCompiler *compiler)
{
int *instruction_idx = NULL;
int i;
if (compiler->n_insns == 0)
return NULL;
instruction_idx = malloc (compiler->n_insns * sizeof(int));
for (i=0; in_insns; i++)
instruction_idx[i] = i;
optimise_order (compiler, instruction_idx);
return instruction_idx;
}
void
orc_mips_emit_loop (OrcCompiler *compiler, int unroll)
{
int i, j;
int iteration_per_loop = 1;
OrcInstruction *insn;
OrcStaticOpcode *opcode;
OrcRule *rule;
int total_shift = compiler->loop_shift;
int *insn_idx;
ORC_DEBUG ("loop_shift=%d", compiler->loop_shift);
if (unroll)
total_shift += compiler->unroll_shift;
if (unroll)
iteration_per_loop = 1 << compiler->unroll_shift;
insn_idx = get_optimised_instruction_order (compiler);
if (insn_idx == NULL) {
ORC_ERROR ("Could not get optimised instruction order, not emitting loop");
return;
}
for (j=0; junroll_index = j;
for (i=0; in_insns; i++) {
insn = compiler->insns + insn_idx[i];
opcode = insn->opcode;
if (insn->flags & ORC_INSN_FLAG_INVARIANT) continue;
orc_compiler_append_code(compiler,"/* %d: %s */\n", i, insn->opcode->name);
compiler->min_temp_reg = ORC_MIPS_T3;
rule = insn->rule;
if (rule && rule->emit) {
compiler->insn_shift = compiler->loop_shift;
if (insn->flags & ORC_INSTRUCTION_FLAG_X2) {
compiler->insn_shift += 1;
}
if (insn->flags & ORC_INSTRUCTION_FLAG_X4) {
compiler->insn_shift += 2;
}
rule->emit (compiler, rule->emit_user, insn);
} else {
orc_compiler_append_code (compiler, "No rule for %s\n", opcode->name);
}
}
}
compiler->unroll_index = 0;
for (j=0; jvars + j;
if (var->name == NULL) continue;
if (var->vartype == ORC_VAR_TYPE_SRC ||
var->vartype == ORC_VAR_TYPE_DEST) {
int offset;
if (var->update_type == 0) {
offset = 0;
} else if (var->update_type == 1) {
offset = (var->size << total_shift) >> 1;
} else {
offset = var->size << total_shift;
}
if (offset !=0 && var->ptr_register) {
orc_mips_emit_addiu (compiler,
var->ptr_register,
var->ptr_register,
offset);
}
}
}
}
static int
get_align_var (OrcCompiler *compiler)
{
if (compiler->vars[ORC_VAR_D1].size) return ORC_VAR_D1;
if (compiler->vars[ORC_VAR_S1].size) return ORC_VAR_S1;
ORC_PROGRAM_ERROR(compiler, "could not find alignment variable");
return -1;
}
static int
get_shift (int size)
{
switch (size) {
case 1:
return 0;
case 2:
return 1;
case 4:
return 2;
default:
ORC_ERROR("bad size %d", size);
}
return -1;
}
/* alignment is a bit field. Each bit (from least significant) corresponds to a
* dest or source variable in the order
* ORC_VAR_D1-ORC_VAR_D4,ORC_VAR_S1-ORC_VAR_S8
*/
void
orc_mips_set_alignment (OrcCompiler *compiler, orc_uint16 alignment)
{
int i;
for (i=ORC_VAR_D1; i<=ORC_VAR_S8; i++) {
compiler->vars[i].is_aligned = !!(alignment & (1<vars[i].is_aligned)
alignment |= 1<loop_shift;
compiler->loop_shift = loop_shift;
saved_alignment = orc_mips_get_alignment (compiler);
orc_mips_set_alignment (compiler, alignment);
orc_mips_emit_loop (compiler, unroll);
orc_mips_set_alignment (compiler, saved_alignment);
compiler->loop_shift = saved_loop_shift;
orc_mips_emit_addi (compiler, counter, counter, -1);
orc_mips_emit_bnez (compiler, counter, loop_label);
orc_mips_emit_nop (compiler);
}
/* FIXME: this stuff should be cached */
int
orc_mips_get_loop_label (OrcCompiler *compiler, int alignments)
{
int i,
j=0,
bitfield=0;
for (i=ORC_VAR_D1; i<=ORC_VAR_S8; i++) {
OrcVariable *var = &(compiler->vars[i]);
if (var->name == NULL || var->ptr_register == 0 || var->is_aligned) {
if (alignments & (1 << i))
return -1;
else
continue;
}
if (alignments & (1 << i)) {
bitfield |= 1 << j;
}
j++;
}
if (bitfield)
return LAST_LABEL + bitfield;
return -1;
}
/* overwrites $t0 and $t1 */
void
orc_mips_add_strides (OrcCompiler *compiler, int var_size_shift)
{
int i;
orc_mips_emit_lw (compiler, ORC_MIPS_T1, compiler->exec_reg,
ORC_MIPS_EXECUTOR_OFFSET_N);
orc_mips_emit_sll (compiler, ORC_MIPS_T1, ORC_MIPS_T1, var_size_shift);
/* $t1 now contains the number of bytes that we treated (and that the var
* pointer registers advanced) */
for(i=0;ivars[i].name == NULL) continue;
switch (compiler->vars[i].vartype) {
case ORC_VAR_TYPE_CONST:
break;
case ORC_VAR_TYPE_PARAM:
break;
case ORC_VAR_TYPE_SRC:
case ORC_VAR_TYPE_DEST:
/* get the stride (it's in bytes) */
orc_mips_emit_lw (compiler, ORC_MIPS_T0, compiler->exec_reg,
ORC_MIPS_EXECUTOR_OFFSET_PARAMS(i));
/* $t0 = stride - bytes advanced
we add that to the pointer so that it points to the beginning of the
next stride */
orc_mips_emit_sub (compiler, ORC_MIPS_T0, ORC_MIPS_T0, ORC_MIPS_T1);
orc_mips_emit_addu (compiler, compiler->vars[i].ptr_register,
compiler->vars[i].ptr_register, ORC_MIPS_T0);
break;
case ORC_VAR_TYPE_ACCUMULATOR:
break;
case ORC_VAR_TYPE_TEMP:
break;
default:
ORC_COMPILER_ERROR(compiler,"bad vartype");
break;
}
}
}
void
orc_compiler_orc_mips_assemble (OrcCompiler *compiler)
{
int stack_size;
int align_shift = 2; /* this wouldn't work on mips64 */
int align_var = get_align_var (compiler);
int var_size_shift;
int i;
var_size_shift = get_shift (compiler->vars[align_var].size);
stack_size = orc_mips_emit_prologue (compiler);
/* FIXME: load constants and params */
#if 0
for (i=0; ivars[i].name == NULL)
ORC_PROGRAM_ERROR (compiler, "unimplemented");
}
#endif
orc_mips_load_constants_inner (compiler);
if (compiler->program->is_2d) {
/* ex->params[ORC_VAR_A1] contains "m", the number of lines we want to treat */
orc_mips_emit_lw (compiler, ORC_MIPS_T0, compiler->exec_reg,
ORC_MIPS_EXECUTOR_OFFSET_PARAMS(ORC_VAR_A1));
orc_mips_emit_beqz (compiler, ORC_MIPS_T0, LABEL_END);
orc_mips_emit_label (compiler, LABEL_OUTER_LOOP);
}
orc_mips_emit_lw (compiler, ORC_MIPS_T2, compiler->exec_reg,
ORC_MIPS_EXECUTOR_OFFSET_N);
orc_mips_emit_blez (compiler, ORC_MIPS_T2, LABEL_END);
/* Note: in all these counter calculations ($t0, $t1 and $t2), we assume that
* variables of k bytes are k-bytes aligned. */
/* $t0 = number of iterations in region0 (before alignment) */
/* = number of bytes to get to alignment / var_size
= ((alignment - data_address) % alignment) / var_size
= (((1 << align_shift) - data_address) % (1 << align_shift)) / var_size
= (((1 << align_shift) - data_address) & ((1 << align_shfit) - 1)) >> var_size_shift
*/
orc_mips_emit_addiu (compiler, ORC_MIPS_T0, ORC_MIPS_ZERO, 1 << align_shift);
orc_mips_emit_sub (compiler, ORC_MIPS_T0, ORC_MIPS_T0,
compiler->vars[align_var].ptr_register);
orc_mips_emit_andi (compiler, ORC_MIPS_T0, ORC_MIPS_T0,
(1 << align_shift) - 1);
if (var_size_shift > 0)
orc_mips_emit_srl (compiler, ORC_MIPS_T0, ORC_MIPS_T0, var_size_shift);
/* $t1 = number of iterations in region1 (aligned)
= (n - $t0) / (loop_size * unroll)
= (n - $t0) >> (loop_shift + unroll_shift)
*/
orc_mips_emit_sub (compiler, ORC_MIPS_T2, ORC_MIPS_T2, ORC_MIPS_T0);
/*
handle the case where n < $t0. In that case, we want to handle n elements
in region0, and no element in the two other regions.
bgez $t2, usual_case
move $t1, $0
move $t2, $0
lw $t0, OFFSET_N($a0)
beqz $0, LABEL_REGION0_LOOP
usual_case:
*/
orc_mips_emit_conditional_branch_with_offset (compiler, ORC_MIPS_BGEZ,
ORC_MIPS_T2, ORC_MIPS_ZERO,
24);
orc_mips_emit_nop (compiler);
orc_mips_emit_move (compiler, ORC_MIPS_T1, ORC_MIPS_ZERO);
orc_mips_emit_move (compiler, ORC_MIPS_T2, ORC_MIPS_ZERO);
orc_mips_emit_lw (compiler, ORC_MIPS_T0, compiler->exec_reg,
ORC_MIPS_EXECUTOR_OFFSET_N);
orc_mips_emit_beqz (compiler, ORC_MIPS_ZERO, LABEL_REGION0_LOOP);
orc_mips_emit_nop (compiler);
if (compiler->loop_shift + compiler->unroll_shift > 0)
orc_mips_emit_srl (compiler, ORC_MIPS_T1, ORC_MIPS_T2,
compiler->loop_shift + compiler->unroll_shift);
else
orc_mips_emit_move (compiler, ORC_MIPS_T1, ORC_MIPS_T2);
/* if ($t0 == 0) goto REGION1 */
orc_mips_emit_beqz (compiler, ORC_MIPS_T0, LABEL_REGION1);
/* $t2 = number of iterations in region2 (after aligned region)
= (n - $t0) % loop_size
= (previous $t2) % loop_size
= $t2 & ((1 << loop_shift + unroll_shift) - 1)
*/
/* note that this instruction is in the branch delay slot */
if (compiler->loop_shift + compiler->unroll_shift > 0)
orc_mips_emit_andi (compiler, ORC_MIPS_T2, ORC_MIPS_T2,
(1 << (compiler->loop_shift + compiler->unroll_shift)) - 1);
else
/* loop_shift==0: $t2 should be 0 because we can handle all our data in region 1*/
orc_mips_emit_move (compiler, ORC_MIPS_T2, ORC_MIPS_ZERO);
/* FIXME: when loop_shift == 0, we only need to emit region1 */
orc_mips_emit_full_loop (compiler, ORC_MIPS_T0, 0, LABEL_REGION0_LOOP, 0, FALSE);
orc_mips_emit_label (compiler, LABEL_REGION1);
orc_mips_emit_beqz (compiler, ORC_MIPS_T1, LABEL_REGION2);
/* branch delay slot is occupied either by the next andi in the loop below or
* by the nop after that loop */
/* from here on until LABEL_REGION2, align_var is known to be aligned (that's
* the reason why we went through region 0) */
compiler->vars[align_var].is_aligned = TRUE;
/* We need a register that contains 1 so that we easily get 2^i */
orc_mips_emit_ori (compiler, ORC_MIPS_T3, ORC_MIPS_ZERO, 1);
/* That's where we will store the bitfield of aligned vars (apart from
* align_var) */
orc_mips_emit_ori (compiler, ORC_MIPS_T5, ORC_MIPS_ZERO, 0);
for (i=ORC_VAR_D1; i<=ORC_VAR_S8; i++) {
OrcVariable *var = &(compiler->vars[i]);
if (var->name == NULL || var->ptr_register == 0 || var->is_aligned) continue;
orc_mips_emit_andi (compiler, ORC_MIPS_T0, var->ptr_register, (1 << align_shift) - 1);
orc_mips_emit_conditional_branch_with_offset (compiler, ORC_MIPS_BNE,
ORC_MIPS_T0, ORC_MIPS_ZERO,
8 /* skipping the next two instructions */);
orc_mips_emit_sll (compiler, ORC_MIPS_T4, ORC_MIPS_T3, i);
orc_mips_emit_or (compiler, ORC_MIPS_T5, ORC_MIPS_T5, ORC_MIPS_T4);
}
orc_mips_emit_beqz (compiler, ORC_MIPS_T5, LABEL_REGION1_LOOP);
/* Loop on all the alignment combinations we can handle and compare them to
* the actual alignment we have, then branch to the best loop for it*/
/* Note: this assumes that ORC_VAR_D1 == 0 */
for (i=1; i < (1 << (ORC_VAR_S8 +1)); i++) {
int label = orc_mips_get_loop_label (compiler, i);
if (label == -1) continue;
if (label >= ORC_N_LABELS) { /* this check works because _get_loop_label() */
break; /* is strictly monotonic and increasing */
}
/* This next line works to load i because ORC_VAR_S8 < 16 */
orc_mips_emit_ori (compiler, ORC_MIPS_T0, ORC_MIPS_ZERO, i);
orc_mips_emit_beq (compiler, ORC_MIPS_T5, ORC_MIPS_T0, label);
}
orc_mips_emit_nop (compiler);
/* If we reach here, it means we haven't branched to any specific loop, so we
* branch to the fallback one */
orc_mips_emit_beqz (compiler, ORC_MIPS_ZERO, LABEL_REGION1_LOOP);
orc_mips_emit_nop (compiler);
/* Loop on all alignment combinations we can handle (limited by number of
* labels available) and emit the loop for it */
for (i=0; i < (1 << (ORC_VAR_S8 +1)); i++) {
int label = orc_mips_get_loop_label (compiler, i);
if (label == -1) continue;
if (label >= ORC_N_LABELS) /* this check works because _get_loop_label() */
break; /* is strictly monotonic and increasing */
orc_mips_emit_full_loop (compiler, ORC_MIPS_T1, compiler->loop_shift,
label, i | (1 << align_var), TRUE);
/* Jump the other loop versions and go to REGION2 */
orc_mips_emit_beqz (compiler, ORC_MIPS_ZERO, LABEL_REGION2);
orc_mips_emit_nop (compiler);
}
/* Fallback loop that works for any alignment combination */
orc_mips_emit_full_loop (compiler, ORC_MIPS_T1, compiler->loop_shift,
LABEL_REGION1_LOOP, 1 << align_var, TRUE);
compiler->vars[align_var].is_aligned = FALSE;
orc_mips_emit_label (compiler, LABEL_REGION2);
orc_mips_emit_beqz (compiler, ORC_MIPS_T2, LABEL_REGION2_LOOP_END);
orc_mips_emit_nop (compiler);
orc_mips_emit_full_loop (compiler, ORC_MIPS_T2, 0, LABEL_REGION2_LOOP, 0, FALSE);
orc_mips_emit_label (compiler, LABEL_REGION2_LOOP_END);
if (compiler->program->is_2d) {
/* ex->params[ORC_VAR_A1] contains "m", the number of lines we want to treat */
orc_mips_emit_lw (compiler, ORC_MIPS_T2, compiler->exec_reg,
ORC_MIPS_EXECUTOR_OFFSET_PARAMS(ORC_VAR_A1));
orc_mips_add_strides (compiler, var_size_shift);
orc_mips_emit_addi (compiler, ORC_MIPS_T2, ORC_MIPS_T2, -1);
orc_mips_emit_sw (compiler, ORC_MIPS_T2, compiler->exec_reg,
ORC_MIPS_EXECUTOR_OFFSET_PARAMS(ORC_VAR_A1));
orc_mips_emit_bnez (compiler, ORC_MIPS_T2, LABEL_OUTER_LOOP);
orc_mips_emit_nop (compiler);
}
orc_mips_emit_label (compiler, LABEL_END);
orc_mips_do_fixups (compiler);
orc_mips_emit_epilogue (compiler, stack_size);
}
void
orc_mips_flush_cache (OrcCode *code)
{
#ifdef HAVE_MIPSEL
__clear_cache (code->code, code->code + code->code_size);
#endif
}
orc-0.4.18/orc/orcutils.h 0000664 0001750 0001750 00000014762 12111024531 012112 0000000 0000000 /*
* ORC - Library of Optimized Inner Loops
* Copyright (c) 2007 David A. Schleef
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _ORC_UTILS_H_
#define _ORC_UTILS_H_
/* Orc objects */
//typedef struct _OrcVariable OrcVariable;
//typedef struct _OrcOpcodeSet OrcOpcodeSet;
//typedef struct _OrcStaticOpcode OrcStaticOpcode;
typedef struct _OrcInstruction OrcInstruction;
typedef struct _OrcProgram OrcProgram;
typedef struct _OrcCompiler OrcCompiler;
typedef struct _OrcConstant OrcConstant;
//typedef struct _OrcFixup OrcFixup;
typedef struct _OrcTarget OrcTarget;
typedef struct _OrcCode OrcCode;
//typedef struct _OrcCodeChunk OrcCodeChunk;
typedef enum {
ORC_COMPILE_RESULT_OK = 0,
ORC_COMPILE_RESULT_UNKNOWN_COMPILE = 0x100,
ORC_COMPILE_RESULT_MISSING_RULE = 0x101,
ORC_COMPILE_RESULT_UNKNOWN_PARSE = 0x200,
ORC_COMPILE_RESULT_PARSE = 0x201,
ORC_COMPILE_RESULT_VARIABLE = 0x202
} OrcCompileResult;
#ifndef _ORC_INTEGER_TYPEDEFS_
#define _ORC_INTEGER_TYPEDEFS_
#if defined(__STDC__) && __STDC__ && __STDC_VERSION__ >= 199901L
#include
typedef int8_t orc_int8;
typedef int16_t orc_int16;
typedef int32_t orc_int32;
typedef int64_t orc_int64;
typedef uint8_t orc_uint8;
typedef uint16_t orc_uint16;
typedef uint32_t orc_uint32;
typedef uint64_t orc_uint64;
typedef intptr_t orc_intptr;
#define ORC_UINT64_C(x) UINT64_C(x)
#elif defined(_MSC_VER)
typedef signed __int8 orc_int8;
typedef signed __int16 orc_int16;
typedef signed __int32 orc_int32;
typedef signed __int64 orc_int64;
typedef unsigned __int8 orc_uint8;
typedef unsigned __int16 orc_uint16;
typedef unsigned __int32 orc_uint32;
typedef unsigned __int64 orc_uint64;
#ifdef _WIN64
typedef unsigned __int64 orc_intptr;
#else
typedef unsigned long orc_intptr;
#endif
#define ORC_UINT64_C(x) (x##Ui64)
#else
#include
typedef signed char orc_int8;
typedef short orc_int16;
typedef int orc_int32;
typedef unsigned char orc_uint8;
typedef unsigned short orc_uint16;
typedef unsigned int orc_uint32;
#if INT_MAX == LONG_MAX
typedef long long orc_int64;
typedef unsigned long long orc_uint64;
#define ORC_UINT64_C(x) (x##ULL)
#else
typedef long orc_int64;
typedef unsigned long orc_uint64;
#define ORC_UINT64_C(x) (x##UL)
#endif
#ifdef _WIN64
typedef unsigned __int64 orc_intptr;
#else
typedef unsigned long orc_intptr;
#endif
#endif
typedef union { orc_int16 i; orc_int8 x2[2]; } orc_union16;
typedef union { orc_int32 i; float f; orc_int16 x2[2]; orc_int8 x4[4]; } orc_union32;
typedef union { orc_int64 i; double f; orc_int32 x2[2]; float x2f[2]; orc_int16 x4[4]; } orc_union64;
#endif
#ifndef TRUE
#define TRUE 1
#endif
#ifndef FALSE
#define FALSE 0
#endif
typedef unsigned int orc_bool;
#define ORC_PTR_TO_INT(x) ((int)(orc_intptr)(x))
#define ORC_PTR_OFFSET(ptr,offset) ((void *)(((unsigned char *)(ptr)) + (offset)))
#define ORC_STRUCT_OFFSET(struct_type, member) \
(ORC_PTR_TO_INT((unsigned char *) &((struct_type*) 0)->member))
#ifdef ORC_ENABLE_UNSTABLE_API
#define ARRAY_SIZE(x) (sizeof(x)/sizeof(x[0]))
#ifndef MIN
#define MIN(a,b) ((a)<(b) ? (a) : (b))
#endif
#ifndef MAX
#define MAX(a,b) ((a)>(b) ? (a) : (b))
#endif
#ifndef ORC_CLAMP
#define ORC_CLAMP(x,a,b) ((x)<(a) ? (a) : ((x)>(b) ? (b) : (x)))
#endif
#define ORC_READ_UINT32_LE(ptr) \
((orc_uint32)( \
((orc_uint8 *)(ptr))[0] | \
(((orc_uint8 *)(ptr))[1]<<8) | \
(((orc_uint8 *)(ptr))[2]<<16) | \
(((orc_uint8 *)(ptr))[3]<<24)))
#define ORC_WRITE_UINT32_LE(ptr,val) \
do { \
((orc_uint8 *)ptr)[0] = ((val)>>0)&0xff; \
((orc_uint8 *)ptr)[1] = ((val)>>8)&0xff; \
((orc_uint8 *)ptr)[2] = ((val)>>16)&0xff; \
((orc_uint8 *)ptr)[3] = ((val)>>24)&0xff; \
} while(0)
#endif
#if defined(__GNUC__) && defined(__GNUC_MINOR__)
#define ORC_GNUC_PREREQ(maj, min) \
((__GNUC__ << 16) + __GNUC_MINOR__ >= ((maj) << 16) + (min))
#else
#define ORC_GNUC_PREREQ(maj, min) 0
#endif
#ifndef ORC_INTERNAL
#if defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590)
#define ORC_INTERNAL __attribute__((visibility("hidden")))
#elif defined(__SUNPRO_C) && (__SUNPRO_C >= 0x550)
#define ORC_INTERNAL __hidden
#elif defined (__GNUC__) && ORC_GNUC_PREREQ(3,3) && defined(__ELF__)
#define ORC_INTERNAL __attribute__((visibility("hidden")))
#else
#define ORC_INTERNAL
#endif
#endif
#if ORC_GNUC_PREREQ(3,3) /* guess */
#define ORC_GNU_PRINTF(a,b) __attribute__((__format__ (__printf__, a, b)))
#else
#define ORC_GNU_PRINTF(a,b)
#endif
#if ORC_GNUC_PREREQ(2,4)
#define ORC_GNUC_UNUSED __attribute__((__unused__))
#else
#define ORC_GNUC_UNUSED
#endif
#ifdef __cplusplus
#define ORC_BEGIN_DECLS extern "C" {
#define ORC_END_DECLS }
#else
#define ORC_BEGIN_DECLS
#define ORC_END_DECLS
#endif
#ifdef _MSC_VER
#ifdef ORC_EXPORTS
#define ORC_EXPORT __declspec(dllexport) extern
#else
#define ORC_EXPORT __declspec(dllimport) extern
#endif
#else /* not _MSC_VER */
#define ORC_EXPORT extern
#endif
ORC_BEGIN_DECLS
#ifdef ORC_ENABLE_UNSTABLE_API
int get_file_int (const char *file, int *value);
char * get_file (const char *file);
char * get_cpuinfo_line (char *cpuinfo, const char *tag);
char * _strndup (const char *s, int n);
char ** strsplit (const char *s, char delimiter);
char * get_tag_value (char *s, const char *tag);
orc_int64 _strtoll (const char *nptr, char **endptr, int base);
void orc_global_mutex_lock (void);
void orc_global_mutex_unlock (void);
#endif
ORC_END_DECLS
#endif
orc-0.4.18/orc/orcarm.c 0000664 0001750 0001750 00000047507 12177015514 011544 0000000 0000000
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include
#include
#include
#include
#include
#include
#include
#include
#ifdef HAVE_ARM
#if defined(__APPLE__)
#include
#endif
#endif
/**
* SECTION:orcarm
* @title: ARM
* @short_description: code generation for ARM
*/
const char *
orc_arm_cond_name (OrcArmCond cond)
{
static const char *cond_names[] = {
"eq", "ne", "cs", "cc", "mi", "pl", "vs", "vc",
"hi", "ls", "ge", "lt", "gt", "le", "", ""
};
if (cond < 0 || cond >= 16) {
return "ERROR";
}
return cond_names[cond&0xf];
}
const char *
orc_arm_reg_name (int reg)
{
#if 0
static const char *gp_regs[] = {
"a1", "a2", "a3", "a4",
"v1", "v2", "v3", "v4",
"v5", "v6", "v7", "v8",
"ip", "sp", "lr", "pc" };
#else
static const char *gp_regs[] = {
"r0", "r1", "r2", "r3",
"r4", "r5", "r6", "r7",
"r8", "r9", "r10", "r11",
"ip", "sp", "lr", "pc" };
//"r12", "r13", "r14", "r15" };
#endif
if (reg < ORC_GP_REG_BASE || reg >= ORC_GP_REG_BASE+16) {
return "ERROR";
}
return gp_regs[reg&0xf];
}
void
orc_arm_emit (OrcCompiler *compiler, orc_uint32 insn)
{
ORC_WRITE_UINT32_LE (compiler->codeptr, insn);
compiler->codeptr+=4;
}
void
orc_arm_emit_bx_lr (OrcCompiler *compiler)
{
ORC_ASM_CODE(compiler," bx lr\n");
orc_arm_emit (compiler, 0xe12fff1e);
}
void
orc_arm_emit_push (OrcCompiler *compiler, int regs)
{
int i;
int x = 0;
ORC_ASM_CODE(compiler," push {");
for(i=0;i<16;i++){
if (regs & (1<labels[label] = compiler->codeptr;
}
void
orc_arm_add_fixup (OrcCompiler *compiler, int label, int type)
{
ORC_ASSERT (compiler->n_fixups < ORC_N_FIXUPS);
compiler->fixups[compiler->n_fixups].ptr = compiler->codeptr;
compiler->fixups[compiler->n_fixups].label = label;
compiler->fixups[compiler->n_fixups].type = type;
compiler->n_fixups++;
}
void
orc_arm_do_fixups (OrcCompiler *compiler)
{
int i;
for(i=0;in_fixups;i++){
unsigned char *label = compiler->labels[compiler->fixups[i].label];
unsigned char *ptr = compiler->fixups[i].ptr;
orc_uint32 code;
int diff;
if (compiler->fixups[i].type == 0) {
code = ORC_READ_UINT32_LE (ptr);
diff = code;
diff = (diff << 8) >> 8;
diff += ((label - ptr) >> 2);
if (diff != (diff << 8)>>8) {
ORC_COMPILER_ERROR(compiler, "fixup out of range");
}
ORC_WRITE_UINT32_LE(ptr, (code&0xff000000) | (diff&0x00ffffff));
} else {
code = ORC_READ_UINT32_LE (ptr);
diff = code;
/* We store the offset in the code as signed, but the CPU considers
* it unsigned */
diff = (diff << 24) >> 24;
diff += ((label - ptr) >> 2);
if (diff != (diff & 0xff)) {
ORC_COMPILER_ERROR(compiler, "fixup out of range (%d > 255)", diff);
}
ORC_WRITE_UINT32_LE(ptr, (code&0xffffff00) | (diff&0x000000ff));
}
}
}
void
orc_arm_emit_align (OrcCompiler *compiler, int align_shift)
{
int diff;
diff = (compiler->code - compiler->codeptr)&((1<>= 2;
shift2++;
}
if (x > 0xff) {
ORC_PROGRAM_ERROR(compiler, "bad immediate value");
}
}
code = 0xe3a00000;
code |= (dest&0xf) << 12;
code |= (((16-shift2)&0xf) << 8);
code |= (x&0xff);
ORC_ASM_CODE(compiler," mov %s, #0x%08x\n", orc_arm_reg_name (dest), imm);
orc_arm_emit (compiler, code);
}
void
orc_arm_emit_add_imm (OrcCompiler *compiler, int dest, int src1, int imm)
{
orc_uint32 code;
int shift2;
unsigned int x;
if ((imm & 0xff) == imm) {
shift2 = 0;
x = imm;
} else {
shift2 = 0;
x = imm & 0xffffffff;
while ((x & 3) == 0) {
x >>= 2;
shift2++;
}
if (x > 0xff) {
ORC_PROGRAM_ERROR(compiler, "bad immediate value");
}
}
code = 0xe2800000;
code |= (src1&0xf) << 16;
code |= (dest&0xf) << 12;
code |= (((16-shift2)&0xf) << 8);
code |= (x&0xff);
ORC_ASM_CODE(compiler," add %s, %s, #0x%08x\n", orc_arm_reg_name (dest),
orc_arm_reg_name(src1), imm);
orc_arm_emit (compiler, code);
}
void
orc_arm_emit_and_imm (OrcCompiler *compiler, int dest, int src1, int value)
{
orc_uint32 code;
code = 0xe2000000;
code |= (src1&0xf) << 16;
code |= (dest&0xf) << 12;
code |= (value) << 0;
ORC_ASM_CODE(compiler," and %s, %s, #%d\n",
orc_arm_reg_name (dest),
orc_arm_reg_name (src1),
value);
orc_arm_emit (compiler, code);
}
void
orc_arm_emit_cmp (OrcCompiler *compiler, int src1, int src2)
{
orc_uint32 code;
code = 0xe1500000;
code |= (src1&0xf) << 16;
code |= (src2&0xf) << 0;
ORC_ASM_CODE(compiler," cmp %s, %s\n",
orc_arm_reg_name (src1),
orc_arm_reg_name (src2));
orc_arm_emit (compiler, code);
}
void
orc_arm_emit_asr_imm (OrcCompiler *compiler, int dest, int src1, int value)
{
orc_uint32 code;
if (value == 0) {
ORC_ERROR("bad immediate value");
}
code = 0xe1a00040;
code |= (src1&0xf) << 0;
code |= (dest&0xf) << 12;
code |= (value) << 7;
ORC_ASM_CODE(compiler," asr %s, %s, #%d\n",
orc_arm_reg_name (dest),
orc_arm_reg_name (src1),
value);
orc_arm_emit (compiler, code);
}
void
orc_arm_emit_lsl_imm (OrcCompiler *compiler, int dest, int src1, int value)
{
orc_uint32 code;
if (value == 0) {
ORC_ERROR("bad immediate value");
}
code = 0xe1a00000;
code |= (src1&0xf) << 0;
code |= (dest&0xf) << 12;
code |= (value) << 7;
ORC_ASM_CODE(compiler," lsl %s, %s, #%d\n",
orc_arm_reg_name (dest),
orc_arm_reg_name (src1),
value);
orc_arm_emit (compiler, code);
}
void
orc_arm_emit_load_reg (OrcCompiler *compiler, int dest, int src1, int offset)
{
orc_uint32 code;
code = 0xe5900000;
code |= (src1&0xf) << 16;
code |= (dest&0xf) << 12;
code |= offset&0xfff;
ORC_ASM_CODE(compiler," ldr %s, [%s, #%d]\n",
orc_arm_reg_name (dest),
orc_arm_reg_name (src1), offset);
orc_arm_emit (compiler, code);
}
void
orc_arm_emit_store_reg (OrcCompiler *compiler, int src1, int dest, int offset)
{
orc_uint32 code;
code = 0xe5800000;
code |= (dest&0xf) << 16;
code |= (src1&0xf) << 12;
code |= offset&0xfff;
ORC_ASM_CODE(compiler," str %s, [%s, #%d]\n",
orc_arm_reg_name (src1),
orc_arm_reg_name (dest), offset);
orc_arm_emit (compiler, code);
}
void
orc_arm_emit_mov (OrcCompiler *compiler, int dest, int src)
{
if (dest == src) return;
orc_arm_emit_mov_r(compiler, ORC_ARM_COND_AL, 0, dest, src);
}
void
orc_arm_emit_sub (OrcCompiler *compiler, int dest, int src1, int src2)
{
orc_arm_emit_sub_r (compiler, ORC_ARM_COND_AL, 0, dest, src1, src2);
}
void
orc_arm_emit_sub_imm (OrcCompiler *compiler, int dest, int src1, int value,
int record)
{
orc_arm_emit_sub_i (compiler, ORC_ARM_COND_AL, record, dest, src1, value);
}
void
orc_arm_emit_add (OrcCompiler *compiler, int dest, int src1, int src2)
{
orc_arm_emit_add_r (compiler, ORC_ARM_COND_AL, 0, dest, src1, src2);
}
void
orc_arm_emit_cmp_imm (OrcCompiler *compiler, int src1, int value)
{
orc_arm_emit_cmp_i (compiler, ORC_ARM_COND_AL, src1, value);
}
/* shifter operands */
/* 1
* 1 0 9 8 7 6 5 4 3 2 1 0
* +-+-+-+-+-+-+-+-+-+-+-+-+
* |rotimm | immed_8 |
* +-+-+-+-+-+-+-+-+-+-+-+-+
*/
#define arm_so_i(rot,imm) ((((rot)&15)<<8)|((imm)&255))
/* 1
* 1 0 9 8 7 6 5 4 3 2 1 0
* +-+-+-+-+-+-+-+-+-+-+-+-+
* | Si | St|0| Rm |
* +-+-+-+-+-+-+-+-+-+-+-+-+
*/
#define arm_so_rsi(Si,St,Rm) ((((Si)&31)<<7)|(((St)&3)<<5)|((Rm)&15))
#define arm_so_rrx(Rm) arm_so_rsi(0,ORC_ARM_ROR,Rm)
#define arm_so_r(Rm) ((Rm)&15)
/* 1
* 1 0 9 8 7 6 5 4 3 2 1 0
* +-+-+-+-+-+-+-+-+-+-+-+-+
* | Rs |0| St|1| Rm |
* +-+-+-+-+-+-+-+-+-+-+-+-+
*/
#define arm_so_rsr(Rs,St,Rm) (0x010|(((Rs)&15)<<8)|(((St)&3)<<5)|((Rm)&15))
/* data processing instructions */
/* 3 2 2 2 2 2 2 2 1 1 1 1 1
* 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
* | cond |0 0|I| opcode|S| Rn | Rd | shifter_operand |
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
*/
#define arm_code_dp(cond,I,opcode,S,Rn,Rd,So) ((((cond)&15)<<28) | (((I)&1)<<25) | \
(((opcode)&15)<<21) | (((S)&1)<<20) | \
(((Rn)&15)<<16) | (((Rd)&15)<<12) | \
((So)&0xfff))
/*
* type 0: {}{s} {}, , #imm (imm = (val>>(shift*2))|(val<<(32-(shift*2))))
* type 1: {}{s} {}, ,
* type 2: {}{s} {}, , , [LSL|LSR|ASR] #imm
* type 3: {}{s} {}, , , [LSL|LSR|ASR]
* type 4: {}{s} {,} , , RRX
*/
void
orc_arm_emit_dp (OrcCompiler *p, int type, OrcArmCond cond, OrcArmDP opcode,
int S, int Rd, int Rn, int Rm, int shift, orc_uint32 val)
{
orc_uint32 code;
int I = 0;
int shifter_op;
char shifter[64];
orc_uint32 imm;
static const char *shift_names[] = {
"LSL", "LSR", "ASR", "ROR"
};
/* opcodes with Rd */
static const int op_Rd[] = {
1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1
};
/* opcodes using Rn */
static const int op_Rn[] = {
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0
};
static const char *dp_insn_names[] = {
"and", "eor", "sub", "rsb", "add", "adc", "sbc", "rsc",
"tst", "teq", "cmp", "cmn", "orr", "mov", "bic", "mvn"
};
switch (type) {
case 0:
/* #imm */
imm = (orc_uint32) val;
/* if imm <= 0xff we're done. It's recommanded that we choose the
* smallest shifter value. Impossible values will overflow the shifter. */
while (imm > 0xff && shift < 16) {
imm = (imm << 2) | (imm >> 30);
shift++;
}
if (shift > 15) {
ORC_COMPILER_ERROR(p,"invalid ARM immediate %08x", val);
return;
}
shifter_op = arm_so_i (shift, imm);
sprintf (shifter, "#0x%08x", val);
I = 1;
break;
case 1:
/* */
shifter_op = arm_so_r (Rm);
sprintf (shifter, "%s", orc_arm_reg_name (Rm));
break;
case 2:
/* , [LSL|LSR|ASR] #imm */
shifter_op = arm_so_rsi (val,shift,Rm);
sprintf (shifter, "%s, %s #%d",
orc_arm_reg_name (Rm), shift_names[shift], val);
break;
case 3:
/* , [LSL|LSR|ASR] */
shifter_op = arm_so_rsr (val,shift,Rm);
sprintf (shifter, "%s, %s %s",
orc_arm_reg_name (Rm), shift_names[shift], orc_arm_reg_name (val));
break;
case 4:
/* , RRX */
shifter_op = arm_so_rrx (Rm);
sprintf (shifter, "%s, RRX",
orc_arm_reg_name (Rm));
break;
default:
ORC_COMPILER_ERROR(p,"unknown data processing type %d", type);
return;
}
if (op_Rd[opcode]) {
if (op_Rn[opcode]) {
/* opcode using Rn */
code = arm_code_dp (cond, I, opcode, S, Rn, Rd, shifter_op);
ORC_ASM_CODE(p," %s%s%s %s, %s, %s\n",
dp_insn_names[opcode], orc_arm_cond_name(cond), (S ? "s" : ""),
orc_arm_reg_name (Rd), orc_arm_reg_name (Rn), shifter);
} else {
/* opcode using Rd and val (mov, mvn) */
code = arm_code_dp (cond, I, opcode, S, Rn, Rd, shifter_op);
ORC_ASM_CODE(p," %s%s%s %s, %s\n",
dp_insn_names[opcode], orc_arm_cond_name(cond), (S ? "s" : ""),
orc_arm_reg_name (Rd), shifter);
}
} else {
/* opcode does not change Rd, change status register (cmp, tst, ..) */
code = arm_code_dp (cond, I, opcode, 1, Rn, 0, shifter_op);
ORC_ASM_CODE(p," %s%s %s, %s\n",
dp_insn_names[opcode], orc_arm_cond_name(cond), orc_arm_reg_name (Rn), shifter);
}
orc_arm_emit (p, code);
}
/* parallel instructions */
/* 3 2 2 2 2 2 2 2 1 1 1 1 1
* 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
* | cond | mode | Rn | Rd |0 0 0 0| op | Rm |
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
*/
#define arm_code_par(cond,mode,Rn,Rd,op,Rm) (((cond)<<28)|((mode)<<20)|(((Rn)&0xf)<<16)|(((Rd)&0xf)<<12)|((op)<<4)|((Rm)&0xf)|0xf00)
void
orc_arm_emit_par (OrcCompiler *p, int op, int mode, OrcArmCond cond,
int Rd, int Rn, int Rm)
{
orc_uint32 code;
static const int par_op[] = {
1, 3, 5, 7, 9, 15, 11, 5, 5
};
static const char *par_op_names[] = {
"add16", "addsubx", "subaddx", "sub16", "add8", "sub8", "sel", "add", "sub"
};
static const int par_mode[] = {
0x61, 0x62, 0x63, 0x65, 0x66, 0x67, 0x68, 0x10, 0x12, 0x14, 0x16
};
static const char *par_mode_names[] = {
"s", "q", "sh", "u", "uq", "uh", "", "q", "q", "qd", "qd"
};
code = arm_code_par (cond, par_mode[mode], Rn, Rd, par_op[op], Rm);
if (op == 7) {
int tmp;
/* gas does something screwy here */
code &= ~0xf00;
tmp = Rn;
Rn = Rm;
Rm = tmp;
}
ORC_ASM_CODE(p," %s%s%s %s, %s, %s\n",
par_mode_names[mode], par_op_names[op], orc_arm_cond_name(cond),
orc_arm_reg_name (Rd),
orc_arm_reg_name (Rn),
orc_arm_reg_name (Rm));
orc_arm_emit (p, code);
}
/* extend instructions */
/* 3 2 2 2 2 2 2 2 1 1 1 1 1 1
* 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
* | cond |0 1 1 0 0 0 0 0| Rn | Rd |rot|0 0|0 1 1 1| Rm |
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
*/
#define arm_code_xt(op,cond,Rn,Rd,r8,Rm) (op|((cond)<<28)|(((Rn)&0xf)<<16)|(((Rd)&0xf)<<12)|((((r8)&0xf)&0x18)<<7)|((Rm)&0xf))
void
orc_arm_emit_xt (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int Rn, int Rm, int r8)
{
orc_uint32 code;
char shifter[64];
static const orc_uint32 xt_opcodes[] = {
0x06800070, 0x06a00070, 0x06b00070, 0x06c00070, 0x06e00070, 0x06f00070
};
static const char *xt_insn_names[] = {
"sxtb16", "sxtb", "sxth", "uxtb16", "uxtb", "uxth",
"sxtab16", "sxtab", "sxtah", "uxtab16", "uxtab", "uxtah",
};
if (r8 & 0x18)
sprintf (shifter, ", ROR #%d", r8 & 0x18);
else
shifter[0] = '\0';
code = arm_code_xt (xt_opcodes[op], cond, Rn, Rd, r8, Rm);
if (Rn < 15) {
/* with Rn */
ORC_ASM_CODE(p," %s%s %s, %s, %s%s\n",
xt_insn_names[op], orc_arm_cond_name(cond),
orc_arm_reg_name (Rd),
orc_arm_reg_name (Rn),
orc_arm_reg_name (Rm),
shifter);
} else {
ORC_ASM_CODE(p," %s%s %s, %s%s\n",
xt_insn_names[op], orc_arm_cond_name(cond),
orc_arm_reg_name (Rd),
orc_arm_reg_name (Rm),
shifter);
}
orc_arm_emit (p, code);
}
#define arm_code_pkh(op,cond,Rn,Rd,sh,Rm) (op|((cond)<<28)|(((Rn)&0xf)<<16)|(((Rd)&0xf)<<12)|((sh)<<7)|((Rm)&0xf))
void
orc_arm_emit_pkh (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int Rn, int Rm, int sh)
{
orc_uint32 code;
char shifter[64];
static const orc_uint32 pkh_opcodes[] = { 0x06800010, 0x06800050 };
static const char *pkh_insn_names[] = { "pkhbt", "pkhtb" };
if (sh > 0) {
sprintf (shifter, ", %s #%d",
(op == 0 ? "LSL" : "ASR"), sh);
} else {
shifter[0] = '\0';
}
code = arm_code_pkh (pkh_opcodes[op], cond, Rn, Rd, sh, Rm);
ORC_ASM_CODE(p," %s%s %s, %s, %s%s\n",
pkh_insn_names[op], orc_arm_cond_name(cond),
orc_arm_reg_name (Rd),
orc_arm_reg_name (Rn),
orc_arm_reg_name (Rm),
shifter);
orc_arm_emit (p, code);
}
/* extend instructions */
/* 3 2 2 2 2 1 1 1 1 1 1
* 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0 9 8 7 6 5 4 3 2 1 0
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
* | cond |0 1 1 0|x x x| sat | Rd | sh |a|0 1| Rm |
* +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
*/
#define arm_code_sat(op,cond,sat,Rd,sh,a,Rm) (op|(((cond)&15)<<28)|(((sat)&31)<<16)|\
(((Rd)&15)<<12)|(((sh)&31)<<7)|(((a)&1)<<6)|\
((Rm)&15))
void
orc_arm_emit_sat (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int sat, int Rm, int sh, int asr)
{
orc_uint32 code;
char shifter[64];
static const orc_uint32 sat_opcodes[] = { 0x06a00010, 0x06e00010, 0, 0 };
static const char *sat_insn_names[] = { "ssat", "usat", "ssat16", "usat16" };
static const int par_mode[] = { 0, 0, 0x6a, 0x6e };
static const int par_op[] = { 0, 0, 3, 3 };
if (sh > 0) {
sprintf (shifter, ", %s #%d",
(asr&1 ? "ASR" : "LSL"), sh);
} else {
shifter[0] = '\0';
}
if (op < 2) {
code = arm_code_sat (sat_opcodes[op], cond, sat, Rd, sh, asr, Rm);
} else {
if (op == 3) {
code = arm_code_par (cond, par_mode[op], sat, Rd, par_op[op], Rm);
} else {
code = arm_code_par (cond, par_mode[op], sat - 1, Rd, par_op[op], Rm);
}
}
ORC_ASM_CODE(p," %s%s %s, #%d, %s%s\n",
sat_insn_names[op], orc_arm_cond_name(cond),
orc_arm_reg_name (Rd),
sat,
orc_arm_reg_name (Rm),
shifter);
orc_arm_emit (p, code);
}
#define arm_code_rv(op,cond,Rd,Rm) (op|(((cond)&15)<<28)|(((Rd)&15)<<12)|((Rm)&15))
void
orc_arm_emit_rv (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int Rm)
{
orc_uint32 code;
static const orc_uint32 rv_opcodes[] = { 0x06bf0f30, 0x06bf0fb0 };
static const char *rv_insn_names[] = { "rev", "rev16" };
code = arm_code_rv (rv_opcodes[op], cond, Rd, Rm);
ORC_ASM_CODE(p," %s%s %s, %s\n",
rv_insn_names[op], orc_arm_cond_name(cond),
orc_arm_reg_name (Rd), orc_arm_reg_name (Rm));
orc_arm_emit (p, code);
}
void
orc_arm_flush_cache (OrcCode *code)
{
#ifdef HAVE_ARM
#ifdef __APPLE__
sys_icache_invalidate(code->code, code->code_size);
#else
__clear_cache (code->code, code->code + code->code_size);
#endif
#endif
}
void
orc_arm_emit_data (OrcCompiler *compiler, orc_uint32 data)
{
if (compiler->target_flags & ORC_TARGET_CLEAN_COMPILE) {
orc_arm_emit_nop (compiler);
} else {
ORC_ASM_CODE(compiler," .word 0x%08x\n", data);
orc_arm_emit (compiler, data);
}
}
void
orc_arm_loadw (OrcCompiler *compiler, int dest, int src1, int offset)
{
orc_uint32 code;
code = 0xe1d000b0;
code |= (src1&0xf) << 16;
code |= (dest&0xf) << 12;
code |= (offset&0xf0) << 4;
code |= offset&0x0f;
ORC_ASM_CODE(compiler," ldrh %s, [%s, #%d]\n",
orc_arm_reg_name (dest),
orc_arm_reg_name (src1), offset);
orc_arm_emit (compiler, code);
}
orc-0.4.18/orc/orcvariable.h 0000664 0001750 0001750 00000002315 12117155734 012546 0000000 0000000
#ifndef _ORC_VARIABLE_H_
#define _ORC_VARIABLE_H_
#include
#include
#include
#include
#include
#include
#include
#include
ORC_BEGIN_DECLS
#define ORC_VAR_FLAG_VOLATILE_WORKAROUND (1<<0)
typedef struct _OrcVariable OrcVariable;
typedef enum {
ORC_VAR_TYPE_TEMP,
ORC_VAR_TYPE_SRC,
ORC_VAR_TYPE_DEST,
ORC_VAR_TYPE_CONST,
ORC_VAR_TYPE_PARAM,
ORC_VAR_TYPE_ACCUMULATOR
} OrcVarType;
enum {
ORC_PARAM_TYPE_INT = 0,
ORC_PARAM_TYPE_FLOAT,
ORC_PARAM_TYPE_INT64,
ORC_PARAM_TYPE_DOUBLE
};
/**
* OrcVariable:
*
* The OrcVariable structure has no public members
*/
struct _OrcVariable {
/*< private >*/
char *name;
char *type_name;
int size;
OrcVarType vartype;
int used;
int first_use;
int last_use;
int replaced;
int replacement;
int alloc;
int is_chained;
int is_aligned;
int alignment;
int is_uncached;
orc_union64 value;
int ptr_register;
int ptr_offset;
int mask_alloc;
int aligned_data;
int param_type;
int load_dest;
int update_type;
int need_offset_reg;
unsigned int flags;
};
ORC_END_DECLS
#endif
orc-0.4.18/orc/orc-stdint.h 0000644 0001750 0001750 00000000056 11563547254 012347 0000000 0000000 /* This file is intentionally nearly empty */
orc-0.4.18/orc/orcrule.h 0000664 0001750 0001750 00000001611 12111024531 011706 0000000 0000000
#ifndef _ORC_RULE_H_
#define _ORC_RULE_H_
#include
#include
#include
ORC_BEGIN_DECLS
typedef struct _OrcRule OrcRule;
typedef struct _OrcRuleSet OrcRuleSet;
typedef void (*OrcRuleEmitFunc)(OrcCompiler *p, void *user, OrcInstruction *insn);
/**
* OrcRule:
*
* The OrcRule structure has no public members
*/
struct _OrcRule {
/*< private >*/
OrcRuleEmitFunc emit;
void *emit_user;
};
/**
* OrcRuleSet:
*
* The OrcRuleSet structure has no public members
*/
struct _OrcRuleSet {
/*< private >*/
int opcode_major;
int required_target_flags;
OrcRule *rules;
int n_rules;
};
OrcRuleSet * orc_rule_set_new (OrcOpcodeSet *opcode_set, OrcTarget *target,
unsigned int required_flags);
void orc_rule_register (OrcRuleSet *rule_set, const char *opcode_name,
OrcRuleEmitFunc emit, void *emit_user);
ORC_END_DECLS
#endif
orc-0.4.18/orc/orcarm.h 0000644 0001750 0001750 00000050606 11563547254 011552 0000000 0000000
#ifndef _ORC_ARM_H_
#define _ORC_ARM_H_
#include
ORC_BEGIN_DECLS
#ifdef ORC_ENABLE_UNSTABLE_API
typedef enum {
ORC_ARM_A1 = ORC_GP_REG_BASE+0,
ORC_ARM_A2,
ORC_ARM_A3,
ORC_ARM_A4,
ORC_ARM_V1,
ORC_ARM_V2,
ORC_ARM_V3,
ORC_ARM_V4,
ORC_ARM_V5,
ORC_ARM_V6,
ORC_ARM_V7,
ORC_ARM_V8,
ORC_ARM_IP,
ORC_ARM_SP,
ORC_ARM_LR,
ORC_ARM_PC
} OrcArmRegister;
typedef enum {
ORC_ARM_DP_AND = 0,
ORC_ARM_DP_EOR,
ORC_ARM_DP_SUB,
ORC_ARM_DP_RSB,
ORC_ARM_DP_ADD,
ORC_ARM_DP_ADC,
ORC_ARM_DP_SBC,
ORC_ARM_DP_RSC,
ORC_ARM_DP_TST,
ORC_ARM_DP_TEQ,
ORC_ARM_DP_CMP,
ORC_ARM_DP_CMN,
ORC_ARM_DP_ORR,
ORC_ARM_DP_MOV,
ORC_ARM_DP_BIC,
ORC_ARM_DP_MVN
} OrcArmDP;
typedef enum {
ORC_ARM_COND_EQ = 0,
ORC_ARM_COND_NE,
ORC_ARM_COND_CS,
ORC_ARM_COND_CC,
ORC_ARM_COND_MI,
ORC_ARM_COND_PL,
ORC_ARM_COND_VS,
ORC_ARM_COND_VC,
ORC_ARM_COND_HI,
ORC_ARM_COND_LS,
ORC_ARM_COND_GE,
ORC_ARM_COND_LT,
ORC_ARM_COND_GT,
ORC_ARM_COND_LE,
ORC_ARM_COND_AL,
} OrcArmCond;
typedef enum {
ORC_ARM_LSL,
ORC_ARM_LSR,
ORC_ARM_ASR,
ORC_ARM_ROR
} OrcArmShift;
unsigned long orc_arm_get_cpu_flags (void);
void orc_arm_emit (OrcCompiler *compiler, orc_uint32 insn);
void orc_arm_emit_bx_lr (OrcCompiler *compiler);
const char * orc_arm_reg_name (int reg);
const char * orc_arm_cond_name (OrcArmCond cond);
void orc_arm_emit_load_imm (OrcCompiler *compiler, int dest, int imm);
void orc_arm_emit_add (OrcCompiler *compiler, int dest, int src1, int src2);
void orc_arm_emit_sub (OrcCompiler *compiler, int dest, int src1, int src2);
void orc_arm_emit_add_imm (OrcCompiler *compiler, int dest, int src1, int value);
void orc_arm_emit_and_imm (OrcCompiler *compiler, int dest, int src1, int value);
void orc_arm_emit_sub_imm (OrcCompiler *compiler, int dest, int src1, int value, int record);
void orc_arm_emit_asr_imm (OrcCompiler *compiler, int dest, int src1, int value);
void orc_arm_emit_lsl_imm (OrcCompiler *compiler, int dest, int src1, int value);
void orc_arm_emit_cmp_imm (OrcCompiler *compiler, int src1, int value);
void orc_arm_emit_cmp (OrcCompiler *compiler, int src1, int src2);
void orc_arm_emit_mov (OrcCompiler *compiler, int dest, int src);
void orc_arm_emit_align (OrcCompiler *compiler, int align_shift);
void orc_arm_emit_label (OrcCompiler *compiler, int label);
void orc_arm_emit_push (OrcCompiler *compiler, int regs);
void orc_arm_emit_pop (OrcCompiler *compiler, int regs);
void orc_arm_emit_branch (OrcCompiler *compiler, int cond, int label);
void orc_arm_emit_data (OrcCompiler *compiler, orc_uint32 data);
void orc_arm_loadb (OrcCompiler *compiler, int dest, int src1, int offset);
void orc_arm_storeb (OrcCompiler *compiler, int dest, int offset, int src1);
void orc_arm_loadw (OrcCompiler *compiler, int dest, int src1, int offset);
void orc_arm_storew (OrcCompiler *compiler, int dest, int offset, int src1);
void orc_arm_loadl (OrcCompiler *compiler, int dest, int src1, int offset);
void orc_arm_storel (OrcCompiler *compiler, int dest, int offset, int src1);
void orc_arm_emit_load_reg (OrcCompiler *compiler, int dest, int src1, int offset);
void orc_arm_emit_store_reg (OrcCompiler *compiler, int src, int dest, int offset);
void orc_arm_add_fixup (OrcCompiler *compiler, int label, int type);
void orc_arm_do_fixups (OrcCompiler *compiler);
void orc_arm_emit_dp (OrcCompiler *p, int type, OrcArmCond cond, OrcArmDP opcode,
int S, int Rd, int Rn, int Rm, int shift, orc_uint32 val);
void orc_arm_emit_par (OrcCompiler *p, int op, int mode, OrcArmCond cond,
int Rd, int Rn, int Rm);
void orc_arm_emit_xt (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int Rn, int Rm, int r8);
void orc_arm_emit_pkh (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int Rn, int Rm, int sh);
void orc_arm_emit_sat (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int sat, int Rm, int sh, int asr);
void orc_arm_emit_rv (OrcCompiler *p, int op, OrcArmCond cond,
int Rd, int Rm);
void orc_arm_emit_nop (OrcCompiler *compiler);
void orc_arm_flush_cache (OrcCode *code);
/* ALL cpus */
/* data procesing instructions */
/* {}{s} {}, , #imm */
#define orc_arm_emit_and_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_AND,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_eor_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_EOR,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_sub_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_SUB,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_rsb_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_RSB,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_add_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_ADD,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_adc_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_ADC,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_sbc_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_SBC,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_rsc_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_RSC,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_tst_i(p,cond,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_TST,1, 0,Rn,0,0,imm)
#define orc_arm_emit_teq_i(p,cond,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_TEQ,1, 0,Rn,0,0,imm)
#define orc_arm_emit_cmp_i(p,cond,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_CMP,1, 0,Rn,0,0,imm)
#define orc_arm_emit_cmn_i(p,cond,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_CMN,1, 0,Rn,0,0,imm)
#define orc_arm_emit_orr_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_ORR,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_mov_i(p,cond,S,Rd,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_MOV,S,Rd, 0,0,0,imm)
#define orc_arm_emit_bic_i(p,cond,S,Rd,Rn,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_BIC,S,Rd,Rn,0,0,imm)
#define orc_arm_emit_mvn_i(p,cond,S,Rd,imm) orc_arm_emit_dp(p,0,cond,ORC_ARM_DP_MVN,S,Rd, 0,0,0,imm)
/* {}{s} {}, , */
#define orc_arm_emit_and_r(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_AND,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_eor_r(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_EOR,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_sub_r(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_SUB,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_rsb_r(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_RSB,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_add_r(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_ADD,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_adc_r(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_ADC,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_sbc_r(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_SBC,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_rsc_r(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_RSC,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_tst_r(p,cond,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_TST,1, 0,Rn,Rm,0,0)
#define orc_arm_emit_teq_r(p,cond,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_TEQ,1, 0,Rn,Rm,0,0)
#define orc_arm_emit_cmp_r(p,cond,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_CMP,1, 0,Rn,Rm,0,0)
#define orc_arm_emit_cmn_r(p,cond,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_CMN,1, 0,Rn,Rm,0,0)
#define orc_arm_emit_orr_r(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_ORR,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_mov_r(p,cond,S,Rd,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_MOV,S,Rd, 0,Rm,0,0)
#define orc_arm_emit_bic_r(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_BIC,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_mvn_r(p,cond,S,Rd,Rm) orc_arm_emit_dp(p,1,cond,ORC_ARM_DP_MVN,S,Rd, 0,Rm,0,0)
/* {}{s} {}, , , [LSL|LSR|ASR] #imm */
#define orc_arm_emit_and_rsi(p,cond,S,Rd,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_AND,S,Rd,Rn,Rm,sh,im)
#define orc_arm_emit_eor_rsi(p,cond,S,Rd,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_EOR,S,Rd,Rn,Rm,sh,im)
#define orc_arm_emit_sub_rsi(p,cond,S,Rd,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_SUB,S,Rd,Rn,Rm,sh,im)
#define orc_arm_emit_rsb_rsi(p,cond,S,Rd,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_RSB,S,Rd,Rn,Rm,sh,im)
#define orc_arm_emit_add_rsi(p,cond,S,Rd,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_ADD,S,Rd,Rn,Rm,sh,im)
#define orc_arm_emit_adc_rsi(p,cond,S,Rd,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_ADC,S,Rd,Rn,Rm,sh,im)
#define orc_arm_emit_sbc_rsi(p,cond,S,Rd,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_SBC,S,Rd,Rn,Rm,sh,im)
#define orc_arm_emit_rsc_rsi(p,cond,S,Rd,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_RSC,S,Rd,Rn,Rm,sh,im)
#define orc_arm_emit_tst_rsi(p,cond,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_TST,1, 0,Rn,Rm,sh,im)
#define orc_arm_emit_teq_rsi(p,cond,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_TEQ,1, 0,Rn,Rm,sh,im)
#define orc_arm_emit_cmp_rsi(p,cond,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_CMP,1, 0,Rn,Rm,sh,im)
#define orc_arm_emit_cmn_rsi(p,cond,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_CMN,1, 0,Rn,Rm,sh,im)
#define orc_arm_emit_orr_rsi(p,cond,S,Rd,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_ORR,S,Rd,Rn,Rm,sh,im)
#define orc_arm_emit_mov_rsi(p,cond,S,Rd,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_MOV,S,Rd, 0,Rm,sh,im)
#define orc_arm_emit_bic_rsi(p,cond,S,Rd,Rn,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_BIC,S,Rd,Rn,Rm,sh,im)
#define orc_arm_emit_mvn_rsi(p,cond,S,Rd,Rm,sh,im) orc_arm_emit_dp(p,2,cond,ORC_ARM_DP_MVN,S,Rd, 0,Rm,sh,im)
/* {}{s} {}, , , [LSL|LSR|ASR] */
#define orc_arm_emit_and_rsr(p,cond,S,Rd,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_AND,S,Rd,Rn,Rm,sh,Rs)
#define orc_arm_emit_eor_rsr(p,cond,S,Rd,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_EOR,S,Rd,Rn,Rm,sh,Rs)
#define orc_arm_emit_sub_rsr(p,cond,S,Rd,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_SUB,S,Rd,Rn,Rm,sh,Rs)
#define orc_arm_emit_rsb_rsr(p,cond,S,Rd,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_RSB,S,Rd,Rn,Rm,sh,Rs)
#define orc_arm_emit_add_rsr(p,cond,S,Rd,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_ADD,S,Rd,Rn,Rm,sh,Rs)
#define orc_arm_emit_adc_rsr(p,cond,S,Rd,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_ADC,S,Rd,Rn,Rm,sh,Rs)
#define orc_arm_emit_sbc_rsr(p,cond,S,Rd,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_SBC,S,Rd,Rn,Rm,sh,Rs)
#define orc_arm_emit_rsc_rsr(p,cond,S,Rd,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_RSC,S,Rd,Rn,Rm,sh,Rs)
#define orc_arm_emit_tst_rsr(p,cond,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_TST,1, 0,Rn,Rm,sh,Rs)
#define orc_arm_emit_teq_rsr(p,cond,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_TEQ,1, 0,Rn,Rm,sh,Rs)
#define orc_arm_emit_cmp_rsr(p,cond,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_CMP,1, 0,Rn,Rm,sh,Rs)
#define orc_arm_emit_cmn_rsr(p,cond,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_CMN,1, 0,Rn,Rm,sh,Rs)
#define orc_arm_emit_orr_rsr(p,cond,S,Rd,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_ORR,S,Rd,Rn,Rm,sh,Rs)
#define orc_arm_emit_mov_rsr(p,cond,S,Rd,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_MOV,S,Rd, 0,Rm,sh,Rs)
#define orc_arm_emit_bic_rsr(p,cond,S,Rd,Rn,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_BIC,S,Rd,Rn,Rm,sh,Rs)
#define orc_arm_emit_mvn_rsr(p,cond,S,Rd,Rm,sh,Rs) orc_arm_emit_dp(p,3,cond,ORC_ARM_DP_MVN,S,Rd, 0,Rm,sh,Rs)
/* {}{s} {,} , , RRX */
#define orc_arm_emit_and_rrx(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_AND,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_eor_rrx(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_EOR,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_sub_rrx(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_SUB,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_rsb_rrx(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_RSB,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_add_rrx(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_ADD,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_adc_rrx(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_ADC,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_sbc_rrx(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_SBC,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_rsc_rrx(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_RSC,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_tst_rrx(p,cond,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_TST,1, 0,Rn,Rm,0,0)
#define orc_arm_emit_teq_rrx(p,cond,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_TEQ,1, 0,Rn,Rm,0,0)
#define orc_arm_emit_cmp_rrx(p,cond,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_CMP,1, 0,Rn,Rm,0,0)
#define orc_arm_emit_cmn_rrx(p,cond,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_CMN,1, 0,Rn,Rm,0,0)
#define orc_arm_emit_orr_rrx(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_ORR,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_mov_rrx(p,cond,S,Rd,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_MOV,S,Rd, 0,Rm,0,0)
#define orc_arm_emit_bic_rrx(p,cond,S,Rd,Rn,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_BIC,S,Rd,Rn,Rm,0,0)
#define orc_arm_emit_mvn_rrx(p,cond,S,Rd,Rm) orc_arm_emit_dp(p,4,cond,ORC_ARM_DP_MVN,S,Rd, 0,Rm,0,0)
/* parallel instructions */
#define orc_arm_emit_sadd16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,0,0,cond,Rd,Rn,Rm)
#define orc_arm_emit_qadd16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,0,1,cond,Rd,Rn,Rm)
#define orc_arm_emit_shadd16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,0,2,cond,Rd,Rn,Rm)
#define orc_arm_emit_uadd16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,0,3,cond,Rd,Rn,Rm)
#define orc_arm_emit_uqadd16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,0,4,cond,Rd,Rn,Rm)
#define orc_arm_emit_uhadd16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,0,5,cond,Rd,Rn,Rm)
#define orc_arm_emit_saddsubx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,1,0,cond,Rd,Rn,Rm)
#define orc_arm_emit_qaddsubx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,1,1,cond,Rd,Rn,Rm)
#define orc_arm_emit_shaddsubx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,1,2,cond,Rd,Rn,Rm)
#define orc_arm_emit_uaddsubx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,1,3,cond,Rd,Rn,Rm)
#define orc_arm_emit_uqaddsubx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,1,4,cond,Rd,Rn,Rm)
#define orc_arm_emit_uhaddsubx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,1,5,cond,Rd,Rn,Rm)
#define orc_arm_emit_ssubaddx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,2,0,cond,Rd,Rn,Rm)
#define orc_arm_emit_qsubaddx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,2,1,cond,Rd,Rn,Rm)
#define orc_arm_emit_shsubaddx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,2,2,cond,Rd,Rn,Rm)
#define orc_arm_emit_usubaddx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,2,3,cond,Rd,Rn,Rm)
#define orc_arm_emit_uqsubaddx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,2,4,cond,Rd,Rn,Rm)
#define orc_arm_emit_uhsubaddx(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,2,5,cond,Rd,Rn,Rm)
#define orc_arm_emit_ssub16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,3,0,cond,Rd,Rn,Rm)
#define orc_arm_emit_qsub16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,3,1,cond,Rd,Rn,Rm)
#define orc_arm_emit_shsub16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,3,2,cond,Rd,Rn,Rm)
#define orc_arm_emit_usub16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,3,3,cond,Rd,Rn,Rm)
#define orc_arm_emit_uqsub16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,3,4,cond,Rd,Rn,Rm)
#define orc_arm_emit_uhsub16(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,3,5,cond,Rd,Rn,Rm)
#define orc_arm_emit_sadd8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,4,0,cond,Rd,Rn,Rm)
#define orc_arm_emit_qadd8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,4,1,cond,Rd,Rn,Rm)
#define orc_arm_emit_shadd8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,4,2,cond,Rd,Rn,Rm)
#define orc_arm_emit_uadd8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,4,3,cond,Rd,Rn,Rm)
#define orc_arm_emit_uqadd8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,4,4,cond,Rd,Rn,Rm)
#define orc_arm_emit_uhadd8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,4,5,cond,Rd,Rn,Rm)
#define orc_arm_emit_ssub8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,5,0,cond,Rd,Rn,Rm)
#define orc_arm_emit_qsub8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,5,1,cond,Rd,Rn,Rm)
#define orc_arm_emit_shsub8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,5,2,cond,Rd,Rn,Rm)
#define orc_arm_emit_usub8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,5,3,cond,Rd,Rn,Rm)
#define orc_arm_emit_uqsub8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,5,4,cond,Rd,Rn,Rm)
#define orc_arm_emit_uhsub8(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,5,5,cond,Rd,Rn,Rm)
/* selection */
#define orc_arm_emit_sel(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,6,6,cond,Rd,Rn,Rm)
/* saturating add */
#define orc_arm_emit_qadd(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,7,7, cond,Rd,Rn,Rm)
#define orc_arm_emit_qsub(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,8,8, cond,Rd,Rn,Rm)
#define orc_arm_emit_qdadd(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,7,9, cond,Rd,Rn,Rm)
#define orc_arm_emit_qdsub(p,cond,Rd,Rn,Rm) orc_arm_emit_par(p,8,10,cond,Rd,Rn,Rm)
/* extend instructions */
/* with ROR #r8, r8 should be a multiple of 8 */
#define orc_arm_emit_sxtb16_r8(p,cond,Rd,Rm,r8) orc_arm_emit_xt(p,0, cond,Rd,15,Rm,r8)
#define orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,r8) orc_arm_emit_xt(p,1, cond,Rd,15,Rm,r8)
#define orc_arm_emit_sxth_r8(p,cond,Rd,Rm,r8) orc_arm_emit_xt(p,2, cond,Rd,15,Rm,r8)
#define orc_arm_emit_uxtb16_r8(p,cond,Rd,Rm,r8) orc_arm_emit_xt(p,3, cond,Rd,15,Rm,r8)
#define orc_arm_emit_uxtb_r8(p,cond,Rd,Rm,r8) orc_arm_emit_xt(p,4, cond,Rd,15,Rm,r8)
#define orc_arm_emit_uxth_r8(p,cond,Rd,Rm,r8) orc_arm_emit_xt(p,5, cond,Rd,15,Rm,r8)
#define orc_arm_emit_sxtab16_r8(p,cond,Rd,Rn,Rm,r8) orc_arm_emit_xt(p,6, cond,Rd,Rn,Rm,r8)
#define orc_arm_emit_sxtab_r8(p,cond,Rd,Rn,Rm,r8) orc_arm_emit_xt(p,7, cond,Rd,Rn,Rm,r8)
#define orc_arm_emit_sxtah_r8(p,cond,Rd,Rn,Rm,r8) orc_arm_emit_xt(p,8, cond,Rd,Rn,Rm,r8)
#define orc_arm_emit_uxtab16_r8(p,cond,Rd,Rn,Rm,r8) orc_arm_emit_xt(p,9, cond,Rd,Rn,Rm,r8)
#define orc_arm_emit_uxtab_r8(p,cond,Rd,Rn,Rm,r8) orc_arm_emit_xt(p,10,cond,Rd,Rn,Rm,r8)
#define orc_arm_emit_uxtah_r8(p,cond,Rd,Rn,Rm,r8) orc_arm_emit_xt(p,11,cond,Rd,Rn,Rm,r8)
/* with out rotate */
#define orc_arm_emit_sxtb16(p,cond,Rd,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
#define orc_arm_emit_sxtb(p,cond,Rd,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
#define orc_arm_emit_sxth(p,cond,Rd,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
#define orc_arm_emit_uxtb16(p,cond,Rd,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
#define orc_arm_emit_uxtb(p,cond,Rd,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
#define orc_arm_emit_uxth(p,cond,Rd,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
#define orc_arm_emit_sxtab16(p,cond,Rd,Rn,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
#define orc_arm_emit_sxtab(p,cond,Rd,Rn,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
#define orc_arm_emit_sxtah(p,cond,Rd,Rn,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
#define orc_arm_emit_uxtab16(p,cond,Rd,Rn,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
#define orc_arm_emit_uxtab(p,cond,Rd,Rn,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
#define orc_arm_emit_uxtah(p,cond,Rd,Rn,Rm) orc_arm_emit_sxtb_r8(p,cond,Rd,Rm,0)
/* misc instructions */
/* packing */
#define orc_arm_emit_pkhbt(p,cond,Rd,Rn,Rm) orc_arm_emit_pkh(p,0,cond,Rd,Rn,Rm,0)
#define orc_arm_emit_pkhtb(p,cond,Rd,Rn,Rm) orc_arm_emit_pkh(p,1,cond,Rd,Rn,Rm,0)
/* with [LSL|ASR] #imm */
#define orc_arm_emit_pkhbt_s(p,cond,Rd,Rn,Rm,lsl) orc_arm_emit_pkh(p,0,cond,Rd,Rn,Rm,lsl)
#define orc_arm_emit_pkhtb_s(p,cond,Rd,Rn,Rm,asr) orc_arm_emit_pkh(p,1,cond,Rd,Rn,Rm,asr)
/* saturation */
#define orc_arm_emit_ssat(p,cond,Rd,sat,Rm) orc_arm_emit_sat(p,0,cond,Rd,sat,Rm,0, 0)
#define orc_arm_emit_usat(p,cond,Rd,sat,Rm) orc_arm_emit_sat(p,1,cond,Rd,sat,Rm,0, 0)
#define orc_arm_emit_ssat_lsl(p,cond,Rd,sat,Rm,sh) orc_arm_emit_sat(p,0,cond,Rd,sat,Rm,sh,0)
#define orc_arm_emit_usat_lsl(p,cond,Rd,sat,Rm,sh) orc_arm_emit_sat(p,1,cond,Rd,sat,Rm,sh,0)
#define orc_arm_emit_ssat_asr(p,cond,Rd,sat,Rm,sh) orc_arm_emit_sat(p,0,cond,Rd,sat,Rm,sh,1)
#define orc_arm_emit_usat_asr(p,cond,Rd,sat,Rm,sh) orc_arm_emit_sat(p,1,cond,Rd,sat,Rm,sh,1)
#define orc_arm_emit_ssat16(p,cond,Rd,sat,Rm) orc_arm_emit_sat(p,2,cond,Rd,sat,Rm,0, 0)
#define orc_arm_emit_usat16(p,cond,Rd,sat,Rm) orc_arm_emit_sat(p,3,cond,Rd,sat,Rm,0, 0)
/* reversing */
#define orc_arm_emit_rev(p,cond,Rd,Rm) orc_arm_emit_rv (p,0,cond,Rd,Rm)
#define orc_arm_emit_rev16(p,cond,Rd,Rm) orc_arm_emit_rv (p,1,cond,Rd,Rm)
#endif
ORC_END_DECLS
#endif
orc-0.4.18/orc/orconce.c 0000664 0001750 0001750 00000003554 12071634360 011702 0000000 0000000
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include
#include
#if defined(HAVE_THREAD_PTHREAD)
#include
static pthread_mutex_t once_mutex = PTHREAD_MUTEX_INITIALIZER;
static pthread_mutex_t global_mutex = PTHREAD_MUTEX_INITIALIZER;
void
orc_once_mutex_lock (void)
{
pthread_mutex_lock (&once_mutex);
}
void
orc_once_mutex_unlock (void)
{
pthread_mutex_unlock (&once_mutex);
}
void
orc_global_mutex_lock (void)
{
pthread_mutex_lock (&global_mutex);
}
void
orc_global_mutex_unlock (void)
{
pthread_mutex_unlock (&global_mutex);
}
#elif defined(HAVE_THREAD_WIN32)
#include
static CRITICAL_SECTION once_mutex;
static CRITICAL_SECTION global_mutex;
void
orc_once_mutex_lock (void)
{
EnterCriticalSection (&once_mutex);
}
void
orc_once_mutex_unlock (void)
{
LeaveCriticalSection (&once_mutex);
}
void
orc_global_mutex_lock (void)
{
EnterCriticalSection (&global_mutex);
}
void
orc_global_mutex_unlock (void)
{
LeaveCriticalSection (&global_mutex);
}
#ifdef _MSC_VER
#pragma section(".CRT$XCU",read)
static void __cdecl
orc_once_cs_init (void)
{
InitializeCriticalSection (&once_mutex);
InitializeCriticalSection (&global_mutex);
}
__declspec(allocate(".CRT$XCU"))
void (__cdecl * orc_once_cs_init_constructor)(void) = orc_once_cs_init;
#elif defined(__GNUC__)
static void orc_once_cs_init (void) __attribute__((constructor));
static void
orc_once_cs_init (void)
{
InitializeCriticalSection (&once_mutex);
InitializeCriticalSection (&global_mutex);
}
#else
#error Expecting GCC or MSVC on Windows
#endif
#if 0
BOOL WINAPI
DllMain (HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved)
{
if (dwReason == DLL_PROCESS_ATTACH) {
InitializeCriticalSection (&once_mutex);
}
return TRUE;
}
#endif
#else
void
orc_once_mutex_lock (void)
{
}
void
orc_once_mutex_unlock (void)
{
}
#endif
orc-0.4.18/orc/Makefile.in 0000664 0001750 0001750 00000240612 12206165327 012153 0000000 0000000 # Makefile.in generated by automake 1.11.6 from Makefile.am.
# @configure_input@
# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
# 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Free Software
# Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
@SET_MAKE@
VPATH = @srcdir@
am__make_dryrun = \
{ \
am__dry=no; \
case $$MAKEFLAGS in \
*\\[\ \ ]*) \
echo 'am--echo: ; @echo "AM" OK' | $(MAKE) -f - 2>/dev/null \
| grep '^AM OK$$' >/dev/null || am__dry=yes;; \
*) \
for am__flg in $$MAKEFLAGS; do \
case $$am__flg in \
*=*|--*) ;; \
*n*) am__dry=yes; break;; \
esac; \
done;; \
esac; \
test $$am__dry = yes; \
}
pkgdatadir = $(datadir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkglibexecdir = $(libexecdir)/@PACKAGE@
am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
install_sh_DATA = $(install_sh) -c -m 644
install_sh_PROGRAM = $(install_sh) -c
install_sh_SCRIPT = $(install_sh) -c
INSTALL_HEADER = $(INSTALL_DATA)
transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = @build@
host_triplet = @host@
@ENABLE_BACKEND_SSE_TRUE@am__append_1 = orcsse.c orcrules-sse.c \
@ENABLE_BACKEND_SSE_TRUE@ orcprogram-sse.c orcx86.c \
@ENABLE_BACKEND_SSE_TRUE@ orcx86insn.c
@ENABLE_BACKEND_MMX_TRUE@am__append_2 = orcmmx.c orcrules-mmx.c orcprogram-mmx.c
@ENABLE_BACKEND_MMX_TRUE@@ENABLE_BACKEND_SSE_FALSE@am__append_3 = orcx86.c
@ENABLE_BACKEND_ALTIVEC_TRUE@am__append_4 = \
@ENABLE_BACKEND_ALTIVEC_TRUE@ orcrules-altivec.c orcprogram-altivec.c orcpowerpc.c
@ENABLE_BACKEND_NEON_TRUE@am__append_5 = orcprogram-neon.c \
@ENABLE_BACKEND_NEON_TRUE@ orcrules-neon.c orcarm.c
@ENABLE_BACKEND_ARM_TRUE@am__append_6 = orcprogram-arm.c orcrules-arm.c
@ENABLE_BACKEND_ARM_TRUE@@ENABLE_BACKEND_NEON_FALSE@am__append_7 = orcarm.c
@ENABLE_BACKEND_C64X_TRUE@am__append_8 = orcprogram-c64x-c.c
@ENABLE_BACKEND_MIPS_TRUE@am__append_9 = orcmips.c orcprogram-mips.c orcrules-mips.c
@HAVE_I386_TRUE@am__append_10 = orccpu-x86.c
@HAVE_AMD64_TRUE@am__append_11 = orccpu-x86.c
@HAVE_POWERPC_TRUE@am__append_12 = orccpu-powerpc.c
@HAVE_ARM_TRUE@am__append_13 = orccpu-arm.c
noinst_PROGRAMS = generate-emulation$(EXEEXT) \
generate-bytecode$(EXEEXT)
subdir = orc
DIST_COMMON = $(noinst_HEADERS) $(pkginclude_HEADERS) \
$(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/ac_libtool_tags.m4 \
$(top_srcdir)/m4/as-compiler-flag.m4 \
$(top_srcdir)/m4/as-host-defines.m4 \
$(top_srcdir)/m4/as-nano.m4 $(top_srcdir)/m4/gtk-doc.m4 \
$(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltoptions.m4 \
$(top_srcdir)/m4/ltsugar.m4 $(top_srcdir)/m4/ltversion.m4 \
$(top_srcdir)/m4/lt~obsolete.m4 $(top_srcdir)/m4/pkg.m4 \
$(top_srcdir)/configure.ac
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
$(ACLOCAL_M4)
mkinstalldirs = $(install_sh) -d
CONFIG_HEADER = $(top_builddir)/config.h
CONFIG_CLEAN_FILES =
CONFIG_CLEAN_VPATH_FILES =
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 = f=`echo $$p | sed -e 's|^.*/||'`;
am__install_max = 40
am__nobase_strip_setup = \
srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
am__nobase_strip = \
for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
am__nobase_list = $(am__nobase_strip_setup); \
for p in $$list; do echo "$$p $$p"; done | \
sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
$(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
if (++n[$$2] == $(am__install_max)) \
{ print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
END { for (dir in files) print dir, files[dir] }'
am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
am__uninstall_files_from_dir = { \
test -z "$$files" \
|| { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
|| { echo " ( cd '$$dir' && rm -f" $$files ")"; \
$(am__cd) "$$dir" && rm -f $$files; }; \
}
am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(pkgincludedir)"
LTLIBRARIES = $(lib_LTLIBRARIES)
am__DEPENDENCIES_1 =
liborc_@ORC_MAJORMINOR@_la_DEPENDENCIES = $(am__DEPENDENCIES_1) \
$(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1)
am__liborc_@ORC_MAJORMINOR@_la_SOURCES_DIST = orc.c orcbytecode.c \
orcemulateopcodes.c orcexecutor.c orcfunctions.c orcutils.c \
orcrule.c orccodemem.c orcprogram.c orccompiler.c \
orcprogram-c.c orcprogram.h orcopcodes.c orcparse.c orconce.c \
orcdebug.c orccode.c orcsse.c orcrules-sse.c orcprogram-sse.c \
orcx86.c orcx86insn.c orcmmx.c orcrules-mmx.c orcprogram-mmx.c \
orcrules-altivec.c orcprogram-altivec.c orcpowerpc.c \
orcprogram-neon.c orcrules-neon.c orcarm.c orcprogram-arm.c \
orcrules-arm.c orcprogram-c64x-c.c orcmips.c orcprogram-mips.c \
orcrules-mips.c orccpu-x86.c orccpu-powerpc.c orccpu-arm.c
@ENABLE_BACKEND_SSE_TRUE@am__objects_1 = \
@ENABLE_BACKEND_SSE_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcsse.lo \
@ENABLE_BACKEND_SSE_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcrules-sse.lo \
@ENABLE_BACKEND_SSE_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcprogram-sse.lo \
@ENABLE_BACKEND_SSE_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcx86.lo \
@ENABLE_BACKEND_SSE_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcx86insn.lo
@ENABLE_BACKEND_MMX_TRUE@am__objects_2 = \
@ENABLE_BACKEND_MMX_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcmmx.lo \
@ENABLE_BACKEND_MMX_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcrules-mmx.lo \
@ENABLE_BACKEND_MMX_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcprogram-mmx.lo
@ENABLE_BACKEND_MMX_TRUE@@ENABLE_BACKEND_SSE_FALSE@am__objects_3 = liborc_@ORC_MAJORMINOR@_la-orcx86.lo
@ENABLE_BACKEND_ALTIVEC_TRUE@am__objects_4 = liborc_@ORC_MAJORMINOR@_la-orcrules-altivec.lo \
@ENABLE_BACKEND_ALTIVEC_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcprogram-altivec.lo \
@ENABLE_BACKEND_ALTIVEC_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcpowerpc.lo
@ENABLE_BACKEND_NEON_TRUE@am__objects_5 = liborc_@ORC_MAJORMINOR@_la-orcprogram-neon.lo \
@ENABLE_BACKEND_NEON_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcrules-neon.lo \
@ENABLE_BACKEND_NEON_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcarm.lo
@ENABLE_BACKEND_ARM_TRUE@am__objects_6 = liborc_@ORC_MAJORMINOR@_la-orcprogram-arm.lo \
@ENABLE_BACKEND_ARM_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcrules-arm.lo
@ENABLE_BACKEND_ARM_TRUE@@ENABLE_BACKEND_NEON_FALSE@am__objects_7 = liborc_@ORC_MAJORMINOR@_la-orcarm.lo
@ENABLE_BACKEND_C64X_TRUE@am__objects_8 = liborc_@ORC_MAJORMINOR@_la-orcprogram-c64x-c.lo
@ENABLE_BACKEND_MIPS_TRUE@am__objects_9 = liborc_@ORC_MAJORMINOR@_la-orcmips.lo \
@ENABLE_BACKEND_MIPS_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcprogram-mips.lo \
@ENABLE_BACKEND_MIPS_TRUE@ liborc_@ORC_MAJORMINOR@_la-orcrules-mips.lo
@HAVE_I386_TRUE@am__objects_10 = \
@HAVE_I386_TRUE@ liborc_@ORC_MAJORMINOR@_la-orccpu-x86.lo
@HAVE_AMD64_TRUE@am__objects_11 = \
@HAVE_AMD64_TRUE@ liborc_@ORC_MAJORMINOR@_la-orccpu-x86.lo
@HAVE_POWERPC_TRUE@am__objects_12 = liborc_@ORC_MAJORMINOR@_la-orccpu-powerpc.lo
@HAVE_ARM_TRUE@am__objects_13 = \
@HAVE_ARM_TRUE@ liborc_@ORC_MAJORMINOR@_la-orccpu-arm.lo
am_liborc_@ORC_MAJORMINOR@_la_OBJECTS = \
liborc_@ORC_MAJORMINOR@_la-orc.lo \
liborc_@ORC_MAJORMINOR@_la-orcbytecode.lo \
liborc_@ORC_MAJORMINOR@_la-orcemulateopcodes.lo \
liborc_@ORC_MAJORMINOR@_la-orcexecutor.lo \
liborc_@ORC_MAJORMINOR@_la-orcfunctions.lo \
liborc_@ORC_MAJORMINOR@_la-orcutils.lo \
liborc_@ORC_MAJORMINOR@_la-orcrule.lo \
liborc_@ORC_MAJORMINOR@_la-orccodemem.lo \
liborc_@ORC_MAJORMINOR@_la-orcprogram.lo \
liborc_@ORC_MAJORMINOR@_la-orccompiler.lo \
liborc_@ORC_MAJORMINOR@_la-orcprogram-c.lo \
liborc_@ORC_MAJORMINOR@_la-orcopcodes.lo \
liborc_@ORC_MAJORMINOR@_la-orcparse.lo \
liborc_@ORC_MAJORMINOR@_la-orconce.lo \
liborc_@ORC_MAJORMINOR@_la-orcdebug.lo \
liborc_@ORC_MAJORMINOR@_la-orccode.lo $(am__objects_1) \
$(am__objects_2) $(am__objects_3) $(am__objects_4) \
$(am__objects_5) $(am__objects_6) $(am__objects_7) \
$(am__objects_8) $(am__objects_9) $(am__objects_10) \
$(am__objects_11) $(am__objects_12) $(am__objects_13)
liborc_@ORC_MAJORMINOR@_la_OBJECTS = \
$(am_liborc_@ORC_MAJORMINOR@_la_OBJECTS)
liborc_@ORC_MAJORMINOR@_la_LINK = $(LIBTOOL) --tag=CC \
$(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CCLD) \
$(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) \
$(liborc_@ORC_MAJORMINOR@_la_LDFLAGS) $(LDFLAGS) -o $@
PROGRAMS = $(noinst_PROGRAMS)
generate_bytecode_SOURCES = generate-bytecode.c
generate_bytecode_OBJECTS = \
generate_bytecode-generate-bytecode.$(OBJEXT)
generate_bytecode_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=link $(CCLD) \
$(generate_bytecode_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) \
-o $@
generate_emulation_SOURCES = generate-emulation.c
generate_emulation_OBJECTS = \
generate_emulation-generate-emulation.$(OBJEXT)
generate_emulation_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
$(LIBTOOLFLAGS) --mode=link $(CCLD) \
$(generate_emulation_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
$(LDFLAGS) -o $@
DEFAULT_INCLUDES = -I.@am__isrc@ -I$(top_builddir)
depcomp = $(SHELL) $(top_srcdir)/depcomp
am__depfiles_maybe = depfiles
am__mv = mv -f
COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
CCLD = $(CC)
LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
$(LDFLAGS) -o $@
SOURCES = $(liborc_@ORC_MAJORMINOR@_la_SOURCES) generate-bytecode.c \
generate-emulation.c
DIST_SOURCES = $(am__liborc_@ORC_MAJORMINOR@_la_SOURCES_DIST) \
generate-bytecode.c generate-emulation.c
am__can_run_installinfo = \
case $$AM_UPDATE_INFO_DIR in \
n|no|NO) false;; \
*) (install-info --version) >/dev/null 2>&1;; \
esac
HEADERS = $(noinst_HEADERS) $(pkginclude_HEADERS)
ETAGS = etags
CTAGS = ctags
DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
pkgincludedir = $(includedir)/orc-@ORC_MAJORMINOR@/orc
ACLOCAL = @ACLOCAL@
ACLOCAL_AMFLAGS = @ACLOCAL_AMFLAGS@
AMTAR = @AMTAR@
AR = @AR@
AS = @AS@
AUTOCONF = @AUTOCONF@
AUTOHEADER = @AUTOHEADER@
AUTOMAKE = @AUTOMAKE@
AWK = @AWK@
CC = @CC@
CCAS = @CCAS@
CCASDEPMODE = @CCASDEPMODE@
CCASFLAGS = @CCASFLAGS@
CCDEPMODE = @CCDEPMODE@
CFLAGS = @CFLAGS@
CPP = @CPP@
CPPFLAGS = @CPPFLAGS@
CYGPATH_W = @CYGPATH_W@
DEFS = @DEFS@
DEPDIR = @DEPDIR@
DLLTOOL = @DLLTOOL@
DSYMUTIL = @DSYMUTIL@
DUMPBIN = @DUMPBIN@
ECHO_C = @ECHO_C@
ECHO_N = @ECHO_N@
ECHO_T = @ECHO_T@
EGREP = @EGREP@
ERROR_CFLAGS = @ERROR_CFLAGS@
EXEEXT = @EXEEXT@
FGREP = @FGREP@
GREP = @GREP@
GTKDOC_CHECK = @GTKDOC_CHECK@
GTKDOC_MKPDF = @GTKDOC_MKPDF@
GTKDOC_REBASE = @GTKDOC_REBASE@
HTML_DIR = @HTML_DIR@
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LD = @LD@
LDFLAGS = @LDFLAGS@
LIBM = @LIBM@
LIBOBJS = @LIBOBJS@
LIBRT = @LIBRT@
LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
LIPO = @LIPO@
LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@
MAKEINFO = @MAKEINFO@
MANIFEST_TOOL = @MANIFEST_TOOL@
MKDIR_P = @MKDIR_P@
NANO = @NANO@
NM = @NM@
NMEDIT = @NMEDIT@
OBJDUMP = @OBJDUMP@
OBJEXT = @OBJEXT@
ORC_CFLAGS = @ORC_CFLAGS@
ORC_LIBS = @ORC_LIBS@
ORC_LIBVERSION = @ORC_LIBVERSION@
ORC_MAJORMINOR = @ORC_MAJORMINOR@
OTOOL = @OTOOL@
OTOOL64 = @OTOOL64@
PACKAGE = @PACKAGE@
PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_STRING = @PACKAGE_STRING@
PACKAGE_TARNAME = @PACKAGE_TARNAME@
PACKAGE_URL = @PACKAGE_URL@
PACKAGE_VERSION = @PACKAGE_VERSION@
PATH_SEPARATOR = @PATH_SEPARATOR@
PKG_CONFIG = @PKG_CONFIG@
PTHREAD_CFLAGS = @PTHREAD_CFLAGS@
PTHREAD_LIBS = @PTHREAD_LIBS@
RANLIB = @RANLIB@
SED = @SED@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
STRIP = @STRIP@
VERSION = @VERSION@
abs_builddir = @abs_builddir@
abs_srcdir = @abs_srcdir@
abs_top_builddir = @abs_top_builddir@
abs_top_srcdir = @abs_top_srcdir@
ac_ct_AR = @ac_ct_AR@
ac_ct_CC = @ac_ct_CC@
ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
am__include = @am__include@
am__leading_dot = @am__leading_dot@
am__quote = @am__quote@
am__tar = @am__tar@
am__untar = @am__untar@
bindir = @bindir@
build = @build@
build_alias = @build_alias@
build_cpu = @build_cpu@
build_os = @build_os@
build_vendor = @build_vendor@
builddir = @builddir@
datadir = @datadir@
datarootdir = @datarootdir@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@
host = @host@
host_alias = @host_alias@
host_cpu = @host_cpu@
host_os = @host_os@
host_vendor = @host_vendor@
htmldir = @htmldir@
includedir = @includedir@
infodir = @infodir@
install_sh = @install_sh@
libdir = @libdir@
libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@
mandir = @mandir@
mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@
pdfdir = @pdfdir@
pkgconfigdir = @pkgconfigdir@
prefix = @prefix@
program_transform_name = @program_transform_name@
psdir = @psdir@
sbindir = @sbindir@
sharedstatedir = @sharedstatedir@
srcdir = @srcdir@
sysconfdir = @sysconfdir@
target_alias = @target_alias@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
lib_LTLIBRARIES = liborc-@ORC_MAJORMINOR@.la
liborc_@ORC_MAJORMINOR@_la_LIBADD = $(LIBM) $(LIBRT) $(PTHREAD_LIBS)
liborc_@ORC_MAJORMINOR@_la_LDFLAGS = \
-version-info $(ORC_LIBVERSION) \
-no-undefined -export-symbols-regex 'orc_'
liborc_@ORC_MAJORMINOR@_la_CFLAGS = $(ORC_CFLAGS) \
-DORC_ENABLE_UNSTABLE_API
liborc_@ORC_MAJORMINOR@_la_SOURCES = orc.c orcbytecode.c \
orcemulateopcodes.c orcexecutor.c orcfunctions.c orcutils.c \
orcrule.c orccodemem.c orcprogram.c orccompiler.c \
orcprogram-c.c orcprogram.h orcopcodes.c orcparse.c orconce.c \
orcdebug.c orccode.c $(am__append_1) $(am__append_2) \
$(am__append_3) $(am__append_4) $(am__append_5) \
$(am__append_6) $(am__append_7) $(am__append_8) \
$(am__append_9) $(am__append_10) $(am__append_11) \
$(am__append_12) $(am__append_13)
pkginclude_HEADERS = \
orc-stdint.h \
orc.h \
orcarm.h \
orcbytecode.h \
orcbytecodes.h \
orccode.h \
orccompiler.h \
orcconstant.h \
orccpu.h \
orccpuinsn.h \
orcdebug.h \
orcemulateopcodes.h \
orcexecutor.h \
orcfunctions.h \
orcinstruction.h \
orcinternal.h \
orclimits.h \
orcmmx.h \
orcneon.h \
orconce.h \
orcopcode.h \
orcparse.h \
orcpowerpc.h \
orcprogram.h \
orcrule.h \
orcsse.h \
orctarget.h \
orcutils.h \
orcvariable.h \
orcx86.h \
orcx86insn.h \
orcmips.h
noinst_HEADERS = \
opcodes.h
generate_emulation_LDADD = $(ORC_LIBS)
generate_emulation_CFLAGS = $(ORC_CFLAGS)
generate_emulation_DEPENDENCIES = liborc-0.4.la
generate_bytecode_LDADD = $(ORC_LIBS)
generate_bytecode_CFLAGS = $(ORC_CFLAGS)
generate_bytecode_DEPENDENCIES = liborc-0.4.la
all: all-am
.SUFFIXES:
.SUFFIXES: .c .lo .o .obj
$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
&& { if test -f $@; then exit 0; else break; fi; }; \
exit 1;; \
esac; \
done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu orc/Makefile'; \
$(am__cd) $(top_srcdir) && \
$(AUTOMAKE) --gnu orc/Makefile
.PRECIOUS: Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \
*config.status*) \
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
*) \
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
esac;
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(top_srcdir)/configure: $(am__configure_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(ACLOCAL_M4): $(am__aclocal_m4_deps)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
$(am__aclocal_m4_deps):
install-libLTLIBRARIES: $(lib_LTLIBRARIES)
@$(NORMAL_INSTALL)
@list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
list2=; for p in $$list; do \
if test -f $$p; then \
list2="$$list2 $$p"; \
else :; fi; \
done; \
test -z "$$list2" || { \
echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \
$(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \
}
uninstall-libLTLIBRARIES:
@$(NORMAL_UNINSTALL)
@list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
for p in $$list; do \
$(am__strip_dir) \
echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \
$(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \
done
clean-libLTLIBRARIES:
-test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES)
@list='$(lib_LTLIBRARIES)'; for p in $$list; do \
dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \
test "$$dir" != "$$p" || dir=.; \
echo "rm -f \"$${dir}/so_locations\""; \
rm -f "$${dir}/so_locations"; \
done
liborc-@ORC_MAJORMINOR@.la: $(liborc_@ORC_MAJORMINOR@_la_OBJECTS) $(liborc_@ORC_MAJORMINOR@_la_DEPENDENCIES) $(EXTRA_liborc_@ORC_MAJORMINOR@_la_DEPENDENCIES)
$(liborc_@ORC_MAJORMINOR@_la_LINK) -rpath $(libdir) $(liborc_@ORC_MAJORMINOR@_la_OBJECTS) $(liborc_@ORC_MAJORMINOR@_la_LIBADD) $(LIBS)
clean-noinstPROGRAMS:
@list='$(noinst_PROGRAMS)'; test -n "$$list" || exit 0; \
echo " rm -f" $$list; \
rm -f $$list || exit $$?; \
test -n "$(EXEEXT)" || exit 0; \
list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
echo " rm -f" $$list; \
rm -f $$list
generate-bytecode$(EXEEXT): $(generate_bytecode_OBJECTS) $(generate_bytecode_DEPENDENCIES) $(EXTRA_generate_bytecode_DEPENDENCIES)
@rm -f generate-bytecode$(EXEEXT)
$(generate_bytecode_LINK) $(generate_bytecode_OBJECTS) $(generate_bytecode_LDADD) $(LIBS)
generate-emulation$(EXEEXT): $(generate_emulation_OBJECTS) $(generate_emulation_DEPENDENCIES) $(EXTRA_generate_emulation_DEPENDENCIES)
@rm -f generate-emulation$(EXEEXT)
$(generate_emulation_LINK) $(generate_emulation_OBJECTS) $(generate_emulation_LDADD) $(LIBS)
mostlyclean-compile:
-rm -f *.$(OBJEXT)
distclean-compile:
-rm -f *.tab.c
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/generate_bytecode-generate-bytecode.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/generate_emulation-generate-emulation.Po@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orc.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcarm.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcbytecode.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccode.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccodemem.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccompiler.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-arm.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-powerpc.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-x86.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcdebug.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcemulateopcodes.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcexecutor.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcfunctions.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcmips.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcmmx.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orconce.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcopcodes.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcparse.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcpowerpc.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-altivec.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-arm.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-c.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-c64x-c.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-mips.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-mmx.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-neon.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-sse.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrule.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-altivec.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-arm.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-mips.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-mmx.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-neon.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-sse.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcsse.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcutils.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcx86.Plo@am__quote@
@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcx86insn.Plo@am__quote@
.c.o:
@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(COMPILE) -c $<
.c.obj:
@am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'`
.c.lo:
@am__fastdepCC_TRUE@ $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $<
liborc_@ORC_MAJORMINOR@_la-orc.lo: orc.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orc.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orc.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orc.lo `test -f 'orc.c' || echo '$(srcdir)/'`orc.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orc.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orc.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orc.c' object='liborc_@ORC_MAJORMINOR@_la-orc.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orc.lo `test -f 'orc.c' || echo '$(srcdir)/'`orc.c
liborc_@ORC_MAJORMINOR@_la-orcbytecode.lo: orcbytecode.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcbytecode.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcbytecode.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcbytecode.lo `test -f 'orcbytecode.c' || echo '$(srcdir)/'`orcbytecode.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcbytecode.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcbytecode.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcbytecode.c' object='liborc_@ORC_MAJORMINOR@_la-orcbytecode.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcbytecode.lo `test -f 'orcbytecode.c' || echo '$(srcdir)/'`orcbytecode.c
liborc_@ORC_MAJORMINOR@_la-orcemulateopcodes.lo: orcemulateopcodes.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcemulateopcodes.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcemulateopcodes.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcemulateopcodes.lo `test -f 'orcemulateopcodes.c' || echo '$(srcdir)/'`orcemulateopcodes.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcemulateopcodes.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcemulateopcodes.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcemulateopcodes.c' object='liborc_@ORC_MAJORMINOR@_la-orcemulateopcodes.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcemulateopcodes.lo `test -f 'orcemulateopcodes.c' || echo '$(srcdir)/'`orcemulateopcodes.c
liborc_@ORC_MAJORMINOR@_la-orcexecutor.lo: orcexecutor.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcexecutor.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcexecutor.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcexecutor.lo `test -f 'orcexecutor.c' || echo '$(srcdir)/'`orcexecutor.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcexecutor.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcexecutor.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcexecutor.c' object='liborc_@ORC_MAJORMINOR@_la-orcexecutor.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcexecutor.lo `test -f 'orcexecutor.c' || echo '$(srcdir)/'`orcexecutor.c
liborc_@ORC_MAJORMINOR@_la-orcfunctions.lo: orcfunctions.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcfunctions.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcfunctions.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcfunctions.lo `test -f 'orcfunctions.c' || echo '$(srcdir)/'`orcfunctions.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcfunctions.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcfunctions.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcfunctions.c' object='liborc_@ORC_MAJORMINOR@_la-orcfunctions.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcfunctions.lo `test -f 'orcfunctions.c' || echo '$(srcdir)/'`orcfunctions.c
liborc_@ORC_MAJORMINOR@_la-orcutils.lo: orcutils.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcutils.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcutils.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcutils.lo `test -f 'orcutils.c' || echo '$(srcdir)/'`orcutils.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcutils.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcutils.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcutils.c' object='liborc_@ORC_MAJORMINOR@_la-orcutils.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcutils.lo `test -f 'orcutils.c' || echo '$(srcdir)/'`orcutils.c
liborc_@ORC_MAJORMINOR@_la-orcrule.lo: orcrule.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcrule.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrule.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcrule.lo `test -f 'orcrule.c' || echo '$(srcdir)/'`orcrule.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrule.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrule.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcrule.c' object='liborc_@ORC_MAJORMINOR@_la-orcrule.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcrule.lo `test -f 'orcrule.c' || echo '$(srcdir)/'`orcrule.c
liborc_@ORC_MAJORMINOR@_la-orccodemem.lo: orccodemem.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orccodemem.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccodemem.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orccodemem.lo `test -f 'orccodemem.c' || echo '$(srcdir)/'`orccodemem.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccodemem.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccodemem.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orccodemem.c' object='liborc_@ORC_MAJORMINOR@_la-orccodemem.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orccodemem.lo `test -f 'orccodemem.c' || echo '$(srcdir)/'`orccodemem.c
liborc_@ORC_MAJORMINOR@_la-orcprogram.lo: orcprogram.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcprogram.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram.lo `test -f 'orcprogram.c' || echo '$(srcdir)/'`orcprogram.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcprogram.c' object='liborc_@ORC_MAJORMINOR@_la-orcprogram.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram.lo `test -f 'orcprogram.c' || echo '$(srcdir)/'`orcprogram.c
liborc_@ORC_MAJORMINOR@_la-orccompiler.lo: orccompiler.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orccompiler.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccompiler.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orccompiler.lo `test -f 'orccompiler.c' || echo '$(srcdir)/'`orccompiler.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccompiler.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccompiler.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orccompiler.c' object='liborc_@ORC_MAJORMINOR@_la-orccompiler.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orccompiler.lo `test -f 'orccompiler.c' || echo '$(srcdir)/'`orccompiler.c
liborc_@ORC_MAJORMINOR@_la-orcprogram-c.lo: orcprogram-c.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcprogram-c.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-c.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-c.lo `test -f 'orcprogram-c.c' || echo '$(srcdir)/'`orcprogram-c.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-c.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-c.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcprogram-c.c' object='liborc_@ORC_MAJORMINOR@_la-orcprogram-c.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-c.lo `test -f 'orcprogram-c.c' || echo '$(srcdir)/'`orcprogram-c.c
liborc_@ORC_MAJORMINOR@_la-orcopcodes.lo: orcopcodes.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcopcodes.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcopcodes.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcopcodes.lo `test -f 'orcopcodes.c' || echo '$(srcdir)/'`orcopcodes.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcopcodes.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcopcodes.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcopcodes.c' object='liborc_@ORC_MAJORMINOR@_la-orcopcodes.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcopcodes.lo `test -f 'orcopcodes.c' || echo '$(srcdir)/'`orcopcodes.c
liborc_@ORC_MAJORMINOR@_la-orcparse.lo: orcparse.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcparse.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcparse.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcparse.lo `test -f 'orcparse.c' || echo '$(srcdir)/'`orcparse.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcparse.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcparse.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcparse.c' object='liborc_@ORC_MAJORMINOR@_la-orcparse.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcparse.lo `test -f 'orcparse.c' || echo '$(srcdir)/'`orcparse.c
liborc_@ORC_MAJORMINOR@_la-orconce.lo: orconce.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orconce.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orconce.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orconce.lo `test -f 'orconce.c' || echo '$(srcdir)/'`orconce.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orconce.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orconce.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orconce.c' object='liborc_@ORC_MAJORMINOR@_la-orconce.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orconce.lo `test -f 'orconce.c' || echo '$(srcdir)/'`orconce.c
liborc_@ORC_MAJORMINOR@_la-orcdebug.lo: orcdebug.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcdebug.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcdebug.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcdebug.lo `test -f 'orcdebug.c' || echo '$(srcdir)/'`orcdebug.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcdebug.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcdebug.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcdebug.c' object='liborc_@ORC_MAJORMINOR@_la-orcdebug.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcdebug.lo `test -f 'orcdebug.c' || echo '$(srcdir)/'`orcdebug.c
liborc_@ORC_MAJORMINOR@_la-orccode.lo: orccode.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orccode.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccode.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orccode.lo `test -f 'orccode.c' || echo '$(srcdir)/'`orccode.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccode.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccode.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orccode.c' object='liborc_@ORC_MAJORMINOR@_la-orccode.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orccode.lo `test -f 'orccode.c' || echo '$(srcdir)/'`orccode.c
liborc_@ORC_MAJORMINOR@_la-orcsse.lo: orcsse.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcsse.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcsse.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcsse.lo `test -f 'orcsse.c' || echo '$(srcdir)/'`orcsse.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcsse.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcsse.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcsse.c' object='liborc_@ORC_MAJORMINOR@_la-orcsse.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcsse.lo `test -f 'orcsse.c' || echo '$(srcdir)/'`orcsse.c
liborc_@ORC_MAJORMINOR@_la-orcrules-sse.lo: orcrules-sse.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcrules-sse.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-sse.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-sse.lo `test -f 'orcrules-sse.c' || echo '$(srcdir)/'`orcrules-sse.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-sse.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-sse.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcrules-sse.c' object='liborc_@ORC_MAJORMINOR@_la-orcrules-sse.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-sse.lo `test -f 'orcrules-sse.c' || echo '$(srcdir)/'`orcrules-sse.c
liborc_@ORC_MAJORMINOR@_la-orcprogram-sse.lo: orcprogram-sse.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcprogram-sse.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-sse.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-sse.lo `test -f 'orcprogram-sse.c' || echo '$(srcdir)/'`orcprogram-sse.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-sse.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-sse.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcprogram-sse.c' object='liborc_@ORC_MAJORMINOR@_la-orcprogram-sse.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-sse.lo `test -f 'orcprogram-sse.c' || echo '$(srcdir)/'`orcprogram-sse.c
liborc_@ORC_MAJORMINOR@_la-orcx86.lo: orcx86.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcx86.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcx86.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcx86.lo `test -f 'orcx86.c' || echo '$(srcdir)/'`orcx86.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcx86.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcx86.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcx86.c' object='liborc_@ORC_MAJORMINOR@_la-orcx86.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcx86.lo `test -f 'orcx86.c' || echo '$(srcdir)/'`orcx86.c
liborc_@ORC_MAJORMINOR@_la-orcx86insn.lo: orcx86insn.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcx86insn.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcx86insn.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcx86insn.lo `test -f 'orcx86insn.c' || echo '$(srcdir)/'`orcx86insn.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcx86insn.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcx86insn.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcx86insn.c' object='liborc_@ORC_MAJORMINOR@_la-orcx86insn.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcx86insn.lo `test -f 'orcx86insn.c' || echo '$(srcdir)/'`orcx86insn.c
liborc_@ORC_MAJORMINOR@_la-orcmmx.lo: orcmmx.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcmmx.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcmmx.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcmmx.lo `test -f 'orcmmx.c' || echo '$(srcdir)/'`orcmmx.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcmmx.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcmmx.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcmmx.c' object='liborc_@ORC_MAJORMINOR@_la-orcmmx.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcmmx.lo `test -f 'orcmmx.c' || echo '$(srcdir)/'`orcmmx.c
liborc_@ORC_MAJORMINOR@_la-orcrules-mmx.lo: orcrules-mmx.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcrules-mmx.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-mmx.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-mmx.lo `test -f 'orcrules-mmx.c' || echo '$(srcdir)/'`orcrules-mmx.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-mmx.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-mmx.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcrules-mmx.c' object='liborc_@ORC_MAJORMINOR@_la-orcrules-mmx.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-mmx.lo `test -f 'orcrules-mmx.c' || echo '$(srcdir)/'`orcrules-mmx.c
liborc_@ORC_MAJORMINOR@_la-orcprogram-mmx.lo: orcprogram-mmx.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcprogram-mmx.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-mmx.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-mmx.lo `test -f 'orcprogram-mmx.c' || echo '$(srcdir)/'`orcprogram-mmx.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-mmx.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-mmx.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcprogram-mmx.c' object='liborc_@ORC_MAJORMINOR@_la-orcprogram-mmx.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-mmx.lo `test -f 'orcprogram-mmx.c' || echo '$(srcdir)/'`orcprogram-mmx.c
liborc_@ORC_MAJORMINOR@_la-orcrules-altivec.lo: orcrules-altivec.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcrules-altivec.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-altivec.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-altivec.lo `test -f 'orcrules-altivec.c' || echo '$(srcdir)/'`orcrules-altivec.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-altivec.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-altivec.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcrules-altivec.c' object='liborc_@ORC_MAJORMINOR@_la-orcrules-altivec.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-altivec.lo `test -f 'orcrules-altivec.c' || echo '$(srcdir)/'`orcrules-altivec.c
liborc_@ORC_MAJORMINOR@_la-orcprogram-altivec.lo: orcprogram-altivec.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcprogram-altivec.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-altivec.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-altivec.lo `test -f 'orcprogram-altivec.c' || echo '$(srcdir)/'`orcprogram-altivec.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-altivec.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-altivec.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcprogram-altivec.c' object='liborc_@ORC_MAJORMINOR@_la-orcprogram-altivec.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-altivec.lo `test -f 'orcprogram-altivec.c' || echo '$(srcdir)/'`orcprogram-altivec.c
liborc_@ORC_MAJORMINOR@_la-orcpowerpc.lo: orcpowerpc.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcpowerpc.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcpowerpc.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcpowerpc.lo `test -f 'orcpowerpc.c' || echo '$(srcdir)/'`orcpowerpc.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcpowerpc.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcpowerpc.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcpowerpc.c' object='liborc_@ORC_MAJORMINOR@_la-orcpowerpc.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcpowerpc.lo `test -f 'orcpowerpc.c' || echo '$(srcdir)/'`orcpowerpc.c
liborc_@ORC_MAJORMINOR@_la-orcprogram-neon.lo: orcprogram-neon.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcprogram-neon.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-neon.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-neon.lo `test -f 'orcprogram-neon.c' || echo '$(srcdir)/'`orcprogram-neon.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-neon.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-neon.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcprogram-neon.c' object='liborc_@ORC_MAJORMINOR@_la-orcprogram-neon.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-neon.lo `test -f 'orcprogram-neon.c' || echo '$(srcdir)/'`orcprogram-neon.c
liborc_@ORC_MAJORMINOR@_la-orcrules-neon.lo: orcrules-neon.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcrules-neon.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-neon.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-neon.lo `test -f 'orcrules-neon.c' || echo '$(srcdir)/'`orcrules-neon.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-neon.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-neon.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcrules-neon.c' object='liborc_@ORC_MAJORMINOR@_la-orcrules-neon.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-neon.lo `test -f 'orcrules-neon.c' || echo '$(srcdir)/'`orcrules-neon.c
liborc_@ORC_MAJORMINOR@_la-orcarm.lo: orcarm.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcarm.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcarm.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcarm.lo `test -f 'orcarm.c' || echo '$(srcdir)/'`orcarm.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcarm.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcarm.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcarm.c' object='liborc_@ORC_MAJORMINOR@_la-orcarm.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcarm.lo `test -f 'orcarm.c' || echo '$(srcdir)/'`orcarm.c
liborc_@ORC_MAJORMINOR@_la-orcprogram-arm.lo: orcprogram-arm.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcprogram-arm.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-arm.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-arm.lo `test -f 'orcprogram-arm.c' || echo '$(srcdir)/'`orcprogram-arm.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-arm.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-arm.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcprogram-arm.c' object='liborc_@ORC_MAJORMINOR@_la-orcprogram-arm.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-arm.lo `test -f 'orcprogram-arm.c' || echo '$(srcdir)/'`orcprogram-arm.c
liborc_@ORC_MAJORMINOR@_la-orcrules-arm.lo: orcrules-arm.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcrules-arm.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-arm.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-arm.lo `test -f 'orcrules-arm.c' || echo '$(srcdir)/'`orcrules-arm.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-arm.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-arm.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcrules-arm.c' object='liborc_@ORC_MAJORMINOR@_la-orcrules-arm.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-arm.lo `test -f 'orcrules-arm.c' || echo '$(srcdir)/'`orcrules-arm.c
liborc_@ORC_MAJORMINOR@_la-orcprogram-c64x-c.lo: orcprogram-c64x-c.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcprogram-c64x-c.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-c64x-c.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-c64x-c.lo `test -f 'orcprogram-c64x-c.c' || echo '$(srcdir)/'`orcprogram-c64x-c.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-c64x-c.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-c64x-c.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcprogram-c64x-c.c' object='liborc_@ORC_MAJORMINOR@_la-orcprogram-c64x-c.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-c64x-c.lo `test -f 'orcprogram-c64x-c.c' || echo '$(srcdir)/'`orcprogram-c64x-c.c
liborc_@ORC_MAJORMINOR@_la-orcmips.lo: orcmips.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcmips.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcmips.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcmips.lo `test -f 'orcmips.c' || echo '$(srcdir)/'`orcmips.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcmips.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcmips.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcmips.c' object='liborc_@ORC_MAJORMINOR@_la-orcmips.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcmips.lo `test -f 'orcmips.c' || echo '$(srcdir)/'`orcmips.c
liborc_@ORC_MAJORMINOR@_la-orcprogram-mips.lo: orcprogram-mips.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcprogram-mips.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-mips.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-mips.lo `test -f 'orcprogram-mips.c' || echo '$(srcdir)/'`orcprogram-mips.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-mips.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcprogram-mips.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcprogram-mips.c' object='liborc_@ORC_MAJORMINOR@_la-orcprogram-mips.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcprogram-mips.lo `test -f 'orcprogram-mips.c' || echo '$(srcdir)/'`orcprogram-mips.c
liborc_@ORC_MAJORMINOR@_la-orcrules-mips.lo: orcrules-mips.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orcrules-mips.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-mips.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-mips.lo `test -f 'orcrules-mips.c' || echo '$(srcdir)/'`orcrules-mips.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-mips.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orcrules-mips.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orcrules-mips.c' object='liborc_@ORC_MAJORMINOR@_la-orcrules-mips.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orcrules-mips.lo `test -f 'orcrules-mips.c' || echo '$(srcdir)/'`orcrules-mips.c
liborc_@ORC_MAJORMINOR@_la-orccpu-x86.lo: orccpu-x86.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orccpu-x86.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-x86.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orccpu-x86.lo `test -f 'orccpu-x86.c' || echo '$(srcdir)/'`orccpu-x86.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-x86.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-x86.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orccpu-x86.c' object='liborc_@ORC_MAJORMINOR@_la-orccpu-x86.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orccpu-x86.lo `test -f 'orccpu-x86.c' || echo '$(srcdir)/'`orccpu-x86.c
liborc_@ORC_MAJORMINOR@_la-orccpu-powerpc.lo: orccpu-powerpc.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orccpu-powerpc.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-powerpc.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orccpu-powerpc.lo `test -f 'orccpu-powerpc.c' || echo '$(srcdir)/'`orccpu-powerpc.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-powerpc.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-powerpc.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orccpu-powerpc.c' object='liborc_@ORC_MAJORMINOR@_la-orccpu-powerpc.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orccpu-powerpc.lo `test -f 'orccpu-powerpc.c' || echo '$(srcdir)/'`orccpu-powerpc.c
liborc_@ORC_MAJORMINOR@_la-orccpu-arm.lo: orccpu-arm.c
@am__fastdepCC_TRUE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -MT liborc_@ORC_MAJORMINOR@_la-orccpu-arm.lo -MD -MP -MF $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-arm.Tpo -c -o liborc_@ORC_MAJORMINOR@_la-orccpu-arm.lo `test -f 'orccpu-arm.c' || echo '$(srcdir)/'`orccpu-arm.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-arm.Tpo $(DEPDIR)/liborc_@ORC_MAJORMINOR@_la-orccpu-arm.Plo
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='orccpu-arm.c' object='liborc_@ORC_MAJORMINOR@_la-orccpu-arm.lo' libtool=yes @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(liborc_@ORC_MAJORMINOR@_la_CFLAGS) $(CFLAGS) -c -o liborc_@ORC_MAJORMINOR@_la-orccpu-arm.lo `test -f 'orccpu-arm.c' || echo '$(srcdir)/'`orccpu-arm.c
generate_bytecode-generate-bytecode.o: generate-bytecode.c
@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(generate_bytecode_CFLAGS) $(CFLAGS) -MT generate_bytecode-generate-bytecode.o -MD -MP -MF $(DEPDIR)/generate_bytecode-generate-bytecode.Tpo -c -o generate_bytecode-generate-bytecode.o `test -f 'generate-bytecode.c' || echo '$(srcdir)/'`generate-bytecode.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/generate_bytecode-generate-bytecode.Tpo $(DEPDIR)/generate_bytecode-generate-bytecode.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='generate-bytecode.c' object='generate_bytecode-generate-bytecode.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(generate_bytecode_CFLAGS) $(CFLAGS) -c -o generate_bytecode-generate-bytecode.o `test -f 'generate-bytecode.c' || echo '$(srcdir)/'`generate-bytecode.c
generate_bytecode-generate-bytecode.obj: generate-bytecode.c
@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(generate_bytecode_CFLAGS) $(CFLAGS) -MT generate_bytecode-generate-bytecode.obj -MD -MP -MF $(DEPDIR)/generate_bytecode-generate-bytecode.Tpo -c -o generate_bytecode-generate-bytecode.obj `if test -f 'generate-bytecode.c'; then $(CYGPATH_W) 'generate-bytecode.c'; else $(CYGPATH_W) '$(srcdir)/generate-bytecode.c'; fi`
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/generate_bytecode-generate-bytecode.Tpo $(DEPDIR)/generate_bytecode-generate-bytecode.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='generate-bytecode.c' object='generate_bytecode-generate-bytecode.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(generate_bytecode_CFLAGS) $(CFLAGS) -c -o generate_bytecode-generate-bytecode.obj `if test -f 'generate-bytecode.c'; then $(CYGPATH_W) 'generate-bytecode.c'; else $(CYGPATH_W) '$(srcdir)/generate-bytecode.c'; fi`
generate_emulation-generate-emulation.o: generate-emulation.c
@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(generate_emulation_CFLAGS) $(CFLAGS) -MT generate_emulation-generate-emulation.o -MD -MP -MF $(DEPDIR)/generate_emulation-generate-emulation.Tpo -c -o generate_emulation-generate-emulation.o `test -f 'generate-emulation.c' || echo '$(srcdir)/'`generate-emulation.c
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/generate_emulation-generate-emulation.Tpo $(DEPDIR)/generate_emulation-generate-emulation.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='generate-emulation.c' object='generate_emulation-generate-emulation.o' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(generate_emulation_CFLAGS) $(CFLAGS) -c -o generate_emulation-generate-emulation.o `test -f 'generate-emulation.c' || echo '$(srcdir)/'`generate-emulation.c
generate_emulation-generate-emulation.obj: generate-emulation.c
@am__fastdepCC_TRUE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(generate_emulation_CFLAGS) $(CFLAGS) -MT generate_emulation-generate-emulation.obj -MD -MP -MF $(DEPDIR)/generate_emulation-generate-emulation.Tpo -c -o generate_emulation-generate-emulation.obj `if test -f 'generate-emulation.c'; then $(CYGPATH_W) 'generate-emulation.c'; else $(CYGPATH_W) '$(srcdir)/generate-emulation.c'; fi`
@am__fastdepCC_TRUE@ $(am__mv) $(DEPDIR)/generate_emulation-generate-emulation.Tpo $(DEPDIR)/generate_emulation-generate-emulation.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='generate-emulation.c' object='generate_emulation-generate-emulation.obj' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
@am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(generate_emulation_CFLAGS) $(CFLAGS) -c -o generate_emulation-generate-emulation.obj `if test -f 'generate-emulation.c'; then $(CYGPATH_W) 'generate-emulation.c'; else $(CYGPATH_W) '$(srcdir)/generate-emulation.c'; fi`
mostlyclean-libtool:
-rm -f *.lo
clean-libtool:
-rm -rf .libs _libs
install-pkgincludeHEADERS: $(pkginclude_HEADERS)
@$(NORMAL_INSTALL)
@list='$(pkginclude_HEADERS)'; test -n "$(pkgincludedir)" || list=; \
if test -n "$$list"; then \
echo " $(MKDIR_P) '$(DESTDIR)$(pkgincludedir)'"; \
$(MKDIR_P) "$(DESTDIR)$(pkgincludedir)" || exit 1; \
fi; \
for p in $$list; do \
if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
echo "$$d$$p"; \
done | $(am__base_list) | \
while read files; do \
echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(pkgincludedir)'"; \
$(INSTALL_HEADER) $$files "$(DESTDIR)$(pkgincludedir)" || exit $$?; \
done
uninstall-pkgincludeHEADERS:
@$(NORMAL_UNINSTALL)
@list='$(pkginclude_HEADERS)'; test -n "$(pkgincludedir)" || list=; \
files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
dir='$(DESTDIR)$(pkgincludedir)'; $(am__uninstall_files_from_dir)
ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
mkid -fID $$unique
tags: TAGS
TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
set x; \
here=`pwd`; \
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
shift; \
if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
test -n "$$unique" || unique=$$empty_fix; \
if test $$# -gt 0; then \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
"$$@" $$unique; \
else \
$(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
$$unique; \
fi; \
fi
ctags: CTAGS
CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
$(TAGS_FILES) $(LISP)
list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
unique=`for i in $$list; do \
if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
done | \
$(AWK) '{ files[$$0] = 1; nonempty = 1; } \
END { if (nonempty) { for (i in files) print i; }; }'`; \
test -z "$(CTAGS_ARGS)$$unique" \
|| $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
$$unique
GTAGS:
here=`$(am__cd) $(top_builddir) && pwd` \
&& $(am__cd) $(top_srcdir) \
&& gtags -i $(GTAGS_ARGS) "$$here"
distclean-tags:
-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
distdir: $(DISTFILES)
@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
list='$(DISTFILES)'; \
dist_files=`for file in $$list; do echo $$file; done | \
sed -e "s|^$$srcdirstrip/||;t" \
-e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
case $$dist_files in \
*/*) $(MKDIR_P) `echo "$$dist_files" | \
sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
sort -u` ;; \
esac; \
for file in $$dist_files; do \
if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
if test -d $$d/$$file; then \
dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
if test -d "$(distdir)/$$file"; then \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
fi; \
cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
else \
test -f "$(distdir)/$$file" \
|| cp -p $$d/$$file "$(distdir)/$$file" \
|| exit 1; \
fi; \
done
check-am: all-am
check: check-am
all-am: Makefile $(LTLIBRARIES) $(PROGRAMS) $(HEADERS)
installdirs:
for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(pkgincludedir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done
install: install-am
install-exec: install-exec-am
install-data: install-data-am
uninstall: uninstall-am
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
installcheck: installcheck-am
install-strip:
if test -z '$(STRIP)'; then \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
install; \
else \
$(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
"INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
fi
mostlyclean-generic:
clean-generic:
distclean-generic:
-test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
-test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
maintainer-clean-generic:
@echo "This command is intended for maintainers to use"
@echo "it deletes files that may require special tools to rebuild."
clean: clean-am
clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \
clean-noinstPROGRAMS mostlyclean-am
distclean: distclean-am
-rm -rf ./$(DEPDIR)
-rm -f Makefile
distclean-am: clean-am distclean-compile distclean-generic \
distclean-tags
dvi: dvi-am
dvi-am:
html: html-am
html-am:
info: info-am
info-am:
install-data-am: install-pkgincludeHEADERS
install-dvi: install-dvi-am
install-dvi-am:
install-exec-am: install-libLTLIBRARIES
install-html: install-html-am
install-html-am:
install-info: install-info-am
install-info-am:
install-man:
install-pdf: install-pdf-am
install-pdf-am:
install-ps: install-ps-am
install-ps-am:
installcheck-am:
maintainer-clean: maintainer-clean-am
-rm -rf ./$(DEPDIR)
-rm -f Makefile
maintainer-clean-am: distclean-am maintainer-clean-generic
mostlyclean: mostlyclean-am
mostlyclean-am: mostlyclean-compile mostlyclean-generic \
mostlyclean-libtool
pdf: pdf-am
pdf-am:
ps: ps-am
ps-am:
uninstall-am: uninstall-libLTLIBRARIES uninstall-pkgincludeHEADERS
.MAKE: install-am install-strip
.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \
clean-libLTLIBRARIES clean-libtool clean-noinstPROGRAMS ctags \
distclean distclean-compile distclean-generic \
distclean-libtool distclean-tags distdir dvi dvi-am html \
html-am info 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-libLTLIBRARIES install-man install-pdf \
install-pdf-am install-pkgincludeHEADERS install-ps \
install-ps-am install-strip installcheck installcheck-am \
installdirs maintainer-clean maintainer-clean-generic \
mostlyclean mostlyclean-compile mostlyclean-generic \
mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \
uninstall-am uninstall-libLTLIBRARIES \
uninstall-pkgincludeHEADERS
update: generate-emulation generate-bytecode
$(top_builddir)/tools/orcc$(EXEEXT) --implementation -o orcfunctions.c orcfunctions.orc
$(top_builddir)/tools/orcc$(EXEEXT) --header -o orcfunctions.h orcfunctions.orc
./generate-emulation$(EXEEXT) -o orcemulateopcodes.c
./generate-emulation$(EXEEXT) --header -o orcemulateopcodes.h
./generate-bytecode$(EXEEXT) --header -o orcbytecode.h
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
orc-0.4.18/orc/orcopcode.h 0000664 0001750 0001750 00000002604 12111024531 012213 0000000 0000000
#ifndef _ORC_OPCODE_H_
#define _ORC_OPCODE_H_
#include
#include
ORC_BEGIN_DECLS
typedef struct _OrcOpcodeSet OrcOpcodeSet;
typedef struct _OrcStaticOpcode OrcStaticOpcode;
/**
* OrcOpcodeSet:
*
* The OrcOpcodeSet structure has no public members
*/
struct _OrcOpcodeSet {
/*< private >*/
int opcode_major;
char prefix[8];
int n_opcodes;
OrcStaticOpcode *opcodes;
};
#define ORC_STATIC_OPCODE_ACCUMULATOR (1<<0)
#define ORC_STATIC_OPCODE_FLOAT_SRC (1<<1)
#define ORC_STATIC_OPCODE_FLOAT_DEST (1<<2)
#define ORC_STATIC_OPCODE_FLOAT (ORC_STATIC_OPCODE_FLOAT_SRC|ORC_STATIC_OPCODE_FLOAT_DEST)
#define ORC_STATIC_OPCODE_SCALAR (1<<3)
#define ORC_STATIC_OPCODE_LOAD (1<<4)
#define ORC_STATIC_OPCODE_STORE (1<<5)
#define ORC_STATIC_OPCODE_INVARIANT (1<<6)
#define ORC_STATIC_OPCODE_ITERATOR (1<<7)
struct _OrcStaticOpcode {
char name[16];
unsigned int flags;
int dest_size[ORC_STATIC_OPCODE_N_DEST];
int src_size[ORC_STATIC_OPCODE_N_SRC];
OrcOpcodeEmulateNFunc emulateN;
};
OrcStaticOpcode * orc_opcode_find_by_name (const char *name);
void orc_opcode_init (void);
OrcOpcodeSet *orc_opcode_set_get (const char *name);
OrcOpcodeSet *orc_opcode_set_get_nth (int opcode_major);
int orc_opcode_set_find_by_name (OrcOpcodeSet *opcode_set, const char *name);
int orc_opcode_register_static (OrcStaticOpcode *sopcode, char *prefix);
ORC_END_DECLS
#endif
orc-0.4.18/orc/orcrules-mips.c 0000664 0001750 0001750 00000062672 12126351204 013056 0000000 0000000 /*
Copyright 2002 - 2009 David A. Schleef
Copyright 2012 MIPS Technologies, Inc.
Author: Guillaume Emont
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
*/
#include
#include
#include
#define ORC_SW_MAX 32767
#define ORC_SW_MIN (-1-ORC_SW_MAX)
#define ORC_SB_MAX 127
#define ORC_SB_MIN (-1-ORC_SB_MAX)
#define ORC_UB_MAX 255
#define ORC_UB_MIN 0
void
mips_rule_load (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = compiler->vars[insn->src_args[0]].ptr_register;
int dest = compiler->vars[insn->dest_args[0]].alloc;
/* such that 2^total_shift is the amount to load at a time */
int total_shift = compiler->insn_shift + ORC_PTR_TO_INT (user);
int is_aligned = compiler->vars[insn->src_args[0]].is_aligned;
int offset;
if (compiler->vars[insn->src_args[0]].vartype == ORC_VAR_TYPE_CONST) {
ORC_PROGRAM_ERROR (compiler, "not implemented");
return;
}
ORC_DEBUG ("insn_shift=%d", compiler->insn_shift);
offset = compiler->unroll_index << total_shift;
switch (total_shift) {
case 0:
orc_mips_emit_lbu (compiler, dest, src, offset);
break;
case 1:
if (is_aligned) {
orc_mips_emit_lh (compiler, dest, src, offset);
} else {
orc_mips_emit_lbu (compiler, ORC_MIPS_T3, src, offset);
orc_mips_emit_lbu (compiler, dest, src, offset+1);
orc_mips_emit_append (compiler, dest, ORC_MIPS_T3, 8);
}
break;
case 2:
if (is_aligned) {
orc_mips_emit_lw (compiler, dest, src, offset);
} else {
/* note: the code below is little endian specific */
orc_mips_emit_lwr (compiler, dest, src, offset);
orc_mips_emit_lwl (compiler, dest, src, offset+3);
}
break;
default:
ORC_PROGRAM_ERROR(compiler, "Don't know how to handle that shift");
}
compiler->vars[insn->src_args[0]].update_type = 2;
}
void
mips_rule_store (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = compiler->vars[insn->src_args[0]].alloc;
int dest = compiler->vars[insn->dest_args[0]].ptr_register;
int total_shift = compiler->insn_shift + ORC_PTR_TO_INT (user);
int is_aligned = compiler->vars[insn->dest_args[0]].is_aligned;
int offset;
ORC_DEBUG ("insn_shift=%d", compiler->insn_shift);
offset = compiler->unroll_index << total_shift;
switch (total_shift) {
case 0:
orc_mips_emit_sb (compiler, src, dest, offset);
break;
case 1:
if (is_aligned) {
orc_mips_emit_sh (compiler, src, dest, offset);
} else {
/* Note: the code below is little endian specific */
orc_mips_emit_sb (compiler, src, dest, offset);
orc_mips_emit_srl (compiler, ORC_MIPS_T3, src, 8);
orc_mips_emit_sb (compiler, ORC_MIPS_T3, dest, offset+1);
}
break;
case 2:
if (is_aligned) {
orc_mips_emit_sw (compiler, src, dest, offset);
} else {
orc_mips_emit_swr (compiler, src, dest, offset);
orc_mips_emit_swl (compiler, src, dest, offset+3);
}
break;
default:
ORC_PROGRAM_ERROR(compiler, "Don't know how to handle that shift");
}
compiler->vars[insn->dest_args[0]].update_type = 2;
}
void
mips_rule_addl (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_addu (compiler, dest, src1, src2);
}
void
mips_rule_addw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_addu_ph (compiler, dest, src1, src2);
}
void
mips_rule_addb (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_addu_qb (compiler, dest, src1, src2);
}
void
mips_rule_subb (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_subu_qb (compiler, dest, src1, src2);
}
void
mips_rule_copyl (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_move (compiler, dest, src);
}
void
mips_rule_copyw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_move (compiler, dest, src);
}
void
mips_rule_copyb (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
if (dest != src)
orc_mips_emit_move (compiler, dest, src);
}
void
mips_rule_mulswl (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
OrcMipsRegister tmp0 = ORC_MIPS_T3;
OrcMipsRegister tmp1 = ORC_MIPS_T4;
orc_mips_emit_seh (compiler, tmp0, src1);
orc_mips_emit_seh (compiler, tmp1, src2);
orc_mips_emit_mul (compiler, dest, tmp0, tmp1);
}
void
mips_rule_mullw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_mul_ph (compiler, dest, src1, src2);
}
void
mips_rule_shrs (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
OrcVariable *src2 = compiler->vars + insn->src_args[1];
int dest = ORC_DEST_ARG (compiler, insn, 0);
if (src2->vartype == ORC_VAR_TYPE_CONST) {
orc_mips_emit_sra (compiler, dest, src1, src2->value.i);
} else {
ORC_COMPILER_ERROR(compiler, "rule only implemented for constants");
}
}
void
mips_rule_convssslw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
OrcMipsRegister tmp0 = ORC_MIPS_T3;
OrcMipsRegister tmp1 = ORC_MIPS_T4;
if (dest != src)
orc_mips_emit_move (compiler, dest, src);
orc_mips_emit_ori (compiler, tmp0, ORC_MIPS_ZERO, ORC_SW_MAX);
orc_mips_emit_slt (compiler, tmp1, tmp0, src);
orc_mips_emit_movn (compiler, dest, tmp0, tmp1);
orc_mips_emit_lui (compiler, tmp0, (ORC_SW_MIN >> 16) & 0xffff);
orc_mips_emit_ori (compiler, tmp0, tmp0, ORC_SW_MIN & 0xffff);
/* this still works if src == dest since in that case, its value is either
* the original src or ORC_SW_MAX, which works as well here */
orc_mips_emit_slt (compiler, tmp1, src, tmp0);
orc_mips_emit_movn (compiler, dest, tmp0, tmp1);
}
void
mips_rule_convssswb (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
OrcMipsRegister tmp = ORC_MIPS_T3;
orc_mips_emit_repl_ph (compiler, tmp, ORC_SB_MAX);
orc_mips_emit_cmp_lt_ph (compiler, tmp, src);
orc_mips_emit_pick_ph (compiler, dest, tmp, src);
orc_mips_emit_repl_ph (compiler, tmp, ORC_SB_MIN);
orc_mips_emit_cmp_lt_ph (compiler, dest, tmp);
orc_mips_emit_pick_ph (compiler, dest, tmp, dest);
if (compiler->insn_shift > 0)
orc_mips_emit_precr_qb_ph (compiler, dest, ORC_MIPS_ZERO, dest);
}
void
mips_rule_convsuswb (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
OrcMipsRegister tmp = ORC_MIPS_T3;
orc_mips_emit_repl_ph (compiler, tmp, ORC_UB_MAX);
orc_mips_emit_cmp_lt_ph (compiler, tmp, src);
orc_mips_emit_pick_ph (compiler, dest, tmp, src);
orc_mips_emit_cmp_lt_ph (compiler, dest, ORC_MIPS_ZERO);
orc_mips_emit_pick_ph (compiler, dest, ORC_MIPS_ZERO, dest);
if (compiler->insn_shift > 0)
orc_mips_emit_precr_qb_ph (compiler, dest, ORC_MIPS_ZERO, dest);
}
void
mips_rule_convsbw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
/* left shift 8 bits, then right shift signed 8 bits, so that the sign bit
* gets replicated in the upper 8 bits */
if (compiler->insn_shift > 0) {
orc_mips_emit_preceu_ph_qbr (compiler, dest, src);
orc_mips_emit_shll_ph (compiler, dest, dest, 8);
orc_mips_emit_shra_ph (compiler, dest, dest, 8);
} else {
orc_mips_emit_shll_ph (compiler, dest, src, 8);
orc_mips_emit_shra_ph (compiler, dest, dest, 8);
}
}
void
mips_rule_mergewl (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
if (src1 == src2) {
orc_mips_emit_replv_ph (compiler, dest, src1);
} else if (dest == src1) {
orc_mips_emit_sll (compiler, dest, dest, 16);
orc_mips_emit_prepend (compiler, dest, src2, 16);
} else {
if (dest != src2)
orc_mips_emit_move (compiler, dest, src2);
orc_mips_emit_append (compiler, dest, src1, 16);
}
}
void
mips_rule_mergebw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
OrcMipsRegister tmp0 = ORC_MIPS_T3;
OrcMipsRegister tmp1 = ORC_MIPS_T4;
if (compiler->insn_shift > 0) {
orc_mips_emit_preceu_ph_qbr (compiler, tmp0, src1);
orc_mips_emit_preceu_ph_qbr (compiler, tmp1, src2);
orc_mips_emit_shll_ph (compiler, tmp1, tmp1, 8);
orc_mips_emit_or (compiler, dest, tmp0, tmp1);
} else {
orc_mips_emit_shll_ph (compiler, tmp0, src2, 8);
orc_mips_emit_or (compiler, dest, tmp0, src1);
}
}
void
mips_rule_addssw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_addq_s_ph (compiler, dest, src1, src2);
}
void
mips_rule_subssw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_subq_s_ph (compiler, dest, src1, src2);
}
void
mips_rule_shrsw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
OrcVariable *src2 = compiler->vars + insn->src_args[1];
int dest = ORC_DEST_ARG (compiler, insn, 0);
if (src2->vartype == ORC_VAR_TYPE_CONST) {
orc_mips_emit_shra_ph (compiler, dest, src1, src2->value.i);
} else {
ORC_COMPILER_ERROR(compiler, "rule only implemented for constants");
}
}
void
mips_rule_shruw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
OrcVariable *src2 = compiler->vars + insn->src_args[1];
int dest = ORC_DEST_ARG (compiler, insn, 0);
if (src2->vartype == ORC_VAR_TYPE_CONST) {
orc_mips_emit_shrl_ph (compiler, dest, src1, src2->value.i);
} else {
ORC_COMPILER_ERROR(compiler, "rule only implemented for constants");
}
}
void
mips_rule_loadupib (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
OrcVariable *src = compiler->vars + insn->src_args[0];
OrcVariable *dest = compiler->vars + insn->dest_args[0];
OrcMipsRegister tmp0 = ORC_MIPS_T3;
OrcMipsRegister tmp1 = ORC_MIPS_T4;
OrcMipsRegister tmp2 = ORC_MIPS_T5;
int offset;
if (src->vartype != ORC_VAR_TYPE_SRC) {
ORC_PROGRAM_ERROR (compiler, "not implemented");
return;
}
switch (compiler->insn_shift) {
case 0:
orc_mips_emit_andi (compiler, tmp0, src->ptr_offset, 1);
/* We only do the first lb if offset is even */
orc_mips_emit_conditional_branch_with_offset (compiler,
ORC_MIPS_BEQ,
tmp0,
ORC_MIPS_ZERO,
16);
orc_mips_emit_lb (compiler, dest->alloc, src->ptr_register, 0);
orc_mips_emit_lb (compiler, tmp0, src->ptr_register, 1);
orc_mips_emit_adduh_r_qb (compiler, dest->alloc, dest->alloc, tmp0);
/* In the case where there is no insn_shift, src->ptr_register needs to be
* incremented only when ptr_offset is odd, _emit_loop() doesn't update it
* in that case, and therefore we do it here */
orc_mips_emit_addiu (compiler, src->ptr_register, src->ptr_register, 1);
orc_mips_emit_addiu (compiler, src->ptr_offset, src->ptr_offset, 1);
break;
case 2:
/*
lb tmp0, 0(src) # a
lb tmp1, 1(src) # b
lb dest, 2(src) # c
andi tmp2, ptr_offset, 1 # i&1
replv.qb tmp0, tmp0 # aaaa
replv.qb tmp1, tmp1 # bbbb
replv.qb dest, dest # cccc
packrl.ph tmp0, tmp1, tmp0 # bbaa
move tmp1, tmp0 # bbaa
prepend tmp1, dest, 8 # cbba
packrl.ph dest, dest, tmp1 # ccbb
# if tmp2
# tmp0 <- dest
movn tmp0, dest, tmp2 # if tmp2 ccbb else bbaa
adduh_r.qb dest, tmp0, tmp1 # (b,c)b(a,b)a | c(b,c)b(a,b)
*/
offset = compiler->unroll_index << (compiler->insn_shift - 1);
orc_mips_emit_lb (compiler, tmp0, src->ptr_register, offset);
orc_mips_emit_lb (compiler, tmp1, src->ptr_register, offset + 1);
orc_mips_emit_lb (compiler, dest->alloc, src->ptr_register, offset + 2);
orc_mips_emit_andi (compiler, tmp2, src->ptr_offset, 1);
orc_mips_emit_replv_qb (compiler, tmp0, tmp0);
orc_mips_emit_replv_qb (compiler, tmp1, tmp1);
orc_mips_emit_replv_qb (compiler, dest->alloc, dest->alloc);
orc_mips_emit_packrl_ph (compiler, tmp0, tmp1, tmp0);
orc_mips_emit_move (compiler, tmp1, tmp0);
orc_mips_emit_prepend (compiler, tmp1, dest->alloc, 8);
orc_mips_emit_packrl_ph (compiler, dest->alloc, dest->alloc, tmp1);
orc_mips_emit_movn (compiler, tmp0, dest->alloc, tmp2);
orc_mips_emit_adduh_r_qb (compiler, dest->alloc, tmp0, tmp1);
/* FIXME: should we remove that as we only use ptr_offset for parity? */
orc_mips_emit_addiu (compiler, src->ptr_offset, src->ptr_offset, 4);
break;
default:
ORC_PROGRAM_ERROR (compiler, "unimplemented");
}
src->update_type = 1;
}
#if 0
void
mips_rule_loadupdb (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
OrcVariable *src = compiler->vars + insn->src_args[0];
OrcVariable *dest = compiler->vars + insn->dest_args[0];
OrcMipsRegister tmp = ORC_MIPS_T3;
int offset;
if (src->vartype != ORC_VAR_TYPE_SRC) {
ORC_PROGRAM_ERROR (compiler, "not implemented");
return;
}
switch (compiler->insn_shift) {
case 0:
orc_mips_emit_andi (compiler, tmp, src->ptr_offset, 1);
orc_mips_emit_conditional_branch_with_offset (compiler,
ORC_MIPS_BEQ,
tmp,
ORC_MIPS_ZERO,
8);
/* this is always done: in branch delay slot*/
orc_mips_emit_lb (compiler, dest->alloc, src->ptr_register, 0);
/* In the case where there is no insn_shift, src->ptr_register needs to be
* incremented only when ptr_offset is odd, _emit_loop() doesn't update it
* in that case, and therefore we do it here */
orc_mips_emit_addiu (compiler, src->ptr_register, src->ptr_register, 1);
orc_mips_emit_append (compiler, dest->alloc, dest->alloc, 8);
orc_mips_emit_addiu (compiler, src->ptr_offset, src->ptr_offset, 1);
break;
case 2:
offset = compiler->unroll_index << (compiler->insn_shift - 1);
orc_mips_emit_lb (compiler, tmp, src->ptr_register, offset + 0);
orc_mips_emit_lb (compiler, dest->alloc, src->ptr_register, offset + 1);
orc_mips_emit_replv_qb (compiler, tmp, tmp);
orc_mips_emit_replv_qb (compiler, dest->alloc, dest->alloc);
orc_mips_emit_packrl_ph (compiler, dest->alloc, dest->alloc, tmp);
/* FIXME: should we remove that as we only use ptr_offset for parity? */
orc_mips_emit_addiu (compiler, src->ptr_offset, src->ptr_offset, 4);
break;
default:
ORC_PROGRAM_ERROR (compiler, "unimplemented");
}
src->update_type = 1;
}
#endif
void
mips_rule_loadp (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
OrcVariable *src = compiler->vars + insn->src_args[0];
OrcVariable *dest = compiler->vars + insn->dest_args[0];
int size = ORC_PTR_TO_INT (user);
if (src->vartype == ORC_VAR_TYPE_CONST) {
if (size == 1 || size == 2) {
orc_mips_emit_ori (compiler, dest->alloc, ORC_MIPS_ZERO, src->value.i);
if (size == 1)
orc_mips_emit_replv_qb (compiler, dest->alloc, dest->alloc);
else if (size == 2)
orc_mips_emit_replv_ph (compiler, dest->alloc, dest->alloc);
} else if (size == 4) {
orc_int16 high_bits;
high_bits = ((src->value.i >> 16) & 0xffff);
if (high_bits) {
orc_mips_emit_lui (compiler, dest->alloc, high_bits);
orc_mips_emit_ori (compiler, dest->alloc, dest->alloc, src->value.i & 0xffff);
} else {
orc_mips_emit_ori (compiler, dest->alloc, ORC_MIPS_ZERO, src->value.i & 0xffff);
}
} else {
ORC_PROGRAM_ERROR(compiler,"unimplemented");
}
} else {
if (size == 1) {
orc_mips_emit_lb (compiler, dest->alloc, compiler->exec_reg,
ORC_MIPS_EXECUTOR_OFFSET_PARAMS(insn->src_args[0]));
orc_mips_emit_replv_qb (compiler, dest->alloc, dest->alloc);
} else if (size == 2) {
orc_mips_emit_lh (compiler, dest->alloc, compiler->exec_reg,
ORC_MIPS_EXECUTOR_OFFSET_PARAMS(insn->src_args[0]));
orc_mips_emit_replv_ph (compiler, dest->alloc, dest->alloc);
} else if (size == 4) {
orc_mips_emit_lw (compiler, dest->alloc, compiler->exec_reg,
ORC_MIPS_EXECUTOR_OFFSET_PARAMS(insn->src_args[0]));
} else {
ORC_PROGRAM_ERROR(compiler,"unimplemented");
}
}
}
void
mips_rule_swapl (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_wsbh (compiler, dest, src);
orc_mips_emit_packrl_ph (compiler, dest, dest, dest);
}
void
mips_rule_swapw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_wsbh (compiler, dest, src);
}
void
mips_rule_avgub (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_adduh_r_qb (compiler, dest, src1, src2);
}
void
mips_rule_convubw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
if (compiler->insn_shift == 1)
orc_mips_emit_preceu_ph_qbr (compiler, dest, src);
}
void
mips_rule_subw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src1 = ORC_SRC_ARG (compiler, insn, 0);
int src2 = ORC_SRC_ARG (compiler, insn, 1);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_subq_ph (compiler, dest, src1, src2);
}
void
mips_rule_convwb (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
if (compiler->insn_shift >0)
orc_mips_emit_precr_qb_ph (compiler, dest, ORC_MIPS_ZERO, src);
}
void
mips_rule_select1wb (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_precrq_qb_ph (compiler, dest, ORC_MIPS_ZERO, src);
}
void
mips_rule_select0lw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
/* no op */
}
void
mips_rule_select1lw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
orc_mips_emit_srl (compiler, dest, src, 16);
}
void
mips_rule_splatbw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
OrcMipsRegister tmp = ORC_MIPS_T3;
orc_mips_emit_preceu_ph_qbr (compiler, tmp, src);
orc_mips_emit_shll_ph (compiler, dest, tmp, 8);
orc_mips_emit_or (compiler, dest, dest, tmp);
}
void
mips_rule_splitlw (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest1 = ORC_DEST_ARG (compiler, insn, 0);
int dest2 = ORC_DEST_ARG (compiler, insn, 1);
orc_mips_emit_srl (compiler, dest1, src, 16);
orc_mips_emit_andi (compiler, dest2, src, 0xffff);
}
void
mips_rule_splitwb (OrcCompiler *compiler, void *user, OrcInstruction *insn)
{
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest1 = ORC_DEST_ARG (compiler, insn, 0);
int dest2 = ORC_DEST_ARG (compiler, insn, 1);
orc_mips_emit_precrq_qb_ph (compiler, dest1, ORC_MIPS_ZERO, src);
orc_mips_emit_precr_qb_ph (compiler, dest2, ORC_MIPS_ZERO, src);
}
void
orc_compiler_orc_mips_register_rules (OrcTarget *target)
{
OrcRuleSet *rule_set;
rule_set = orc_rule_set_new (orc_opcode_set_get("sys"), target, 0);
orc_rule_register (rule_set, "loadl", mips_rule_load, (void *) 2);
orc_rule_register (rule_set, "loadw", mips_rule_load, (void *) 1);
orc_rule_register (rule_set, "loadb", mips_rule_load, (void *) 0);
orc_rule_register (rule_set, "loadpl", mips_rule_loadp, (void *) 4);
orc_rule_register (rule_set, "loadpw", mips_rule_loadp, (void *) 2);
orc_rule_register (rule_set, "loadpb", mips_rule_loadp, (void *) 1);
orc_rule_register (rule_set, "storel", mips_rule_store, (void *)2);
orc_rule_register (rule_set, "storew", mips_rule_store, (void *)1);
orc_rule_register (rule_set, "storeb", mips_rule_store, (void *)0);
orc_rule_register (rule_set, "addl", mips_rule_addl, NULL);
orc_rule_register (rule_set, "addw", mips_rule_addw, NULL);
orc_rule_register (rule_set, "addb", mips_rule_addb, NULL);
orc_rule_register (rule_set, "subb", mips_rule_subb, NULL);
orc_rule_register (rule_set, "copyl", mips_rule_copyl, NULL);
orc_rule_register (rule_set, "copyw", mips_rule_copyw, NULL);
orc_rule_register (rule_set, "copyb", mips_rule_copyb, NULL);
orc_rule_register (rule_set, "mulswl", mips_rule_mulswl, NULL);
orc_rule_register (rule_set, "mullw", mips_rule_mullw, NULL);
orc_rule_register (rule_set, "shrsl", mips_rule_shrs, NULL);
orc_rule_register (rule_set, "convssslw", mips_rule_convssslw, NULL);
orc_rule_register (rule_set, "convssswb", mips_rule_convssswb, NULL);
orc_rule_register (rule_set, "convsuswb", mips_rule_convsuswb, NULL);
orc_rule_register (rule_set, "convsbw", mips_rule_convsbw, NULL);
orc_rule_register (rule_set, "convubw", mips_rule_convubw, NULL);
orc_rule_register (rule_set, "convwb", mips_rule_convwb, NULL);
orc_rule_register (rule_set, "select0wb", mips_rule_convwb, NULL);
orc_rule_register (rule_set, "select1wb", mips_rule_select1wb, NULL);
orc_rule_register (rule_set, "select0lw", mips_rule_select0lw, NULL);
orc_rule_register (rule_set, "select1lw", mips_rule_select1lw, NULL);
orc_rule_register (rule_set, "mergewl", mips_rule_mergewl, NULL);
orc_rule_register (rule_set, "mergebw", mips_rule_mergebw, NULL);
orc_rule_register (rule_set, "splatbw", mips_rule_splatbw, NULL);
orc_rule_register (rule_set, "splitlw", mips_rule_splitlw, NULL);
orc_rule_register (rule_set, "splitwb", mips_rule_splitwb, NULL);
orc_rule_register (rule_set, "addssw", mips_rule_addssw, NULL);
orc_rule_register (rule_set, "subssw", mips_rule_subssw, NULL);
orc_rule_register (rule_set, "loadupib", mips_rule_loadupib, NULL);
/* orc_rule_register (rule_set, "loadupdb", mips_rule_loadupdb, NULL); */
orc_rule_register (rule_set, "shrsw", mips_rule_shrsw, NULL);
orc_rule_register (rule_set, "shruw", mips_rule_shruw, NULL);
orc_rule_register (rule_set, "swapl", mips_rule_swapl, NULL);
orc_rule_register (rule_set, "swapw", mips_rule_swapw, NULL);
orc_rule_register (rule_set, "avgub", mips_rule_avgub, NULL);
orc_rule_register (rule_set, "subw", mips_rule_subw, NULL);
}
orc-0.4.18/orc/orcprogram.c 0000664 0001750 0001750 00000060747 12111024531 012420 0000000 0000000
#include "config.h"
#include
#include
#include
#include
#include
#include
/**
* SECTION:orcprogram
* @title: OrcProgram
* @short_description: Creating and manipulating Orc programs
*/
/**
* orc_program_new:
*
* Create a new OrcProgram. The program should be freed using
* @orc_program_free().
*
* Returns: a pointer to an OrcProgram structure
*/
OrcProgram *
orc_program_new (void)
{
OrcProgram *p;
orc_init ();
p = malloc(sizeof(OrcProgram));
memset (p, 0, sizeof(OrcProgram));
p->name = malloc (40);
sprintf(p->name, "func_%p", p);
return p;
}
/**
* orc_program_new_dss:
* @size1: size of destination array members
* @size2: size of first source array members
* @size3: size of second source array members
*
* Create a new OrcProgram, with a destination named "d1" and
* two sources named "s1" and "s2".
*
* Returns: a pointer to an OrcProgram structure
*/
OrcProgram *
orc_program_new_dss (int size1, int size2, int size3)
{
OrcProgram *p;
p = orc_program_new ();
orc_program_add_destination (p, size1, "d1");
orc_program_add_source (p, size2, "s1");
orc_program_add_source (p, size3, "s2");
return p;
}
/**
* orc_program_new_ds:
* @size1: size of destination array members
* @size2: size of source array members
*
* Create a new OrcProgram, with a destination named "d1" and
* one source named "s1".
*
* Returns: a pointer to an OrcProgram structure
*/
OrcProgram *
orc_program_new_ds (int size1, int size2)
{
OrcProgram *p;
p = orc_program_new ();
orc_program_add_destination (p, size1, "d1");
orc_program_add_source (p, size2, "s1");
return p;
}
/**
* orc_program_new_ass:
* @size1: size of destination array members
* @size2: size of first source array members
* @size3: size of second source array members
*
* Create a new OrcProgram, with an accumulator named "a1" and
* two source named "s1" and "s2".
*
* Returns: a pointer to an OrcProgram structure
*/
OrcProgram *
orc_program_new_ass (int size1, int size2, int size3)
{
OrcProgram *p;
p = orc_program_new ();
orc_program_add_accumulator (p, size1, "a1");
orc_program_add_source (p, size2, "s1");
orc_program_add_source (p, size3, "s2");
return p;
}
/**
* orc_program_new_as:
* @size1: size of destination array members
* @size2: size of source array members
*
* Create a new OrcProgram, with an accumulator named "a1" and
* one source named "s1".
*
* Returns: a pointer to an OrcProgram structure
*/
OrcProgram *
orc_program_new_as (int size1, int size2)
{
OrcProgram *p;
p = orc_program_new ();
orc_program_add_accumulator (p, size1, "a1");
orc_program_add_source (p, size2, "s1");
return p;
}
OrcProgram *
orc_program_new_from_static_bytecode (const orc_uint8 *bytecode)
{
OrcProgram *p;
p = orc_program_new ();
orc_bytecode_parse_function (p, bytecode);
return p;
}
/**
* orc_program_free:
* @program: a pointer to an OrcProgram structure
*
* Frees an OrcProgram.
*/
void
orc_program_free (OrcProgram *program)
{
int i;
for(i=0;ivars[i].name) {
free (program->vars[i].name);
program->vars[i].name = NULL;
}
}
if (program->asm_code) {
free (program->asm_code);
program->asm_code = NULL;
}
if (program->name) {
free (program->name);
program->name = NULL;
}
if (program->error_msg) {
free (program->error_msg);
program->error_msg = NULL;
}
free (program);
}
/**
* orc_program_set_name:
* @program: a pointer to an OrcProgram structure
* @name: string to set the name to
*
* Sets the name of the program. The string is copied.
*/
void
orc_program_set_name (OrcProgram *program, const char *name)
{
if (program->name) {
free (program->name);
}
program->name = strdup (name);
}
/**
* orc_program_set_line:
* @program: a pointer to an OrcProgram structure
* @name: define where we are in the source
*
* Sets the current line of the program.
*/
void
orc_program_set_line (OrcProgram *program, unsigned int line)
{
program->current_line = line;
}
/**
* orc_program_set_2d:
* @program: a pointer to an OrcProgram structure
*
* Sets a flag on the program indicating that arrays are two
* dimensional. This causes the compiler to generate code for
* an OrcExec2D executor.
*/
void
orc_program_set_2d (OrcProgram *program)
{
program->is_2d = TRUE;
}
void orc_program_set_constant_n (OrcProgram *program, int n)
{
program->constant_n = n;
}
void orc_program_set_n_multiple (OrcProgram *program, int n)
{
program->n_multiple = n;
}
void orc_program_set_n_minimum (OrcProgram *program, int n)
{
program->n_minimum = n;
}
void orc_program_set_n_maximum (OrcProgram *program, int n)
{
program->n_maximum = n;
}
void orc_program_set_constant_m (OrcProgram *program, int m)
{
program->constant_m = m;
}
/**
* orc_program_set_backup_function:
* @program: a pointer to an OrcProgram structure
* @func: a function that performs the operations in the program
*
* Normally, if a program cannot be compiled for a particular CPU,
* Orc will emulate the function, which is typically very slow. This
* function allows the developer to provide a function that is called
* instead of resorting to emulation.
*/
void
orc_program_set_backup_function (OrcProgram *program, OrcExecutorFunc func)
{
program->backup_func = func;
if (program->code_exec == NULL) {
program->code_exec = func;
}
}
/**
* orc_program_get_name:
* @program: a pointer to an OrcProgram structure
*
* Gets the name of the program. The string is valid until the name
* is changed or the program is freed.
*
* Returns: a character string
*/
const char *
orc_program_get_name (OrcProgram *program)
{
return program->name;
}
/**
* orc_program_add_temporary:
* @program: a pointer to an OrcProgram structure
* @size: size of data values
* @name: name of variable
*
* Creates a new variable holding temporary values.
*
* Returns: the index of the new variable
*/
int
orc_program_add_temporary (OrcProgram *program, int size, const char *name)
{
int i = ORC_VAR_T1 + program->n_temp_vars;
program->vars[i].vartype = ORC_VAR_TYPE_TEMP;
program->vars[i].size = size;
program->vars[i].name = strdup(name);
program->n_temp_vars++;
return i;
}
/**
* orc_program_dup_temporary:
* @program: a pointer to an OrcProgram structure
* @var: variable to duplicate
* @j: index
*
* Internal function.
*
* Returns: the index of the new variable
*/
int
orc_program_dup_temporary (OrcProgram *program, int var, int j)
{
int i = ORC_VAR_T1 + program->n_temp_vars;
program->vars[i].vartype = ORC_VAR_TYPE_TEMP;
program->vars[i].size = program->vars[var].size;
program->vars[i].name = malloc (strlen(program->vars[var].name) + 10);
sprintf(program->vars[i].name, "%s.dup%d", program->vars[var].name, j);
program->n_temp_vars++;
return i;
}
/**
* orc_program_add_source_full:
* @program: a pointer to an OrcProgram structure
* @size: size of data values
* @name: name of variable
* @type_name: name of type, or NULL
* @alignment: alignment in bytes, or 0
*
* Creates a new variable representing a source array.
*
* Returns: the index of the new variable
*/
int
orc_program_add_source_full (OrcProgram *program, int size, const char *name,
const char *type_name, int alignment)
{
int i = ORC_VAR_S1 + program->n_src_vars;
program->vars[i].vartype = ORC_VAR_TYPE_SRC;
program->vars[i].size = size;
if (alignment == 0) alignment = size;
program->vars[i].alignment = alignment;
program->vars[i].name = strdup(name);
if (type_name) {
program->vars[i].type_name = strdup(type_name);
}
program->n_src_vars++;
return i;
}
/**
* orc_program_add_source:
* @program: a pointer to an OrcProgram structure
* @size: size of data values
* @name: name of variable
*
* Creates a new variable representing a source array.
*
* Returns: the index of the new variable
*/
int
orc_program_add_source (OrcProgram *program, int size, const char *name)
{
return orc_program_add_source_full (program, size, name, NULL, 0);
}
/**
* orc_program_add_destination_full:
* @program: a pointer to an OrcProgram structure
* @size: size of data values
* @name: name of variable
*
* Creates a new variable representing a destination array.
*
* Returns: the index of the new variable
*/
int
orc_program_add_destination_full (OrcProgram *program, int size, const char *name,
const char *type_name, int alignment)
{
int i = ORC_VAR_D1 + program->n_dest_vars;
program->vars[i].vartype = ORC_VAR_TYPE_DEST;
program->vars[i].size = size;
if (alignment == 0) alignment = size;
program->vars[i].alignment = alignment;
program->vars[i].name = strdup(name);
if (type_name) {
program->vars[i].type_name = strdup(type_name);
}
program->n_dest_vars++;
return i;
}
/**
* orc_program_add_destination:
* @program: a pointer to an OrcProgram structure
* @size: size of data values
* @name: name of variable
*
* Creates a new variable representing a destination array.
*
* Returns: the index of the new variable
*/
int
orc_program_add_destination (OrcProgram *program, int size, const char *name)
{
return orc_program_add_destination_full (program, size, name, NULL, 0);
}
/**
* orc_program_add_constant:
* @program: a pointer to an OrcProgram structure
* @size: size of data value
* @value: the value
* @name: name of variable
*
* Creates a new variable representing a constant value.
*
* Returns: the index of the new variable
*/
int
orc_program_add_constant (OrcProgram *program, int size, int value, const char *name)
{
int i;
i = ORC_VAR_C1 + program->n_const_vars;
program->vars[i].vartype = ORC_VAR_TYPE_CONST;
program->vars[i].size = size;
program->vars[i].value.i = value;
program->vars[i].name = strdup(name);
program->n_const_vars++;
return i;
}
int
orc_program_add_constant_int64 (OrcProgram *program, int size,
orc_int64 value, const char *name)
{
int i;
i = ORC_VAR_C1 + program->n_const_vars;
program->vars[i].vartype = ORC_VAR_TYPE_CONST;
program->vars[i].size = size;
program->vars[i].value.i = value;
program->vars[i].name = strdup(name);
program->n_const_vars++;
return i;
}
int
orc_program_add_constant_float (OrcProgram *program, int size,
float value, const char *name)
{
orc_union32 u;
u.f = value;
return orc_program_add_constant (program, size, u.i, name);
}
int
orc_program_add_constant_double (OrcProgram *program, int size,
double value, const char *name)
{
orc_union64 u;
u.f = value;
return orc_program_add_constant_int64 (program, size, u.i, name);
}
int
orc_program_add_constant_str (OrcProgram *program, int size,
const char *value, const char *name)
{
int i;
char *end;
orc_int64 val_i;
double val_d;
int j;
i = ORC_VAR_C1 + program->n_const_vars;
val_i = _strtoll (value, &end, 0);
if (end[0] == 0) {
program->vars[i].value.i = val_i;
if (size == 0)
size = 4;
} else if ((end[0] == 'l' || end[0] == 'L') && end[1] == 0) {
program->vars[i].value.i = val_i;
if (size == 0)
size = 8;
} else {
val_d = strtod (value, &end);
if (end[0] == 0) {
orc_union32 u;
u.f = val_d;
program->vars[i].value.i = u.i;
if (size == 0)
size = 4;
} else if ((end[0] == 'l' || end[0] == 'L') && end[1] == 0) {
program->vars[i].value.f = val_d;
if (size == 0)
size = 8;
} else {
return -1;
}
}
for(j=0;jn_const_vars;j++){
if (program->vars[ORC_VAR_C1 + j].value.i == program->vars[i].value.i) {
return ORC_VAR_C1 + j;
}
}
program->vars[i].vartype = ORC_VAR_TYPE_CONST;
program->vars[i].size = size;
program->vars[i].name = strdup(name);
program->n_const_vars++;
return i;
}
/**
* orc_program_add_parameter:
* @program: a pointer to an OrcProgram structure
* @size: size of data value
* @name: name of variable
*
* Creates a new variable representing a scalar parameter.
*
* Returns: the index of the new variable
*/
int
orc_program_add_parameter (OrcProgram *program, int size, const char *name)
{
int i = ORC_VAR_P1 + program->n_param_vars;
program->vars[i].vartype = ORC_VAR_TYPE_PARAM;
program->vars[i].param_type = ORC_PARAM_TYPE_INT;
program->vars[i].size = size;
program->vars[i].name = strdup(name);
program->n_param_vars++;
return i;
}
/**
* orc_program_add_parameter_float:
* @program: a pointer to an OrcProgram structure
* @size: size of data value
* @name: name of variable
*
* Creates a new variable representing a scalar parameter.
*
* Returns: the index of the new variable
*/
int
orc_program_add_parameter_float (OrcProgram *program, int size, const char *name)
{
int i = ORC_VAR_P1 + program->n_param_vars;
program->vars[i].vartype = ORC_VAR_TYPE_PARAM;
program->vars[i].param_type = ORC_PARAM_TYPE_FLOAT;
program->vars[i].size = size;
program->vars[i].name = strdup(name);
program->n_param_vars++;
return i;
}
int
orc_program_add_parameter_double (OrcProgram *program, int size,
const char *name)
{
int i = ORC_VAR_P1 + program->n_param_vars;
program->vars[i].vartype = ORC_VAR_TYPE_PARAM;
program->vars[i].param_type = ORC_PARAM_TYPE_DOUBLE;
program->vars[i].size = size;
program->vars[i].name = strdup(name);
program->n_param_vars++;
return i;
}
int
orc_program_add_parameter_int64 (OrcProgram *program, int size,
const char *name)
{
int i = ORC_VAR_P1 + program->n_param_vars;
program->vars[i].vartype = ORC_VAR_TYPE_PARAM;
program->vars[i].param_type = ORC_PARAM_TYPE_INT64;
program->vars[i].size = size;
program->vars[i].name = strdup(name);
program->n_param_vars++;
return i;
}
/**
* orc_program_add_accumulator:
* @program: a pointer to an OrcProgram structure
* @size: size of data value
* @name: name of variable
*
* Creates a new variable representing an accumulator.
*
* Returns: the index of the new variable
*/
int
orc_program_add_accumulator (OrcProgram *program, int size, const char *name)
{
int i = ORC_VAR_A1 + program->n_accum_vars;
program->vars[i].vartype = ORC_VAR_TYPE_ACCUMULATOR;
program->vars[i].size = size;
program->vars[i].name = strdup(name);
program->n_accum_vars++;
return i;
}
void
orc_program_set_type_name (OrcProgram *program, int var, const char *type_name)
{
program->vars[var].type_name = strdup(type_name);
}
void
orc_program_set_var_alignment (OrcProgram *program, int var, int alignment)
{
program->vars[var].alignment = alignment;
if (alignment >= 16) {
program->vars[var].is_aligned = TRUE;
}
}
void
orc_program_set_sampling_type (OrcProgram *program, int var,
int sampling_type)
{
/* This doesn't do anything yet */
}
/**
* orc_program_append_ds:
* @program: a pointer to an OrcProgram structure
* @name: name of instruction
* @arg0: index of first variable
* @arg1: index of second variable
*
* Appends an instruction to the program, with arguments @arg0 and
* @arg1. The instruction must take 2 operands.
*/
void
orc_program_append_ds (OrcProgram *program, const char *name, int arg0,
int arg1)
{
OrcInstruction *insn;
insn = program->insns + program->n_insns;
insn->opcode = orc_opcode_find_by_name (name);
if (!insn->opcode) {
ORC_ERROR ("unknown opcode: %s", name);
}
insn->dest_args[0] = arg0;
insn->src_args[0] = arg1;
program->n_insns++;
}
/**
* orc_program_append_ds:
* @program: a pointer to an OrcProgram structure
* @name: name of instruction
* @arg0: index of first variable
* @arg1: index of second variable
* @arg2: index of second variable
*
* Appends an instruction to the program, with arguments @arg0,
* @arg1, and @arg2. The instruction must take 3 operands.
*/
void
orc_program_append (OrcProgram *program, const char *name, int arg0,
int arg1, int arg2)
{
OrcInstruction *insn;
insn = program->insns + program->n_insns;
insn->opcode = orc_opcode_find_by_name (name);
if (!insn->opcode) {
ORC_ERROR ("unknown opcode: %s", name);
}
insn->dest_args[0] = arg0;
insn->src_args[0] = arg1;
insn->src_args[1] = arg2;
program->n_insns++;
}
/**
* orc_program_append_ds_2:
* @program: a pointer to an OrcProgram structure
* @name: name of instruction
* @arg0: index of first variable
* @arg1: index of second variable
* @arg2: index of third variable
* @arg3: index of fourth variable
*
* Appends an instruction to the program, with arguments @arg0,
* @arg1, @arg2, and @arg3.
*/
void
orc_program_append_2 (OrcProgram *program, const char *name, unsigned int flags,
int arg0, int arg1, int arg2, int arg3)
{
OrcInstruction *insn;
int args[4];
int i;
insn = program->insns + program->n_insns;
insn->opcode = orc_opcode_find_by_name (name);
if (!insn->opcode) {
ORC_ERROR ("unknown opcode: %s", name);
}
insn->flags = flags;
args[0] = arg0;
args[1] = arg1;
args[2] = arg2;
args[3] = arg3;
insn->flags = flags;
i = 0;
insn->dest_args[0] = args[i++];
if (insn->opcode) {
if (insn->opcode->dest_size[1] != 0) {
insn->dest_args[1] = args[i++];
}
if (insn->opcode->src_size[0] != 0) {
insn->src_args[0] = args[i++];
}
if (insn->opcode->src_size[1] != 0) {
insn->src_args[1] = args[i++];
}
if (insn->opcode->src_size[2] != 0) {
insn->src_args[2] = args[i++];
}
}
program->n_insns++;
}
/**
* orc_program_find_var_by_name:
* @program: a pointer to an OrcProgram structure
* @name: name of instruction
*
* Finds the variable with the name @name. If no variable with the
* given name exists in the program, -1 is returned.
*
* Returns: the index of the variable
*/
int
orc_program_find_var_by_name (OrcProgram *program, const char *name)
{
int i;
if (name == NULL) return -1;
for(i=0;ivars[i].name && strcmp (program->vars[i].name, name) == 0) {
return i;
}
}
return -1;
}
/**
* orc_program_append_str:
* @program: a pointer to an OrcProgram structure
* @name: name of instruction
* @arg0: name of first variable
* @arg1: name of second variable
* @arg2: name of third variable
*
* Appends an instruction to the program, with arguments @arg0,
* @arg1, and @arg2. The instruction must take 3 operands.
*/
void
orc_program_append_str (OrcProgram *program, const char *name,
const char *arg1, const char *arg2, const char *arg3)
{
OrcInstruction *insn;
insn = program->insns + program->n_insns;
insn->opcode = orc_opcode_find_by_name (name);
if (!insn->opcode) {
ORC_ERROR ("unknown opcode: %s", name);
}
insn->dest_args[0] = orc_program_find_var_by_name (program, arg1);
if (insn->opcode->dest_size[1] != 0) {
insn->dest_args[1] = orc_program_find_var_by_name (program, arg2);
insn->src_args[0] = orc_program_find_var_by_name (program, arg3);
} else {
insn->src_args[0] = orc_program_find_var_by_name (program, arg2);
insn->src_args[1] = orc_program_find_var_by_name (program, arg3);
}
program->n_insns++;
}
/**
* orc_program_append_str_2:
* @program: a pointer to an OrcProgram structure
* @name: name of instruction
* @flags: flags
* @arg0: name of first variable
* @arg1: name of second variable
* @arg2: name of third variable
* @arg3: name of fourth variable
*
* Appends an instruction to the program, with arguments @arg0,
* @arg1, @arg2, and @arg3.
*/
void
orc_program_append_str_2 (OrcProgram *program, const char *name,
unsigned int flags, const char *arg1, const char *arg2, const char *arg3,
const char *arg4)
{
OrcInstruction *insn;
int args[4];
int i;
insn = program->insns + program->n_insns;
insn->line = program->current_line;
insn->opcode = orc_opcode_find_by_name (name);
if (!insn->opcode) {
ORC_ERROR ("unknown opcode: %s at line %d", name, insn->line);
}
args[0] = orc_program_find_var_by_name (program, arg1);
args[1] = orc_program_find_var_by_name (program, arg2);
args[2] = orc_program_find_var_by_name (program, arg3);
args[3] = orc_program_find_var_by_name (program, arg4);
insn->flags = flags;
i = 0;
insn->dest_args[0] = args[i++];
if (insn->opcode) {
if (insn->opcode->dest_size[1] != 0) {
insn->dest_args[1] = args[i++];
}
if (insn->opcode->src_size[0] != 0) {
insn->src_args[0] = args[i++];
}
if (insn->opcode->src_size[1] != 0) {
insn->src_args[1] = args[i++];
}
if (insn->opcode->src_size[2] != 0) {
insn->src_args[2] = args[i++];
}
}
program->n_insns++;
}
/**
* orc_program_append_ds_str:
* @program: a pointer to an OrcProgram structure
* @name: name of instruction
* @arg0: name of first variable
* @arg1: name of second variable
*
* Appends an instruction to the program, with arguments @arg0 and
* @arg2. The instruction must take 2 operands.
*/
void
orc_program_append_ds_str (OrcProgram *program, const char *name,
const char *arg1, const char *arg2)
{
OrcInstruction *insn;
insn = program->insns + program->n_insns;
insn->opcode = orc_opcode_find_by_name (name);
if (!insn->opcode) {
ORC_ERROR ("unknown opcode: %s", name);
}
insn->dest_args[0] = orc_program_find_var_by_name (program, arg1);
insn->src_args[0] = orc_program_find_var_by_name (program, arg2);
program->n_insns++;
}
void
orc_program_append_dds_str (OrcProgram *program, const char *name,
const char *arg1, const char *arg2, const char *arg3)
{
OrcInstruction *insn;
insn = program->insns + program->n_insns;
insn->opcode = orc_opcode_find_by_name (name);
if (!insn->opcode) {
ORC_ERROR ("unknown opcode: %s", name);
}
insn->dest_args[0] = orc_program_find_var_by_name (program, arg1);
insn->dest_args[1] = orc_program_find_var_by_name (program, arg2);
insn->src_args[0] = orc_program_find_var_by_name (program, arg3);
program->n_insns++;
}
/**
* orc_program_get_asm_code:
* @program: a pointer to an OrcProgram structure
*
* Returns a character string containing the assembly code created
* by compiling the program. This string is valid until the program
* is compiled again or the program is freed.
*
* Returns: a character string
*/
const char *
orc_program_get_asm_code (OrcProgram *program)
{
return program->asm_code;
}
/**
* orc_program_get_error:
* @program: a pointer to an OrcProgram structure
*
* Returns a character string containing the error message from
* compilation. This string is valid until the program
* is compiled again or the program is freed.
*
* Returns: a character string
*/
const char *
orc_program_get_error (OrcProgram *program)
{
if (program->error_msg) return program->error_msg;
return "";
}
/**
* orc_program_get_max_array_size:
* @program: a pointer to an OrcProgram structure
*
* Returns the size of the largest array used in the program.
*
* Returns: the number of bytes
*/
int
orc_program_get_max_array_size (OrcProgram *program)
{
int i;
int max;
max = 0;
for(i=0;ivars[i].size) {
if (program->vars[i].vartype == ORC_VAR_TYPE_SRC ||
program->vars[i].vartype == ORC_VAR_TYPE_DEST) {
max = MAX(max, program->vars[i].size);
}
}
}
return max;
}
/**
* orc_program_get_max_accumulator_size:
* @program: a pointer to an OrcProgram structure
*
* Returns the size of the largest array used in the program.
*
* Returns: the number of bytes
*/
int
orc_program_get_max_accumulator_size (OrcProgram *program)
{
int i;
int max;
max = 0;
for(i=0;ivars[i].size) {
if (program->vars[i].vartype == ORC_VAR_TYPE_ACCUMULATOR) {
max = MAX(max, program->vars[i].size);
}
}
}
return max;
}
int _orc_data_cache_size_level1;
int _orc_data_cache_size_level2;
int _orc_data_cache_size_level3;
int _orc_cpu_family;
int _orc_cpu_model;
int _orc_cpu_stepping;
const char *_orc_cpu_name = "unknown";
void
orc_get_data_cache_sizes (int *level1, int *level2, int *level3)
{
if (level1) {
*level1 = _orc_data_cache_size_level1;
}
if (level2) {
*level2 = _orc_data_cache_size_level2;
}
if (level3) {
*level3 = _orc_data_cache_size_level3;
}
}
void
orc_get_cpu_family_model_stepping (int *family, int *model, int *stepping)
{
if (family) {
*family = _orc_cpu_family;
}
if (model) {
*model = _orc_cpu_model;
}
if (stepping) {
*stepping = _orc_cpu_stepping;
}
}
const char *
orc_get_cpu_name (void)
{
return _orc_cpu_name;
}
void
orc_program_reset (OrcProgram *program)
{
if (program->orccode) {
orc_code_free (program->orccode);
program->orccode = NULL;
}
if (program->asm_code) {
free(program->asm_code);
program->asm_code = NULL;
}
}
OrcCode *
orc_program_take_code (OrcProgram *program)
{
OrcCode *code = program->orccode;
program->orccode = NULL;
return code;
}
orc-0.4.18/orc/orcpowerpc.h 0000664 0001750 0001750 00000017120 12111024531 012420 0000000 0000000
#ifndef _ORC_POWERPC_H_
#define _ORC_POWERPC_H_
#include
ORC_BEGIN_DECLS
typedef enum {
ORC_TARGET_POWERPC_64BIT = (1<<0)
} OrcTargetPowerPCFlags;
#ifdef ORC_ENABLE_UNSTABLE_API
enum {
POWERPC_R0 = ORC_GP_REG_BASE,
POWERPC_R1,
POWERPC_R2,
POWERPC_R3,
POWERPC_R4,
POWERPC_R5,
POWERPC_R6,
POWERPC_R7,
POWERPC_R8,
POWERPC_R9,
POWERPC_R10,
POWERPC_R11,
POWERPC_R12,
POWERPC_R13,
POWERPC_R14,
POWERPC_R15,
POWERPC_R16,
POWERPC_R17,
POWERPC_R18,
POWERPC_R19,
POWERPC_R20,
POWERPC_R21,
POWERPC_R22,
POWERPC_R23,
POWERPC_R24,
POWERPC_R25,
POWERPC_R26,
POWERPC_R27,
POWERPC_R28,
POWERPC_R29,
POWERPC_R30,
POWERPC_R31,
POWERPC_V0 = ORC_VEC_REG_BASE,
POWERPC_V1,
POWERPC_V2,
POWERPC_V3,
POWERPC_V4,
POWERPC_V5,
POWERPC_V6,
POWERPC_V7,
POWERPC_V8,
POWERPC_V9,
POWERPC_V10,
POWERPC_V11,
POWERPC_V12,
POWERPC_V13,
POWERPC_V14,
POWERPC_V15,
POWERPC_V16,
POWERPC_V17,
POWERPC_V18,
POWERPC_V19,
POWERPC_V20,
POWERPC_V21,
POWERPC_V22,
POWERPC_V23,
POWERPC_V24,
POWERPC_V25,
POWERPC_V26,
POWERPC_V27,
POWERPC_V28,
POWERPC_V29,
POWERPC_V30,
POWERPC_V31
};
const char * powerpc_get_regname(int i);
int powerpc_regnum (int i);
void powerpc_emit(OrcCompiler *compiler, unsigned int insn);
void powerpc_emit_add (OrcCompiler *compiler, int regd, int rega, int regb);
void powerpc_emit_addi_rec (OrcCompiler *compiler, int regd, int rega, int imm);
void powerpc_emit_addi (OrcCompiler *compiler, int regd, int rega, int imm);
void powerpc_emit_lwz (OrcCompiler *compiler, int regd, int rega, int imm);
void powerpc_emit_stw (OrcCompiler *compiler, int regs, int rega, int offset);
void powerpc_emit_stwu (OrcCompiler *compiler, int regs, int rega, int offset);
void powerpc_emit_ld (OrcCompiler *compiler, int regd, int rega, int imm);
void powerpc_emit_std (OrcCompiler *compiler, int regs, int rega, int offset);
void powerpc_emit_stdu (OrcCompiler *compiler, int regs, int rega, int offset);
void powerpc_emit_ret (OrcCompiler *compiler);
void powerpc_emit_b (OrcCompiler *compiler, int label);
void powerpc_emit_beq (OrcCompiler *compiler, int label);
void powerpc_emit_bne (OrcCompiler *compiler, int label);
void powerpc_emit_label (OrcCompiler *compiler, int label);
void powerpc_add_fixup (OrcCompiler *compiler, int type, unsigned char *ptr, int label);
void powerpc_do_fixups (OrcCompiler *compiler);
void orc_powerpc_flush_cache (OrcCode *code);
void powerpc_emit_srawi (OrcCompiler *compiler, int regd, int rega, int shift,
int record);
void powerpc_emit_655510 (OrcCompiler *compiler, int major, int d, int a,
int b, int minor);
void powerpc_emit_D (OrcCompiler *compiler, const char *name,
unsigned int insn, int regd, int rega, int imm);
void powerpc_emit_X (OrcCompiler *compiler, unsigned int insn, int d, int a,
int b);
void powerpc_emit_VA (OrcCompiler *compiler, const char *name, unsigned int insn, int d, int a, int b,
int c);
void powerpc_emit_VA_acb (OrcCompiler *compiler, const char *name, unsigned int insn, int d, int a, int b,
int c);
void powerpc_emit_VX (OrcCompiler *compiler, unsigned int insn, int d, int a,
int b);
void powerpc_emit_VX_b (OrcCompiler *p, const char *name, unsigned int insn, int a);
void powerpc_emit_VX_db (OrcCompiler *p, const char *name, unsigned int insn, int d, int b);
void powerpc_emit_VX_dbi (OrcCompiler *p, const char *name, unsigned int insn, int d, int b, int imm);
void powerpc_emit_VXR (OrcCompiler *compiler, const char *name,
unsigned int insn, int d, int a, int b, int record);
void powerpc_emit_VX_2 (OrcCompiler *p, const char *name, unsigned int insn,
int d, int a, int b);
void powerpc_emit_VX_3 (OrcCompiler *p, const char *name, unsigned int insn,
int d, int a, int b, int c);
void powerpc_emit_VX_3_reg (OrcCompiler *p, const char *name, unsigned int insn,
int d, int a, int b, int c);
void powerpc_emit_VX_4 (OrcCompiler *p, const char *name, unsigned int insn,
int d, int a);
int powerpc_get_constant (OrcCompiler *p, int type, int value);
int powerpc_get_constant_full (OrcCompiler *p, int value0, int value1, int value2, int value3);
void powerpc_load_long_constant (OrcCompiler *p, int reg, orc_uint32 a,
orc_uint32 b, orc_uint32 c, orc_uint32 d);
/* instructions */
#define powerpc_emit_vand(p,a,b,c) powerpc_emit_VX_2 (p, "vand", 0x10000404, a, b, c)
#define powerpc_emit_vandc(p,a,b,c) powerpc_emit_VX_2 (p, "vandc", 0x10000444, a, b, c)
#define powerpc_emit_vor(p,a,b,c) powerpc_emit_VX_2 (p, "vor", 0x10000484, a, b, c)
#define powerpc_emit_vxor(p,a,b,c) powerpc_emit_VX_2 (p, "vxor", 0x100004c4, a, b, c)
#define powerpc_emit_vmulesb(p,a,b,c) powerpc_emit_VX_2 (p, "vmulesb", 0x10000308, a, b, c)
#define powerpc_emit_vmuleub(p,a,b,c) powerpc_emit_VX_2 (p, "vmuleub", 0x10000208, a, b, c)
#define powerpc_emit_vmulesh(p,a,b,c) powerpc_emit_VX_2 (p, "vmulesh", 0x10000348, a, b, c)
#define powerpc_emit_vmuleuh(p,a,b,c) powerpc_emit_VX_2 (p, "vmuleuh", 0x10000248, a, b, c)
#define powerpc_emit_vmrghb(p,a,b,c) powerpc_emit_VX_2 (p, "vmrghb", 0x1000000c, a, b, c)
#define powerpc_emit_vmrghh(p,a,b,c) powerpc_emit_VX_2 (p, "vmrghh", 0x1000004c, a, b, c)
#define powerpc_emit_vpkshss(p,a,b,c) powerpc_emit_VX_2 (p, "vpkshss", 0x1000018e, a, b, c)
#define powerpc_emit_vpkshus(p,a,b,c) powerpc_emit_VX_2 (p, "vpkshus", 0x1000010e, a, b, c)
#define powerpc_emit_vpkswss(p,a,b,c) powerpc_emit_VX_2 (p, "vpkswss", 0x100001ce, a, b, c)
#define powerpc_emit_vpkswus(p,a,b,c) powerpc_emit_VX_2 (p, "vpkswus", 0x1000014e, a, b, c)
#define powerpc_emit_vpkuhus(p,a,b,c) powerpc_emit_VX_2 (p, "vpkuhus", 0x1000008e, a, b, c)
#define powerpc_emit_vpkuhum(p,a,b,c) powerpc_emit_VX_2 (p, "vpkuhum", 0x1000000e, a, b, c)
#define powerpc_emit_vpkuwus(p,a,b,c) powerpc_emit_VX_2 (p, "vpkuwus", 0x100000ce, a, b, c)
#define powerpc_emit_vpkuwum(p,a,b,c) powerpc_emit_VX_2 (p, "vpkuwum", 0x1000004e, a, b, c)
#define powerpc_emit_vadduhm(p,a,b,c) powerpc_emit_VX_2 (p, "vadduhm", 0x10000040, a, b, c)
#define powerpc_emit_vadduwm(p,a,b,c) powerpc_emit_VX_2 (p, "vadduwm", 0x10000080, a, b, c)
#define powerpc_emit_vsububm(p,a,b,c) powerpc_emit_VX_2 (p, "vsububm", 0x10000400, a, b, c)
#define powerpc_emit_vsum4ubs(p,a,b,c) powerpc_emit_VX_2 (p, "vsum4ubs", 0x10000608, a, b, c)
#define powerpc_emit_vmaxub(p,a,b,c) powerpc_emit_VX_2 (p, "vmaxub", 0x10000002, a, b, c)
#define powerpc_emit_vmaxsb(p,a,b,c) powerpc_emit_VX_2 (p, "vmaxsb", 0x10000102, a, b, c)
#define powerpc_emit_vmaxsh(p,a,b,c) powerpc_emit_VX_2 (p, "vmaxsh", 0x10000142, a, b, c)
#define powerpc_emit_vmaxsw(p,a,b,c) powerpc_emit_VX_2 (p, "vmaxsw", 0x10000182, a, b, c)
#define powerpc_emit_vminub(p,a,b,c) powerpc_emit_VX_2 (p, "vminub", 0x10000202, a, b, c)
#define powerpc_emit_vminsb(p,a,b,c) powerpc_emit_VX_2 (p, "vminsb", 0x10000302, a, b, c)
#define powerpc_emit_vminsh(p,a,b,c) powerpc_emit_VX_2 (p, "vminsh", 0x10000342, a, b, c)
#define powerpc_emit_vminsw(p,a,b,c) powerpc_emit_VX_2 (p, "vminsw", 0x10000382, a, b, c)
#define powerpc_emit_vsldoi(p,a,b,c,d) powerpc_emit_VX_3 (p, "vsldoi", 0x1000002c | (d<<6), a, b, c, d)
#define powerpc_emit_vmladduhm(p,a,b,c,d) powerpc_emit_VA (p, "vmladduhm", 0x10000022, a, b, c, d)
#define powerpc_emit_vupkhsb(p,a,b) powerpc_emit_VX_4 (p, "vupkhsb", 0x1000020e, a, b)
#define powerpc_emit_vupkhsh(p,a,b) powerpc_emit_VX_4 (p, "vupkhsh", 0x1000024e, a, b)
#define powerpc_emit_vperm(p,a,b,c,d) powerpc_emit_VA (p, "vperm", 0x1000002b, a, b, c, d)
#endif
ORC_END_DECLS
#endif
orc-0.4.18/orc/orcemulateopcodes.h 0000644 0001750 0001750 00000026415 11643723636 014004 0000000 0000000
/* autogenerated by generate-emulation */
#ifndef _ORC_EMULATE_OPCODES_H_
#define _ORC_EMULATE_OPCODES_H_
void emulate_absb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addssb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addusb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_andb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_andnb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_avgsb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_avgub (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpeqb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpgtsb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_copyb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadoffb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadupdb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadupib (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadpb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_ldresnearb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_ldresnearl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_ldreslinb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_ldreslinl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_maxsb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_maxub (OrcOpcodeExecutor *ex, int i, int n);
void emulate_minsb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_minub (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mullb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulhsb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulhub (OrcOpcodeExecutor *ex, int i, int n);
void emulate_orb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shlb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shrsb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shrub (OrcOpcodeExecutor *ex, int i, int n);
void emulate_signb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_storeb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subssb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subusb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_xorb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_absw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addssw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addusw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_andw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_andnw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_avgsw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_avguw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpeqw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpgtsw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_copyw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_div255w (OrcOpcodeExecutor *ex, int i, int n);
void emulate_divluw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadoffw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadpw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_maxsw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_maxuw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_minsw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_minuw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mullw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulhsw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulhuw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_orw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shlw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shrsw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shruw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_signw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_storew (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subssw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subusw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_xorw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_absl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addssl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addusl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_andl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_andnl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_avgsl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_avgul (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpeql (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpgtsl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_copyl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadoffl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadpl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_maxsl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_maxul (OrcOpcodeExecutor *ex, int i, int n);
void emulate_minsl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_minul (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulll (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulhsl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulhul (OrcOpcodeExecutor *ex, int i, int n);
void emulate_orl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shll (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shrsl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shrul (OrcOpcodeExecutor *ex, int i, int n);
void emulate_signl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_storel (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subssl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subusl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_xorl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_loadpq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_storeq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_splatw3q (OrcOpcodeExecutor *ex, int i, int n);
void emulate_copyq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpeqq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpgtsq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_andq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_andnq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_orq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_xorq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shlq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shrsq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_shruq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convsbw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convubw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_splatbw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_splatbl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convswl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convuwl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convslq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convulq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convwb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convhwb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convssswb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convsuswb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convusswb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convuuswb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convlw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convhlw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convssslw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convsuslw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convusslw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convuuslw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convql (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convsssql (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convsusql (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convussql (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convuusql (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulsbw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulubw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulswl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_muluwl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulslq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mululq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_accw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_accl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_accsadubl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_swapw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_swapl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_swapwl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_swapq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_swaplq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_select0wb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_select1wb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_select0lw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_select1lw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_select0ql (OrcOpcodeExecutor *ex, int i, int n);
void emulate_select1ql (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mergelq (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mergewl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mergebw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_splitql (OrcOpcodeExecutor *ex, int i, int n);
void emulate_splitlw (OrcOpcodeExecutor *ex, int i, int n);
void emulate_splitwb (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addf (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subf (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mulf (OrcOpcodeExecutor *ex, int i, int n);
void emulate_divf (OrcOpcodeExecutor *ex, int i, int n);
void emulate_sqrtf (OrcOpcodeExecutor *ex, int i, int n);
void emulate_maxf (OrcOpcodeExecutor *ex, int i, int n);
void emulate_minf (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpeqf (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpltf (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmplef (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convfl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convlf (OrcOpcodeExecutor *ex, int i, int n);
void emulate_addd (OrcOpcodeExecutor *ex, int i, int n);
void emulate_subd (OrcOpcodeExecutor *ex, int i, int n);
void emulate_muld (OrcOpcodeExecutor *ex, int i, int n);
void emulate_divd (OrcOpcodeExecutor *ex, int i, int n);
void emulate_sqrtd (OrcOpcodeExecutor *ex, int i, int n);
void emulate_maxd (OrcOpcodeExecutor *ex, int i, int n);
void emulate_mind (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpeqd (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpltd (OrcOpcodeExecutor *ex, int i, int n);
void emulate_cmpled (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convdl (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convld (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convfd (OrcOpcodeExecutor *ex, int i, int n);
void emulate_convdf (OrcOpcodeExecutor *ex, int i, int n);
#endif
orc-0.4.18/orc/orcprogram-neon.c 0000664 0001750 0001750 00000065255 12071634360 013370 0000000 0000000
#include "config.h"
#include
#include
#include
#include
#include
#include
#include
#include
#include
#define SIZE 65536
void orc_neon_emit_loop (OrcCompiler *compiler, int unroll_index);
void orc_compiler_neon_register_rules (OrcTarget *target);
unsigned int orc_compiler_neon_get_default_flags (void);
void orc_compiler_neon_init (OrcCompiler *compiler);
void orc_compiler_neon_assemble (OrcCompiler *compiler);
void orc_compiler_rewrite_vars (OrcCompiler *compiler);
void orc_compiler_dump (OrcCompiler *compiler);
void orc_neon_save_accumulators (OrcCompiler *compiler);
void neon_add_strides (OrcCompiler *compiler);
void
orc_neon_emit_prologue (OrcCompiler *compiler)
{
unsigned int regs = 0;
int i;
orc_compiler_append_code(compiler,".global %s\n", compiler->program->name);
orc_compiler_append_code(compiler,"%s:\n", compiler->program->name);
for(i=0;i<16;i++){
if (compiler->used_regs[ORC_GP_REG_BASE + i] &&
compiler->save_regs[ORC_GP_REG_BASE + i]) {
regs |= (1<used_regs[ORC_GP_REG_BASE + i] &&
compiler->save_regs[ORC_GP_REG_BASE + i]) {
regs |= (1<valid_regs[i] = 1;
}
for(i=ORC_VEC_REG_BASE+0;ivalid_regs[i] = 1;
}
//compiler->valid_regs[ORC_ARM_SB] = 0;
compiler->valid_regs[ORC_ARM_IP] = 0;
compiler->valid_regs[ORC_ARM_SP] = 0;
compiler->valid_regs[ORC_ARM_LR] = 0;
compiler->valid_regs[ORC_ARM_PC] = 0;
for(i=4;i<12;i++) {
compiler->save_regs[ORC_GP_REG_BASE+i] = 1;
}
for(i=0;ialloc_regs[i] = 0;
compiler->used_regs[i] = 0;
}
compiler->exec_reg = ORC_ARM_A1;
compiler->valid_regs[compiler->exec_reg] = 0;
compiler->gp_tmpreg = ORC_ARM_A2;
compiler->valid_regs[compiler->gp_tmpreg] = 0;
compiler->tmpreg = ORC_VEC_REG_BASE + 0;
compiler->valid_regs[compiler->tmpreg] = 0;
compiler->tmpreg2 = ORC_VEC_REG_BASE + 2;
compiler->valid_regs[compiler->tmpreg2] = 0;
loop_shift = 0;
switch (compiler->max_var_size) {
case 1:
compiler->loop_shift = 4;
break;
case 2:
compiler->loop_shift = 3;
break;
case 4:
compiler->loop_shift = 2;
break;
case 8:
compiler->loop_shift = 1;
break;
default:
ORC_ERROR("unhandled max var size %d", compiler->max_var_size);
break;
}
switch (orc_program_get_max_array_size (compiler->program)) {
case 0:
case 1:
loop_shift = 4;
break;
case 2:
loop_shift = 3;
break;
case 4:
loop_shift = 2;
break;
case 8:
loop_shift = 1;
break;
default:
ORC_ERROR("unhandled max array size %d",
orc_program_get_max_array_size (compiler->program));
break;
}
if (loop_shift < compiler->loop_shift) {
compiler->loop_shift = loop_shift;
}
switch (orc_program_get_max_accumulator_size (compiler->program)) {
case 0:
loop_shift = 4;
break;
case 1:
loop_shift = 3;
break;
case 2:
loop_shift = 2;
break;
case 4:
loop_shift = 1;
break;
case 8:
loop_shift = 0;
break;
default:
ORC_ERROR("unhandled max accumulator size %d",
orc_program_get_max_accumulator_size (compiler->program));
break;
}
if (loop_shift < compiler->loop_shift) {
compiler->loop_shift = loop_shift;
}
/* Unrolling isn't helpful until neon gets an instruction
* scheduler. This decreases the raw amount of code generated
* while still keeping the feature active. */
if (compiler->n_insns < 5) {
compiler->unroll_shift = 0;
}
if (0) {
compiler->need_mask_regs = TRUE;
}
}
void
orc_neon_load_constants_outer (OrcCompiler *compiler)
{
int i;
for(i=0;ivars[i].name == NULL) continue;
switch (compiler->vars[i].vartype) {
case ORC_VAR_TYPE_CONST:
break;
case ORC_VAR_TYPE_PARAM:
break;
case ORC_VAR_TYPE_SRC:
case ORC_VAR_TYPE_DEST:
break;
case ORC_VAR_TYPE_ACCUMULATOR:
orc_neon_emit_loadil (compiler, compiler->vars[i].alloc, 0);
break;
case ORC_VAR_TYPE_TEMP:
break;
default:
ORC_PROGRAM_ERROR(compiler,"bad vartype");
break;
}
}
for(i=0;in_insns;i++){
OrcInstruction *insn = compiler->insns + i;
OrcStaticOpcode *opcode = insn->opcode;
OrcRule *rule;
if (!(insn->flags & ORC_INSN_FLAG_INVARIANT)) continue;
ORC_ASM_CODE(compiler,"# %d: %s\n", i, insn->opcode->name);
compiler->insn_shift = compiler->loop_shift;
if (insn->flags & ORC_INSTRUCTION_FLAG_X2) {
compiler->insn_shift += 1;
}
if (insn->flags & ORC_INSTRUCTION_FLAG_X4) {
compiler->insn_shift += 2;
}
rule = insn->rule;
if (rule && rule->emit) {
rule->emit (compiler, rule->emit_user, insn);
} else {
ORC_COMPILER_ERROR(compiler,"No rule for: %s", opcode->name);
}
}
}
void
orc_neon_load_constants_inner (OrcCompiler *compiler)
{
int i;
for(i=0;ivars[i].name == NULL) continue;
switch (compiler->vars[i].vartype) {
case ORC_VAR_TYPE_CONST:
break;
case ORC_VAR_TYPE_PARAM:
break;
case ORC_VAR_TYPE_SRC:
case ORC_VAR_TYPE_DEST:
orc_arm_emit_load_reg (compiler,
compiler->vars[i].ptr_register,
compiler->exec_reg, ORC_STRUCT_OFFSET(OrcExecutor, arrays[i]));
break;
case ORC_VAR_TYPE_ACCUMULATOR:
break;
case ORC_VAR_TYPE_TEMP:
break;
default:
ORC_PROGRAM_ERROR(compiler,"bad vartype");
break;
}
}
}
#if 0
void
orc_neon_emit_load_src (OrcCompiler *compiler, OrcVariable *var, int unroll_index)
{
int ptr_reg;
int update;
if (var->ptr_register == 0) {
int i;
i = var - compiler->vars;
//arm_emit_mov_memoffset_reg (compiler, arm_ptr_size,
// (int)ORC_STRUCT_OFFSET(OrcExecutor, arrays[i]),
// p->exec_reg, X86_ECX);
ptr_reg = ORC_ARM_PC;
} else {
ptr_reg = var->ptr_register;
}
if (var->vartype == ORC_VAR_TYPE_DEST) {
update = FALSE;
} else {
update = TRUE;
}
switch (var->size) {
case 1:
orc_neon_loadb (compiler, var, update);
break;
case 2:
orc_neon_loadw (compiler, var, update);
break;
case 4:
orc_neon_loadl (compiler, var, update);
break;
case 8:
orc_neon_loadq (compiler, var->alloc, ptr_reg, update, var->is_aligned);
break;
default:
ORC_ERROR("bad size");
}
if (unroll_index == 0) {
switch (compiler->size_region) {
case 0:
case 1:
orc_neon_preload (compiler, var, FALSE, 208);
break;
case 2:
case 3:
orc_neon_preload (compiler, var, FALSE, 208);
break;
}
}
}
void
orc_neon_emit_store_dest (OrcCompiler *compiler, OrcVariable *var)
{
int ptr_reg;
if (var->ptr_register == 0) {
//arm_emit_mov_memoffset_reg (compiler, arm_ptr_size,
// var->ptr_offset, p->exec_reg, X86_ECX);
ptr_reg = ORC_ARM_PC;
} else {
ptr_reg = var->ptr_register;
}
switch (var->size) {
case 1:
orc_neon_storeb (compiler, ptr_reg, TRUE, var->alloc, var->is_aligned);
break;
case 2:
orc_neon_storew (compiler, ptr_reg, TRUE, var->alloc, var->is_aligned);
break;
case 4:
orc_neon_storel (compiler, ptr_reg, TRUE, var->alloc, var->is_aligned);
break;
case 8:
orc_neon_storeq (compiler, ptr_reg, TRUE, var->alloc, var->is_aligned);
break;
default:
ORC_ERROR("bad size");
}
switch (compiler->size_region) {
case 0:
break;
case 1:
/* assume hot cache, see below */
break;
case 2:
/* This is only useful for cold cache and for memset-like operations,
which isn't the usual case, thus it's disabled. */
#if 0
orc_neon_preload (compiler, var, FALSE, 208);
#endif
break;
case 3:
/* none */
break;
}
}
#endif
static int
get_shift (int size)
{
switch (size) {
case 1:
return 0;
case 2:
return 1;
case 4:
return 2;
case 8:
return 3;
default:
ORC_ERROR("bad size %d", size);
}
return -1;
}
static int
get_align_var (OrcCompiler *compiler)
{
if (compiler->vars[ORC_VAR_D1].size) return ORC_VAR_D1;
if (compiler->vars[ORC_VAR_S1].size) return ORC_VAR_S1;
ORC_PROGRAM_ERROR(compiler, "could not find alignment variable");
return -1;
}
enum {
LABEL_ONE_REGION = 1,
LABEL_ONE_REGION_AFTER,
LABEL_REGION0_LOOP,
LABEL_REGION0_SKIP,
LABEL_REGION1_LOOP,
LABEL_REGION1_SKIP,
LABEL_REGION2_LOOP_SMALL,
LABEL_REGION2_LOOP_MEDIUM,
LABEL_REGION2_LOOP_LARGE,
LABEL_REGION2_SMALL,
LABEL_REGION2_MEDIUM,
LABEL_REGION2_SKIP,
LABEL_REGION3_LOOP,
LABEL_REGION3_SKIP,
LABEL_OUTER_LOOP,
LABEL_OUTER_LOOP_SKIP,
LABEL_L1L2_AFTER,
};
void
orc_compiler_neon_assemble (OrcCompiler *compiler)
{
int align_var;
int align_shift;
int var_size_shift;
int i;
align_var = get_align_var (compiler);
if (compiler->error) return;
var_size_shift = get_shift (compiler->vars[align_var].size);
align_shift = 4;
compiler->vars[align_var].is_aligned = FALSE;
orc_neon_emit_prologue (compiler);
orc_neon_load_constants_outer (compiler);
if (compiler->program->is_2d) {
if (compiler->program->constant_m > 0) {
orc_arm_emit_load_imm (compiler, ORC_ARM_A3, compiler->program->constant_m);
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,params[ORC_VAR_A2]));
} else {
orc_arm_emit_load_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor, params[ORC_VAR_A1]));
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,params[ORC_VAR_A2]));
}
orc_arm_emit_label (compiler, LABEL_OUTER_LOOP);
}
#define ORC_NEON_ALIGNED_DEST_CUTOFF 64
if (compiler->loop_shift > 0 && compiler->n_insns < 5) {
orc_arm_emit_load_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,n));
orc_arm_emit_cmp_imm (compiler, ORC_ARM_A3, ORC_NEON_ALIGNED_DEST_CUTOFF);
orc_arm_emit_branch (compiler, ORC_ARM_COND_GT, LABEL_REGION0_SKIP);
orc_arm_emit_asr_imm (compiler, ORC_ARM_A2, ORC_ARM_A3,
compiler->loop_shift);
orc_arm_emit_store_reg (compiler, ORC_ARM_A2, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter2));
orc_arm_emit_and_imm (compiler, ORC_ARM_A3, ORC_ARM_A3,
(1<loop_shift)-1);
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter3));
orc_neon_load_constants_inner (compiler);
orc_arm_emit_load_reg (compiler, ORC_ARM_IP, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter2));
orc_arm_emit_cmp_imm (compiler, ORC_ARM_IP, 0);
orc_arm_emit_branch (compiler, ORC_ARM_COND_EQ, LABEL_REGION2_SKIP);
compiler->size_region = 0;
orc_arm_emit_label (compiler, LABEL_REGION0_LOOP);
orc_arm_emit_sub_imm (compiler, ORC_ARM_IP, ORC_ARM_IP, 1, TRUE);
orc_neon_emit_loop (compiler, -1);
orc_arm_emit_branch (compiler, ORC_ARM_COND_NE, LABEL_REGION0_LOOP);
orc_arm_emit_branch (compiler, ORC_ARM_COND_AL, LABEL_REGION2_SKIP);
orc_arm_emit_label (compiler, LABEL_REGION0_SKIP);
}
if (compiler->loop_shift > 0) {
orc_arm_emit_load_imm (compiler, ORC_ARM_IP, 1<exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,arrays[align_var]));
orc_arm_emit_sub (compiler, ORC_ARM_IP, ORC_ARM_IP, ORC_ARM_A2);
orc_arm_emit_and_imm (compiler, ORC_ARM_IP, ORC_ARM_IP,
(1< 0) {
orc_arm_emit_asr_imm (compiler, ORC_ARM_IP, ORC_ARM_IP, var_size_shift);
}
orc_arm_emit_load_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,n));
orc_arm_emit_cmp (compiler, ORC_ARM_A3, ORC_ARM_IP);
orc_arm_emit_branch (compiler, ORC_ARM_COND_LE, LABEL_ONE_REGION);
orc_arm_emit_store_reg (compiler, ORC_ARM_IP, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter1));
orc_arm_emit_sub (compiler, ORC_ARM_A2, ORC_ARM_A3, ORC_ARM_IP);
orc_arm_emit_asr_imm (compiler, ORC_ARM_A3, ORC_ARM_A2,
compiler->loop_shift + compiler->unroll_shift);
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter2));
orc_arm_emit_and_imm (compiler, ORC_ARM_A3, ORC_ARM_A2,
(1<<(compiler->loop_shift + compiler->unroll_shift))-1);
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter3));
orc_arm_emit_branch (compiler, ORC_ARM_COND_AL, LABEL_ONE_REGION_AFTER);
orc_arm_emit_label (compiler, LABEL_ONE_REGION);
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter1));
orc_arm_emit_load_imm (compiler, ORC_ARM_A3, 0);
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter2));
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter3));
orc_arm_emit_label (compiler, LABEL_ONE_REGION_AFTER);
}
orc_neon_load_constants_inner (compiler);
if (compiler->loop_shift > 0) {
int save_loop_shift = compiler->loop_shift;
compiler->loop_shift = 0;
orc_arm_emit_load_reg (compiler, ORC_ARM_IP, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter1));
orc_arm_emit_cmp_imm (compiler, ORC_ARM_IP, 0);
orc_arm_emit_branch (compiler, ORC_ARM_COND_EQ, LABEL_REGION1_SKIP);
orc_arm_emit_label (compiler, LABEL_REGION1_LOOP);
orc_arm_emit_sub_imm (compiler, ORC_ARM_IP, ORC_ARM_IP, 1, TRUE);
orc_neon_emit_loop (compiler, -1);
orc_arm_emit_branch (compiler, ORC_ARM_COND_NE, LABEL_REGION1_LOOP);
orc_arm_emit_label (compiler, LABEL_REGION1_SKIP);
compiler->loop_shift = save_loop_shift;
compiler->vars[align_var].is_aligned = TRUE;
}
if (compiler->loop_shift > 0) {
orc_arm_emit_load_reg (compiler, ORC_ARM_IP, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter2));
} else {
orc_arm_emit_load_reg (compiler, ORC_ARM_IP, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,n));
}
orc_arm_emit_cmp_imm (compiler, ORC_ARM_IP, 0);
orc_arm_emit_branch (compiler, ORC_ARM_COND_EQ, LABEL_REGION2_SKIP);
orc_arm_emit_asr_imm (compiler, compiler->gp_tmpreg, ORC_ARM_IP,
17 + var_size_shift - compiler->loop_shift - compiler->unroll_shift);
orc_arm_emit_cmp_imm (compiler, compiler->gp_tmpreg, 0);
orc_arm_emit_branch (compiler, ORC_ARM_COND_EQ, LABEL_REGION2_MEDIUM);
/* N is larger than L2 cache size */
compiler->size_region = 3;
orc_arm_emit_label (compiler, LABEL_REGION2_LOOP_LARGE);
orc_arm_emit_sub_imm (compiler, ORC_ARM_IP, ORC_ARM_IP, 1, TRUE);
for(i=0;i<(1<unroll_shift);i++){
orc_neon_emit_loop (compiler, i);
}
orc_arm_emit_branch (compiler, ORC_ARM_COND_NE, LABEL_REGION2_LOOP_LARGE);
orc_arm_emit_branch (compiler, ORC_ARM_COND_AL, LABEL_REGION2_SKIP);
orc_arm_emit_label (compiler, LABEL_REGION2_MEDIUM);
orc_arm_emit_asr_imm (compiler, compiler->gp_tmpreg, ORC_ARM_IP,
13 + var_size_shift - compiler->loop_shift - compiler->unroll_shift);
orc_arm_emit_cmp_imm (compiler, compiler->gp_tmpreg, 0);
orc_arm_emit_branch (compiler, ORC_ARM_COND_EQ, LABEL_REGION2_SMALL);
/* N is smaller than L2 cache size */
compiler->size_region = 2;
orc_arm_emit_label (compiler, LABEL_REGION2_LOOP_MEDIUM);
orc_arm_emit_sub_imm (compiler, ORC_ARM_IP, ORC_ARM_IP, 1, TRUE);
for(i=0;i<(1<unroll_shift);i++){
orc_neon_emit_loop (compiler, i);
}
orc_arm_emit_branch (compiler, ORC_ARM_COND_NE, LABEL_REGION2_LOOP_MEDIUM);
orc_arm_emit_branch (compiler, ORC_ARM_COND_AL, LABEL_REGION2_SKIP);
orc_arm_emit_label (compiler, LABEL_REGION2_SMALL);
/* N is smaller than L2 cache size */
compiler->size_region = 1;
orc_arm_emit_label (compiler, LABEL_REGION2_LOOP_SMALL);
orc_arm_emit_sub_imm (compiler, ORC_ARM_IP, ORC_ARM_IP, 1, TRUE);
for(i=0;i<(1<unroll_shift);i++){
orc_neon_emit_loop (compiler, i);
}
orc_arm_emit_branch (compiler, ORC_ARM_COND_NE, LABEL_REGION2_LOOP_SMALL);
orc_arm_emit_label (compiler, LABEL_REGION2_SKIP);
if (compiler->loop_shift > 0) {
int save_loop_shift = compiler->loop_shift;
compiler->loop_shift = 0;
compiler->vars[align_var].is_aligned = FALSE;
orc_arm_emit_load_reg (compiler, ORC_ARM_IP, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,counter3));
orc_arm_emit_cmp_imm (compiler, ORC_ARM_IP, 0);
orc_arm_emit_branch (compiler, ORC_ARM_COND_EQ, LABEL_REGION3_SKIP);
orc_arm_emit_label (compiler, LABEL_REGION3_LOOP);
orc_arm_emit_sub_imm (compiler, ORC_ARM_IP, ORC_ARM_IP, 1, TRUE);
orc_neon_emit_loop (compiler, -1);
orc_arm_emit_branch (compiler, ORC_ARM_COND_NE, LABEL_REGION3_LOOP);
orc_arm_emit_label (compiler, LABEL_REGION3_SKIP);
compiler->loop_shift = save_loop_shift;
}
if (compiler->program->is_2d) {
neon_add_strides (compiler);
orc_arm_emit_load_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor, params[ORC_VAR_A2]));
orc_arm_emit_sub_imm (compiler, ORC_ARM_A3, ORC_ARM_A3, 1, TRUE);
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,params[ORC_VAR_A2]));
orc_arm_emit_branch (compiler, ORC_ARM_COND_NE, LABEL_OUTER_LOOP);
}
orc_neon_save_accumulators (compiler);
orc_neon_emit_epilogue (compiler);
orc_arm_emit_align (compiler, 4);
orc_arm_emit_label (compiler, 20);
orc_arm_emit_data (compiler, 0x07060706);
orc_arm_emit_data (compiler, 0x07060706);
orc_arm_emit_data (compiler, 0x0f0e0f0e);
orc_arm_emit_data (compiler, 0x0f0e0f0e);
orc_arm_do_fixups (compiler);
}
void
orc_neon_emit_loop (OrcCompiler *compiler, int unroll_index)
{
int j;
int k;
OrcInstruction *insn;
OrcStaticOpcode *opcode;
OrcRule *rule;
orc_compiler_append_code(compiler,"# LOOP shift %d\n", compiler->loop_shift);
for(j=0;jn_insns;j++){
compiler->insn_index = j;
insn = compiler->insns + j;
opcode = insn->opcode;
if (insn->flags & ORC_INSN_FLAG_INVARIANT) continue;
orc_compiler_append_code(compiler,"# %d: %s", j, insn->opcode->name);
/* set up args */
#if 0
for(k=0;kn_src + opcode->n_dest;k++){
args[k] = compiler->vars + insn->args[k];
orc_compiler_append_code(compiler," %d", args[k]->alloc);
if (args[k]->is_chained) {
orc_compiler_append_code(compiler," (chained)");
}
}
#endif
orc_compiler_append_code(compiler,"\n");
for(k=0;ksrc_size[k] == 0) continue;
switch (compiler->vars[insn->src_args[k]].vartype) {
case ORC_VAR_TYPE_SRC:
case ORC_VAR_TYPE_DEST:
//orc_neon_emit_load_src (compiler, &compiler->vars[insn->src_args[k]], unroll_index);
break;
case ORC_VAR_TYPE_CONST:
break;
case ORC_VAR_TYPE_PARAM:
break;
case ORC_VAR_TYPE_TEMP:
break;
default:
break;
}
}
compiler->insn_shift = compiler->loop_shift;
if (insn->flags & ORC_INSTRUCTION_FLAG_X2) {
compiler->insn_shift += 1;
}
if (insn->flags & ORC_INSTRUCTION_FLAG_X4) {
compiler->insn_shift += 2;
}
rule = insn->rule;
if (rule && rule->emit) {
#if 0
if (compiler->vars[insn->dest_args[0]].alloc !=
compiler->vars[insn->src_args[0]].alloc) {
orc_neon_emit_mov (compiler, compiler->vars[insn->dest_args[0]].alloc,
compiler->vars[insn->src_args[0]].alloc);
}
#endif
rule->emit (compiler, rule->emit_user, insn);
} else {
orc_compiler_append_code(compiler,"No rule for: %s\n", opcode->name);
}
for(k=0;kdest_size[k] == 0) continue;
switch (compiler->vars[insn->dest_args[k]].vartype) {
case ORC_VAR_TYPE_DEST:
//orc_neon_emit_store_dest (compiler, &compiler->vars[insn->dest_args[k]]);
break;
case ORC_VAR_TYPE_TEMP:
break;
default:
break;
}
}
}
for(k=0;kvars[k].name == NULL) continue;
if (compiler->vars[k].vartype == ORC_VAR_TYPE_SRC ||
compiler->vars[k].vartype == ORC_VAR_TYPE_DEST) {
if (compiler->vars[k].ptr_register) {
orc_arm_emit_add_imm (compiler,
compiler->vars[k].ptr_register,
compiler->vars[k].ptr_register,
compiler->vars[k].size << compiler->loop_shift);
} else {
//arm_emit_add_imm_memoffset (compiler, arm_ptr_size,
// compiler->vars[k].size << compiler->loop_shift,
// (int)ORC_STRUCT_OFFSET(OrcExecutor, arrays[k]),
// p->exec_reg);
}
}
}
}
#define NEON_BINARY(code,a,b,c) \
((code) | \
(((a)&0xf)<<12) | \
((((a)>>4)&0x1)<<22) | \
(((b)&0xf)<<16) | \
((((b)>>4)&0x1)<<7) | \
(((c)&0xf)<<0) | \
((((c)>>4)&0x1)<<5))
void
orc_neon_save_accumulators (OrcCompiler *compiler)
{
int i;
int src;
unsigned int code;
for(i=0;ivars + i;
if (compiler->vars[i].name == NULL) continue;
switch (compiler->vars[i].vartype) {
case ORC_VAR_TYPE_ACCUMULATOR:
src = compiler->vars[i].alloc;
orc_arm_emit_load_imm (compiler, compiler->gp_tmpreg,
ORC_STRUCT_OFFSET(OrcExecutor, accumulators[i-ORC_VAR_A1]));
orc_arm_emit_add (compiler, compiler->gp_tmpreg,
compiler->gp_tmpreg, compiler->exec_reg);
switch (var->size) {
case 2:
if (compiler->loop_shift > 0) {
ORC_ASM_CODE(compiler," vpaddl.u16 %s, %s\n",
orc_neon_reg_name (src),
orc_neon_reg_name (src));
code = 0xf3b40280;
code |= (src&0xf) << 12;
code |= ((src>>4)&0x1) << 22;
code |= (src&0xf) << 0;
orc_arm_emit (compiler, code);
ORC_ASM_CODE(compiler," vpaddl.u32 %s, %s\n",
orc_neon_reg_name (src),
orc_neon_reg_name (src));
code = 0xf3b80280;
code |= (src&0xf) << 12;
code |= ((src>>4)&0x1) << 22;
code |= (src&0xf) << 0;
orc_arm_emit (compiler, code);
}
ORC_ASM_CODE(compiler," vst1.16 %s[%d], [%s]\n",
orc_neon_reg_name (src), 0,
orc_arm_reg_name (compiler->gp_tmpreg));
code = 0xf480040f;
code |= (compiler->gp_tmpreg&0xf) << 16;
code |= (src&0xf) << 12;
code |= ((src>>4)&0x1) << 22;
orc_arm_emit (compiler, code);
break;
case 4:
if (compiler->loop_shift > 0) {
ORC_ASM_CODE(compiler," vpadd.u32 %s, %s, %s\n",
orc_neon_reg_name (src),
orc_neon_reg_name (src),
orc_neon_reg_name (src));
code = NEON_BINARY(0xf2200b10, src, src, src);
orc_arm_emit (compiler, code);
}
ORC_ASM_CODE(compiler," vst1.32 %s[%d], [%s]\n",
orc_neon_reg_name (src), 0,
orc_arm_reg_name (compiler->gp_tmpreg));
code = 0xf480080f;
code |= (compiler->gp_tmpreg&0xf) << 16;
code |= (src&0xf) << 12;
code |= ((src>>4)&0x1) << 22;
orc_arm_emit (compiler, code);
break;
default:
ORC_ERROR("bad size");
}
break;
default:
break;
}
}
}
void
neon_add_strides (OrcCompiler *compiler)
{
int i;
for(i=0;ivars[i].name == NULL) continue;
switch (compiler->vars[i].vartype) {
case ORC_VAR_TYPE_CONST:
break;
case ORC_VAR_TYPE_PARAM:
break;
case ORC_VAR_TYPE_SRC:
case ORC_VAR_TYPE_DEST:
orc_arm_emit_load_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor, arrays[i]));
orc_arm_emit_load_reg (compiler, ORC_ARM_A2, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor, params[i]));
orc_arm_emit_add (compiler, ORC_ARM_A3, ORC_ARM_A3, ORC_ARM_A2);
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor, arrays[i]));
break;
case ORC_VAR_TYPE_ACCUMULATOR:
break;
case ORC_VAR_TYPE_TEMP:
break;
default:
ORC_COMPILER_ERROR(compiler,"bad vartype");
break;
}
}
}
orc-0.4.18/orc/orcsse.h 0000664 0001750 0001750 00000002263 12111024531 011535 0000000 0000000
#ifndef _ORC_SSE_H_
#define _ORC_SSE_H_
#include
#include
ORC_BEGIN_DECLS
#ifdef ORC_ENABLE_UNSTABLE_API
typedef enum {
X86_XMM0 = ORC_VEC_REG_BASE + 16,
X86_XMM1,
X86_XMM2,
X86_XMM3,
X86_XMM4,
X86_XMM5,
X86_XMM6,
X86_XMM7,
X86_XMM8,
X86_XMM9,
X86_XMM10,
X86_XMM11,
X86_XMM12,
X86_XMM13,
X86_XMM14,
X86_XMM15
}OrcSSERegister;
#define ORC_SSE_SHUF(a,b,c,d) ((((a)&3)<<6)|(((b)&3)<<4)|(((c)&3)<<2)|(((d)&3)<<0))
const char * orc_x86_get_regname_sse(int i);
void orc_x86_emit_mov_memoffset_sse (OrcCompiler *compiler, int size, int offset,
int reg1, int reg2, int is_aligned);
void orc_x86_emit_mov_memindex_sse (OrcCompiler *compiler, int size, int offset,
int reg1, int regindex, int shift, int reg2, int is_aligned);
void orc_x86_emit_mov_sse_memoffset (OrcCompiler *compiler, int size, int reg1, int offset,
int reg2, int aligned, int uncached);
void orc_sse_set_mxcsr (OrcCompiler *compiler);
void orc_sse_restore_mxcsr (OrcCompiler *compiler);
void orc_sse_load_constant (OrcCompiler *compiler, int reg, int size,
orc_uint64 value);
#endif
unsigned int orc_sse_get_cpu_flags (void);
ORC_END_DECLS
#endif
orc-0.4.18/orc/orcfunctions.h 0000644 0001750 0001750 00000003714 11643723635 012777 0000000 0000000
/* autogenerated from orcfunctions.orc */
#ifndef _ORCFUNCTIONS_H_
#define _ORCFUNCTIONS_H_
#ifdef __cplusplus
extern "C" {
#endif
#ifndef _ORC_INTEGER_TYPEDEFS_
#define _ORC_INTEGER_TYPEDEFS_
#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
#include
typedef int8_t orc_int8;
typedef int16_t orc_int16;
typedef int32_t orc_int32;
typedef int64_t orc_int64;
typedef uint8_t orc_uint8;
typedef uint16_t orc_uint16;
typedef uint32_t orc_uint32;
typedef uint64_t orc_uint64;
#define ORC_UINT64_C(x) UINT64_C(x)
#elif defined(_MSC_VER)
typedef signed __int8 orc_int8;
typedef signed __int16 orc_int16;
typedef signed __int32 orc_int32;
typedef signed __int64 orc_int64;
typedef unsigned __int8 orc_uint8;
typedef unsigned __int16 orc_uint16;
typedef unsigned __int32 orc_uint32;
typedef unsigned __int64 orc_uint64;
#define ORC_UINT64_C(x) (x##Ui64)
#define inline __inline
#else
#include
typedef signed char orc_int8;
typedef short orc_int16;
typedef int orc_int32;
typedef unsigned char orc_uint8;
typedef unsigned short orc_uint16;
typedef unsigned int orc_uint32;
#if INT_MAX == LONG_MAX
typedef long long orc_int64;
typedef unsigned long long orc_uint64;
#define ORC_UINT64_C(x) (x##ULL)
#else
typedef long orc_int64;
typedef unsigned long orc_uint64;
#define ORC_UINT64_C(x) (x##UL)
#endif
#endif
typedef union { orc_int16 i; orc_int8 x2[2]; } orc_union16;
typedef union { orc_int32 i; float f; orc_int16 x2[2]; orc_int8 x4[4]; } orc_union32;
typedef union { orc_int64 i; double f; orc_int32 x2[2]; float x2f[2]; orc_int16 x4[4]; } orc_union64;
#endif
#ifndef ORC_RESTRICT
#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
#define ORC_RESTRICT restrict
#elif defined(__GNUC__) && __GNUC__ >= 4
#define ORC_RESTRICT __restrict__
#else
#define ORC_RESTRICT
#endif
#endif
void orc_memcpy (void * ORC_RESTRICT d1, const void * ORC_RESTRICT s1, int n);
void orc_memset (void * ORC_RESTRICT d1, int p1, int n);
#ifdef __cplusplus
}
#endif
#endif
orc-0.4.18/orc/orcbytecodes.h 0000664 0001750 0001750 00000010530 12111024531 012720 0000000 0000000
/* autogenerated by generate-bytecode */
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include
#include
typedef enum {
ORC_BC_END,
ORC_BC_BEGIN_FUNCTION,
ORC_BC_END_FUNCTION,
ORC_BC_SET_CONSTANT_N,
ORC_BC_SET_N_MULTIPLE,
ORC_BC_SET_N_MINIMUM,
ORC_BC_SET_N_MAXIMUM,
ORC_BC_SET_2D,
ORC_BC_SET_CONSTANT_M,
ORC_BC_SET_NAME,
ORC_BC_SET_BACKUP_FUNCTION,
ORC_BC_ADD_DESTINATION,
ORC_BC_ADD_SOURCE,
ORC_BC_ADD_ACCUMULATOR,
ORC_BC_ADD_CONSTANT,
ORC_BC_ADD_CONSTANT_INT64,
ORC_BC_ADD_PARAMETER,
ORC_BC_ADD_PARAMETER_FLOAT,
ORC_BC_ADD_PARAMETER_INT64,
ORC_BC_ADD_PARAMETER_DOUBLE,
ORC_BC_ADD_TEMPORARY,
ORC_BC_INSTRUCTION_FLAGS,
ORC_BC_RESERVED_22,
ORC_BC_RESERVED_23,
ORC_BC_RESERVED_24,
ORC_BC_RESERVED_25,
ORC_BC_RESERVED_26,
ORC_BC_RESERVED_27,
ORC_BC_RESERVED_28,
ORC_BC_RESERVED_29,
ORC_BC_RESERVED_30,
ORC_BC_RESERVED_31,
ORC_BC_absb,
ORC_BC_addb,
ORC_BC_addssb,
ORC_BC_addusb,
ORC_BC_andb,
ORC_BC_andnb,
ORC_BC_avgsb,
ORC_BC_avgub,
/* 40 */
ORC_BC_cmpeqb,
ORC_BC_cmpgtsb,
ORC_BC_copyb,
ORC_BC_loadb,
ORC_BC_loadoffb,
ORC_BC_loadupdb,
ORC_BC_loadupib,
ORC_BC_loadpb,
ORC_BC_ldresnearb,
ORC_BC_ldresnearl,
/* 50 */
ORC_BC_ldreslinb,
ORC_BC_ldreslinl,
ORC_BC_maxsb,
ORC_BC_maxub,
ORC_BC_minsb,
ORC_BC_minub,
ORC_BC_mullb,
ORC_BC_mulhsb,
ORC_BC_mulhub,
ORC_BC_orb,
/* 60 */
ORC_BC_shlb,
ORC_BC_shrsb,
ORC_BC_shrub,
ORC_BC_signb,
ORC_BC_storeb,
ORC_BC_subb,
ORC_BC_subssb,
ORC_BC_subusb,
ORC_BC_xorb,
ORC_BC_absw,
/* 70 */
ORC_BC_addw,
ORC_BC_addssw,
ORC_BC_addusw,
ORC_BC_andw,
ORC_BC_andnw,
ORC_BC_avgsw,
ORC_BC_avguw,
ORC_BC_cmpeqw,
ORC_BC_cmpgtsw,
ORC_BC_copyw,
/* 80 */
ORC_BC_div255w,
ORC_BC_divluw,
ORC_BC_loadw,
ORC_BC_loadoffw,
ORC_BC_loadpw,
ORC_BC_maxsw,
ORC_BC_maxuw,
ORC_BC_minsw,
ORC_BC_minuw,
ORC_BC_mullw,
/* 90 */
ORC_BC_mulhsw,
ORC_BC_mulhuw,
ORC_BC_orw,
ORC_BC_shlw,
ORC_BC_shrsw,
ORC_BC_shruw,
ORC_BC_signw,
ORC_BC_storew,
ORC_BC_subw,
ORC_BC_subssw,
/* 100 */
ORC_BC_subusw,
ORC_BC_xorw,
ORC_BC_absl,
ORC_BC_addl,
ORC_BC_addssl,
ORC_BC_addusl,
ORC_BC_andl,
ORC_BC_andnl,
ORC_BC_avgsl,
ORC_BC_avgul,
/* 110 */
ORC_BC_cmpeql,
ORC_BC_cmpgtsl,
ORC_BC_copyl,
ORC_BC_loadl,
ORC_BC_loadoffl,
ORC_BC_loadpl,
ORC_BC_maxsl,
ORC_BC_maxul,
ORC_BC_minsl,
ORC_BC_minul,
/* 120 */
ORC_BC_mulll,
ORC_BC_mulhsl,
ORC_BC_mulhul,
ORC_BC_orl,
ORC_BC_shll,
ORC_BC_shrsl,
ORC_BC_shrul,
ORC_BC_signl,
ORC_BC_storel,
ORC_BC_subl,
/* 130 */
ORC_BC_subssl,
ORC_BC_subusl,
ORC_BC_xorl,
ORC_BC_loadq,
ORC_BC_loadpq,
ORC_BC_storeq,
ORC_BC_splatw3q,
ORC_BC_copyq,
ORC_BC_cmpeqq,
ORC_BC_cmpgtsq,
/* 140 */
ORC_BC_andq,
ORC_BC_andnq,
ORC_BC_orq,
ORC_BC_xorq,
ORC_BC_addq,
ORC_BC_subq,
ORC_BC_shlq,
ORC_BC_shrsq,
ORC_BC_shruq,
ORC_BC_convsbw,
/* 150 */
ORC_BC_convubw,
ORC_BC_splatbw,
ORC_BC_splatbl,
ORC_BC_convswl,
ORC_BC_convuwl,
ORC_BC_convslq,
ORC_BC_convulq,
ORC_BC_convwb,
ORC_BC_convhwb,
ORC_BC_convssswb,
/* 160 */
ORC_BC_convsuswb,
ORC_BC_convusswb,
ORC_BC_convuuswb,
ORC_BC_convlw,
ORC_BC_convhlw,
ORC_BC_convssslw,
ORC_BC_convsuslw,
ORC_BC_convusslw,
ORC_BC_convuuslw,
ORC_BC_convql,
/* 170 */
ORC_BC_convsssql,
ORC_BC_convsusql,
ORC_BC_convussql,
ORC_BC_convuusql,
ORC_BC_mulsbw,
ORC_BC_mulubw,
ORC_BC_mulswl,
ORC_BC_muluwl,
ORC_BC_mulslq,
ORC_BC_mululq,
/* 180 */
ORC_BC_accw,
ORC_BC_accl,
ORC_BC_accsadubl,
ORC_BC_swapw,
ORC_BC_swapl,
ORC_BC_swapwl,
ORC_BC_swapq,
ORC_BC_swaplq,
ORC_BC_select0wb,
ORC_BC_select1wb,
/* 190 */
ORC_BC_select0lw,
ORC_BC_select1lw,
ORC_BC_select0ql,
ORC_BC_select1ql,
ORC_BC_mergelq,
ORC_BC_mergewl,
ORC_BC_mergebw,
ORC_BC_splitql,
ORC_BC_splitlw,
ORC_BC_splitwb,
/* 200 */
ORC_BC_addf,
ORC_BC_subf,
ORC_BC_mulf,
ORC_BC_divf,
ORC_BC_sqrtf,
ORC_BC_maxf,
ORC_BC_minf,
ORC_BC_cmpeqf,
ORC_BC_cmpltf,
ORC_BC_cmplef,
/* 210 */
ORC_BC_convfl,
ORC_BC_convlf,
ORC_BC_addd,
ORC_BC_subd,
ORC_BC_muld,
ORC_BC_divd,
ORC_BC_sqrtd,
ORC_BC_maxd,
ORC_BC_mind,
ORC_BC_cmpeqd,
/* 220 */
ORC_BC_cmpltd,
ORC_BC_cmpled,
ORC_BC_convdl,
ORC_BC_convld,
ORC_BC_convfd,
ORC_BC_convdf,
/* 226 */
ORC_BC_LAST
} OrcBytecodes;
orc-0.4.18/orc/opcodes.h 0000644 0001750 0001750 00000013151 11563547254 011715 0000000 0000000 UNARY_SB(absb, "ORC_ABS(%s)")
BINARY_SB(addb, "%s + %s")
BINARY_SB(addssb, "ORC_CLAMP_SB(%s + %s)")
BINARY_UB(addusb, "ORC_CLAMP_UB((orc_uint8)%s + (orc_uint8)%s)")
BINARY_SB(andb, "%s & %s")
BINARY_SB(andnb, "(~%s) & %s")
BINARY_SB(avgsb, "(%s + %s + 1)>>1")
BINARY_UB(avgub, "((orc_uint8)%s + (orc_uint8)%s + 1)>>1")
BINARY_SB(cmpeqb, "(%s == %s) ? (~0) : 0")
BINARY_SB(cmpgtsb, "(%s > %s) ? (~0) : 0")
UNARY_SB(copyb, "%s")
BINARY_SB(maxsb, "ORC_MAX(%s, %s)")
BINARY_UB(maxub, "ORC_MAX((orc_uint8)%s, (orc_uint8)%s)")
BINARY_SB(minsb, "ORC_MIN(%s, %s)")
BINARY_UB(minub, "ORC_MIN((orc_uint8)%s, (orc_uint8)%s)")
BINARY_SB(mullb, "(%s * %s) & 0xff")
BINARY_SB(mulhsb, "(%s * %s) >> 8")
BINARY_UB(mulhub, "((orc_uint32)(orc_uint8)%s * (orc_uint32)(orc_uint8)%s) >> 8")
BINARY_SB(orb, "%s | %s")
BINARY_SB(shlb, "%s << %s")
BINARY_SB(shrsb, "%s >> %s")
BINARY_UB(shrub, "((orc_uint8)%s) >> %s")
UNARY_SB(signb, "ORC_CLAMP(%s,-1,1)")
BINARY_SB(subb, "%s - %s")
BINARY_SB(subssb, "ORC_CLAMP_SB(%s - %s)")
BINARY_UB(subusb, "ORC_CLAMP_UB((orc_uint8)%s - (orc_uint8)%s)")
BINARY_SB(xorb, "%s ^ %s")
UNARY_SW(absw, "ORC_ABS(%s)")
BINARY_SW(addw, "%s + %s")
BINARY_SW(addssw, "ORC_CLAMP_SW(%s + %s)")
BINARY_UW(addusw, "ORC_CLAMP_UW((orc_uint16)%s + (orc_uint16)%s)")
BINARY_SW(andw, "%s & %s")
BINARY_SW(andnw, "(~%s) & %s")
BINARY_SW(avgsw, "(%s + %s + 1)>>1")
BINARY_UW(avguw, "((orc_uint16)%s + (orc_uint16)%s + 1)>>1")
BINARY_SW(cmpeqw, "(%s == %s) ? (~0) : 0")
BINARY_SW(cmpgtsw, "(%s > %s) ? (~0) : 0")
UNARY_SW(copyw, "%s")
BINARY_SW(maxsw, "ORC_MAX(%s, %s)")
BINARY_UW(maxuw, "ORC_MAX((orc_uint16)%s, (orc_uint16)%s)")
BINARY_SW(minsw, "ORC_MIN(%s, %s)")
BINARY_UW(minuw, "ORC_MIN((orc_uint16)%s, (orc_uint16)%s)")
BINARY_SW(mullw, "(%s * %s) & 0xffff")
BINARY_SW(mulhsw, "(%s * %s) >> 16")
BINARY_UW(mulhuw, "((orc_uint32)((orc_uint16)%s) * (orc_uint32)((orc_uint16)%s)) >> 16")
BINARY_SW(orw, "%s | %s")
BINARY_SW(shlw, "%s << %s")
BINARY_SW(shrsw, "%s >> %s")
BINARY_UW(shruw, "((orc_uint16)%s) >> %s")
UNARY_SW(signw, "ORC_CLAMP(%s,-1,1)")
BINARY_SW(subw, "%s - %s")
BINARY_SW(subssw, "ORC_CLAMP_SW(%s - %s)")
BINARY_UW(subusw, "ORC_CLAMP_UW((orc_uint16)%s - (orc_uint16)%s)")
BINARY_SW(xorw, "%s ^ %s")
UNARY_SL(absl, "ORC_ABS(%s)")
BINARY_SL(addl, "%s + %s")
BINARY_SL(addssl, "ORC_CLAMP_SL((orc_int64)%s + (orc_int64)%s)")
BINARY_UL(addusl, "ORC_CLAMP_UL((orc_int64)(orc_uint32)%s + (orc_int64)(orc_uint32)%s)")
BINARY_SL(andl, "%s & %s")
BINARY_SL(andnl, "(~%s) & %s")
BINARY_SL(avgsl, "((orc_int64)%s + (orc_int64)%s + 1)>>1")
BINARY_UL(avgul, "((orc_uint64)(orc_uint32)%s + (orc_uint64)(orc_uint32)%s + 1)>>1")
BINARY_SL(cmpeql, "(%s == %s) ? (~0) : 0")
BINARY_SL(cmpgtsl, "(%s > %s) ? (~0) : 0")
UNARY_SL(copyl, "%s")
BINARY_SL(maxsl, "ORC_MAX(%s, %s)")
BINARY_UL(maxul, "ORC_MAX((orc_uint32)%s, (orc_uint32)%s)")
BINARY_SL(minsl, "ORC_MIN(%s, %s)")
BINARY_UL(minul, "ORC_MIN((orc_uint32)%s, (orc_uint32)%s)")
BINARY_SL(mulll, "(%s * %s) & 0xffffffff")
BINARY_SL(mulhsl, "((orc_int64)%s * (orc_int64)%s) >> 32")
BINARY_UL(mulhul, "((orc_uint64)(orc_uint32)%s * (orc_uint64)(orc_uint32)%s) >> 32")
BINARY_SL(orl, "%s | %s")
BINARY_SL(shll, "%s << %s")
BINARY_SL(shrsl, "%s >> %s")
BINARY_UL(shrul, "((orc_uint32)%s) >> %s")
UNARY_SL(signl, "ORC_CLAMP(%s,-1,1)")
BINARY_SL(subl, "%s - %s")
BINARY_SL(subssl, "ORC_CLAMP_SL((orc_int64)%s - (orc_int64)%s)")
BINARY_UL(subusl, "ORC_CLAMP_UL((orc_int64)(orc_uint32)%s - (orc_int64)(orc_uint32)%s)")
BINARY_SL(xorl, "%s ^ %s")
UNARY_SQ(copyq, "%s")
BINARY_SQ(cmpeqq, "(%s == %s) ? (~0) : 0")
BINARY_SQ(cmpgtsq, "(%s > %s) ? (~0) : 0")
BINARY_SQ(andq, "%s & %s")
BINARY_SQ(andnq, "(~%s) & %s")
BINARY_SQ(orq, "%s | %s")
BINARY_SQ(xorq, "%s ^ %s")
BINARY_SQ(addq, "%s + %s")
BINARY_SQ(subq, "%s - %s")
BINARY_SQ(shlq, "%s << %s")
BINARY_SQ(shrsq, "%s >> %s")
BINARY_UQ(shruq, "((orc_uint64)%s) >> %s")
UNARY_BW(convsbw, "%s")
UNARY_BW(convubw, "(orc_uint8)%s")
UNARY_WB(convwb, "%s")
UNARY_WB(convhwb, "((orc_uint16)%s)>>8")
UNARY_WB(convssswb, "ORC_CLAMP_SB(%s)")
UNARY_WB(convsuswb, "ORC_CLAMP_UB(%s)")
UNARY_WB(convusswb, "ORC_MIN((orc_uint16)%s,ORC_SB_MAX)")
UNARY_WB(convuuswb, "ORC_MIN((orc_uint16)%s,ORC_UB_MAX)")
UNARY_WL(convswl, "%s")
UNARY_WL(convuwl, "(orc_uint16)%s")
UNARY_LW(convlw, "%s")
UNARY_WB(convhlw, "((orc_uint32)%s)>>16")
UNARY_LW(convssslw, "ORC_CLAMP_SW(%s)")
UNARY_LW(convsuslw, "ORC_CLAMP_UW(%s)")
UNARY_LW(convusslw, "ORC_CLAMP((orc_uint32)%s,0,ORC_SW_MAX)")
UNARY_LW(convuuslw, "ORC_CLAMP_UW((orc_uint32)%s)")
UNARY_LQ(convslq, "%s")
UNARY_LQ(convulq, "(orc_uint32)%s")
UNARY_LW(convql, "%s")
UNARY_LW(convsssql, "ORC_CLAMP_SL(%s)")
UNARY_LW(convsusql, "ORC_CLAMP_UL(%s)")
UNARY_LW(convussql, "ORC_CLAMP_SL((orc_uint64)%s)")
UNARY_LW(convuusql, "ORC_CLAMP_UL((orc_uint64)%s)")
BINARY_BW(mulsbw, "%s * %s")
BINARY_BW(mulubw, "((orc_uint8)%s) * ((orc_uint8)%s)")
BINARY_WL(mulswl, "%s * %s")
BINARY_WL(muluwl, "((orc_uint16)%s) * ((orc_uint16)%s)")
BINARY_LQ(mulslq, "((orc_int64)%s) * ((orc_int64)%s)")
BINARY_LQ(mululq, "((orc_uint64)((orc_uint32)%s)) * ((orc_uint64)((orc_uint32)%s))")
UNARY_UW(swapw, "ORC_SWAP_W(%s)")
UNARY_UL(swapl, "ORC_SWAP_L(%s)")
UNARY_UQ(swapq, "ORC_SWAP_Q(%s)")
BINARY_F(addf, "%s + %s")
BINARY_F(subf, "%s - %s")
BINARY_F(mulf, "%s * %s")
BINARY_F(divf, "%s / %s")
UNARY_F(sqrtf, "sqrt(%s)")
BINARY_FL(cmpeqf, "(%s == %s) ? (~0) : 0")
BINARY_FL(cmpltf, "(%s < %s) ? (~0) : 0")
BINARY_FL(cmplef, "(%s <= %s) ? (~0) : 0")
BINARY_D(addd, "%s + %s")
BINARY_D(subd, "%s - %s")
BINARY_D(muld, "%s * %s")
BINARY_D(divd, "%s / %s")
UNARY_D(sqrtd, "sqrt(%s)")
BINARY_DQ(cmpeqd, "(%s == %s) ? ORC_UINT64_C(~0) : 0")
BINARY_DQ(cmpltd, "(%s < %s) ? ORC_UINT64_C(~0) : 0")
BINARY_DQ(cmpled, "(%s <= %s) ? ORC_UINT64_C(~0) : 0")
orc-0.4.18/orc/orcprogram-arm.c 0000664 0001750 0001750 00000033326 12071634360 013202 0000000 0000000
#include "config.h"
#include
#include
#include
#include
#include
#include
#include
#include
#define SIZE 65536
void orc_arm_emit_loop (OrcCompiler *compiler);
void orc_compiler_orc_arm_register_rules (OrcTarget *target);
void orc_compiler_orc_arm_init (OrcCompiler *compiler);
unsigned int orc_compiler_orc_arm_get_default_flags (void);
void orc_compiler_orc_arm_assemble (OrcCompiler *compiler);
void orc_compiler_rewrite_vars (OrcCompiler *compiler);
void orc_compiler_dump (OrcCompiler *compiler);
void arm_add_strides (OrcCompiler *compiler);
void
orc_arm_emit_prologue (OrcCompiler *compiler)
{
unsigned int regs = 0;
int i;
orc_compiler_append_code(compiler,".global %s\n", compiler->program->name);
orc_compiler_append_code(compiler,"%s:\n", compiler->program->name);
for(i=0;i<16;i++){
if (compiler->used_regs[ORC_GP_REG_BASE + i] &&
compiler->save_regs[ORC_GP_REG_BASE + i]) {
regs |= (1<used_regs[ORC_GP_REG_BASE + i] &&
compiler->save_regs[ORC_GP_REG_BASE + i]) {
regs |= (1<valid_regs[i] = 1;
}
//compiler->valid_regs[ORC_ARM_SB] = 0;
compiler->valid_regs[ORC_ARM_IP] = 0;
compiler->valid_regs[ORC_ARM_SP] = 0;
compiler->valid_regs[ORC_ARM_LR] = 0;
compiler->valid_regs[ORC_ARM_PC] = 0;
for(i=4;i<11;i++) {
compiler->save_regs[ORC_GP_REG_BASE+i] = 1;
}
for(i=0;ialloc_regs[i] = 0;
compiler->used_regs[i] = 0;
}
compiler->exec_reg = ORC_ARM_A1;
compiler->valid_regs[compiler->exec_reg] = 0;
compiler->gp_tmpreg = ORC_ARM_A2;
compiler->valid_regs[compiler->gp_tmpreg] = 0;
compiler->tmpreg = ORC_ARM_A3;
compiler->valid_regs[compiler->tmpreg] = 0;
compiler->loop_shift = 0;
}
void
orc_arm_load_constants_outer (OrcCompiler *compiler)
{
int i;
for(i=0;ivars[i].name == NULL) continue;
switch (compiler->vars[i].vartype) {
case ORC_VAR_TYPE_CONST:
//orc_arm_emit_load_imm (compiler, compiler->vars[i].alloc,
// (int)compiler->vars[i].value);
break;
case ORC_VAR_TYPE_PARAM:
ORC_PROGRAM_ERROR(compiler,"unimplemented");
return;
/* FIXME offset is too large */
//orc_arm_loadw (compiler, compiler->vars[i].alloc,
// compiler->exec_reg,
// (int)ORC_STRUCT_OFFSET(OrcExecutor, params[i]));
break;
case ORC_VAR_TYPE_SRC:
case ORC_VAR_TYPE_DEST:
break;
default:
break;
}
}
for(i=0;in_insns;i++){
OrcInstruction *insn = compiler->insns + i;
OrcStaticOpcode *opcode = insn->opcode;
OrcRule *rule;
if (!(insn->flags & ORC_INSN_FLAG_INVARIANT)) continue;
ORC_ASM_CODE(compiler,"# %d: %s\n", i, insn->opcode->name);
rule = insn->rule;
if (rule && rule->emit) {
rule->emit (compiler, rule->emit_user, insn);
} else {
ORC_COMPILER_ERROR(compiler,"No rule for: %s", opcode->name);
}
}
}
void
orc_arm_load_constants_inner (OrcCompiler *compiler)
{
int i;
for(i=0;ivars[i].name == NULL) continue;
switch (compiler->vars[i].vartype) {
case ORC_VAR_TYPE_CONST:
case ORC_VAR_TYPE_PARAM:
break;
case ORC_VAR_TYPE_SRC:
case ORC_VAR_TYPE_DEST:
orc_arm_emit_load_reg (compiler,
compiler->vars[i].ptr_register,
compiler->exec_reg, ORC_STRUCT_OFFSET(OrcExecutor, arrays[i]));
break;
default:
break;
}
}
}
#if 0
void
orc_arm_emit_load_src (OrcCompiler *compiler, OrcVariable *var)
{
int ptr_reg;
if (var->ptr_register == 0) {
int i;
i = var - compiler->vars;
//orc_arm_emit_mov_memoffset_reg (compiler, orc_arm_ptr_size,
// (int)ORC_STRUCT_OFFSET(OrcExecutor, arrays[i]),
// compiler->exec_reg, X86_ECX);
ptr_reg = ORC_ARM_PC;
} else {
ptr_reg = var->ptr_register;
}
switch (var->size << compiler->loop_shift) {
case 1:
orc_arm_loadb (compiler, var->alloc, ptr_reg, 0);
//orc_arm_emit_mov_memoffset_reg (compiler, 1, 0, ptr_reg, X86_ECX);
//orc_arm_emit_mov_reg_arm (compiler, X86_ECX, var->alloc);
break;
case 2:
orc_arm_loadw (compiler, var->alloc, ptr_reg, 0);
//orc_arm_emit_mov_memoffset_reg (compiler, 2, 0, ptr_reg, X86_ECX);
//orc_arm_emit_mov_reg_arm (compiler, X86_ECX, var->alloc);
break;
case 4:
orc_arm_loadl (compiler, var->alloc, ptr_reg, 0);
//orc_arm_emit_mov_memoffset_arm (compiler, 4, 0, ptr_reg, var->alloc);
break;
//case 8:
//orc_arm_emit_mov_memoffset_arm (compiler, 8, 0, ptr_reg, var->alloc);
break;
//case 16:
//orc_arm_emit_mov_memoffset_arm (compiler, 16, 0, ptr_reg, var->alloc);
break;
default:
ORC_COMPILER_ERROR(compiler, "bad size %d", var->size << compiler->loop_shift);
}
}
void
orc_arm_emit_store_dest (OrcCompiler *compiler, OrcVariable *var)
{
int ptr_reg;
if (var->ptr_register == 0) {
//orc_arm_emit_mov_memoffset_reg (compiler, orc_arm_ptr_size,
// var->ptr_offset, compiler->exec_reg, X86_ECX);
ptr_reg = ORC_ARM_PC;
} else {
ptr_reg = var->ptr_register;
}
switch (var->size << compiler->loop_shift) {
case 1:
orc_arm_storeb (compiler, ptr_reg, 0, var->alloc);
//orc_arm_emit_mov_orc_arm_reg (compiler, var->alloc, X86_ECX);
//orc_arm_emit_mov_reg_memoffset (compiler, 1, X86_ECX, 0, ptr_reg);
break;
case 2:
orc_arm_storew (compiler, ptr_reg, 0, var->alloc);
//orc_arm_emit_mov_orc_arm_reg (compiler, var->alloc, X86_ECX);
//orc_arm_emit_mov_reg_memoffset (compiler, 2, X86_ECX, 0, ptr_reg);
break;
case 4:
orc_arm_storel (compiler, ptr_reg, 0, var->alloc);
//orc_arm_emit_mov_orc_arm_memoffset (compiler, 4, var->alloc, 0, ptr_reg,
// var->is_aligned, var->is_uncached);
break;
case 8:
//orc_arm_emit_mov_orc_arm_memoffset (compiler, 8, var->alloc, 0, ptr_reg,
// var->is_aligned, var->is_uncached);
break;
case 16:
//orc_arm_emit_mov_orc_arm_memoffset (compiler, 16, var->alloc, 0, ptr_reg,
// var->is_aligned, var->is_uncached);
break;
default:
ORC_COMPILER_ERROR(compiler, "bad size %d", var->size << compiler->loop_shift);
}
}
#endif
void
orc_compiler_orc_arm_assemble (OrcCompiler *compiler)
{
int dest_var = ORC_VAR_D1;
compiler->vars[dest_var].is_aligned = FALSE;
orc_arm_emit_prologue (compiler);
orc_arm_load_constants_outer (compiler);
if (compiler->program->is_2d) {
if (compiler->program->constant_m > 0) {
orc_arm_emit_load_imm (compiler, ORC_ARM_A3, compiler->program->constant_m
);
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,params[ORC_VAR_A2]));
} else {
orc_arm_emit_load_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor, params[ORC_VAR_A1]));
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,params[ORC_VAR_A2]));
}
orc_arm_emit_label (compiler, 8);
}
orc_arm_emit_load_reg (compiler, ORC_ARM_IP, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,n));
orc_arm_load_constants_inner (compiler);
orc_arm_emit_label (compiler, 1);
orc_arm_emit_cmp_i (compiler, ORC_ARM_COND_AL, ORC_ARM_IP, 0);
orc_arm_emit_branch (compiler, ORC_ARM_COND_EQ, 3);
orc_arm_emit_label (compiler, 2);
orc_arm_emit_loop (compiler);
orc_arm_emit_sub_i (compiler, ORC_ARM_COND_AL, 0, ORC_ARM_IP, ORC_ARM_IP, 1);
orc_arm_emit_cmp_i (compiler, ORC_ARM_COND_AL, ORC_ARM_IP, 0);
orc_arm_emit_branch (compiler, ORC_ARM_COND_NE, 2);
orc_arm_emit_label (compiler, 3);
if (compiler->program->is_2d) {
arm_add_strides (compiler);
orc_arm_emit_load_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor, params[ORC_VAR_A2]));
orc_arm_emit_sub_imm (compiler, ORC_ARM_A3, ORC_ARM_A3, 1, TRUE);
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor,params[ORC_VAR_A2]));
orc_arm_emit_branch (compiler, ORC_ARM_COND_NE, 8);
}
orc_arm_emit_epilogue (compiler);
orc_arm_do_fixups (compiler);
}
void
orc_arm_emit_loop (OrcCompiler *compiler)
{
int j;
int k;
OrcInstruction *insn;
OrcStaticOpcode *opcode;
OrcRule *rule;
for(j=0;jn_insns;j++){
insn = compiler->insns + j;
opcode = insn->opcode;
if (insn->flags & ORC_INSN_FLAG_INVARIANT) continue;
orc_compiler_append_code(compiler,"# %d: %s", j, insn->opcode->name);
/* set up args */
#if 0
for(k=0;kn_src + opcode->n_dest;k++){
args[k] = compiler->vars + insn->args[k];
orc_compiler_append_code(compiler," %d", args[k]->alloc);
if (args[k]->is_chained) {
orc_compiler_append_code(compiler," (chained)");
}
}
#endif
orc_compiler_append_code(compiler,"\n");
for(k=0;ksrc_size[k] == 0) continue;
switch (compiler->vars[insn->src_args[k]].vartype) {
case ORC_VAR_TYPE_SRC:
case ORC_VAR_TYPE_DEST:
//orc_arm_emit_load_src (compiler, &compiler->vars[insn->src_args[k]]);
break;
case ORC_VAR_TYPE_CONST:
break;
case ORC_VAR_TYPE_PARAM:
break;
case ORC_VAR_TYPE_TEMP:
break;
default:
break;
}
}
rule = insn->rule;
if (rule && rule->emit) {
int src = ORC_SRC_ARG (compiler, insn, 0);
int dest = ORC_DEST_ARG (compiler, insn, 0);
if (dest != src) {
orc_arm_emit_mov_r (compiler, ORC_ARM_COND_AL, 0, dest, src);
}
rule->emit (compiler, rule->emit_user, insn);
} else {
orc_compiler_append_code(compiler,"No rule for: %s\n", opcode->name);
}
for(k=0;kdest_size[k] == 0) continue;
switch (compiler->vars[insn->dest_args[k]].vartype) {
case ORC_VAR_TYPE_DEST:
//orc_arm_emit_store_dest (compiler, &compiler->vars[insn->dest_args[k]]);
break;
case ORC_VAR_TYPE_TEMP:
break;
default:
break;
}
}
}
for(k=0;kvars[k].name == NULL) continue;
if (compiler->vars[k].vartype == ORC_VAR_TYPE_SRC ||
compiler->vars[k].vartype == ORC_VAR_TYPE_DEST) {
if (compiler->vars[k].ptr_register) {
orc_arm_emit_add_i (compiler, ORC_ARM_COND_AL, 0,
compiler->vars[k].ptr_register,
compiler->vars[k].ptr_register,
compiler->vars[k].size << compiler->loop_shift);
} else {
//orc_arm_emit_add_imm_memoffset (compiler, orc_arm_ptr_size,
// compiler->vars[k].size << compiler->loop_shift,
// (int)ORC_STRUCT_OFFSET(OrcExecutor, arrays[k]),
// compiler->exec_reg);
}
}
}
}
void
arm_add_strides (OrcCompiler *compiler)
{
int i;
for(i=0;ivars[i].name == NULL) continue;
switch (compiler->vars[i].vartype) {
case ORC_VAR_TYPE_CONST:
break;
case ORC_VAR_TYPE_PARAM:
break;
case ORC_VAR_TYPE_SRC:
case ORC_VAR_TYPE_DEST:
orc_arm_emit_load_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor, arrays[i]));
orc_arm_emit_load_reg (compiler, ORC_ARM_A2, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor, params[i]));
orc_arm_emit_add (compiler, ORC_ARM_A3, ORC_ARM_A3, ORC_ARM_A2);
orc_arm_emit_store_reg (compiler, ORC_ARM_A3, compiler->exec_reg,
(int)ORC_STRUCT_OFFSET(OrcExecutor, arrays[i]));
break;
case ORC_VAR_TYPE_ACCUMULATOR:
break;
case ORC_VAR_TYPE_TEMP:
break;
default:
ORC_COMPILER_ERROR(compiler,"bad vartype");
break;
}
}
}
orc-0.4.18/orc/orc.c 0000664 0001750 0001750 00000002431 12111024531 011012 0000000 0000000
#include "config.h"
#include
#include
#include
#include
#include
#include
#include "orcinternal.h"
/**
* SECTION:orc
* @title: Orc
* @short_description: Library Initialization
*/
void _orc_debug_init(void);
void _orc_once_init(void);
void _orc_compiler_init(void);
/**
* orc_init:
*
* This function initializes the Orc library, and
* should be called before using any other Orc function.
* Subsequent calls to this function have no effect.
*/
void
orc_init (void)
{
static volatile int inited = FALSE;
if (!inited) {
orc_global_mutex_lock ();
if (!inited) {
ORC_ASSERT(sizeof(OrcExecutor) == sizeof(OrcExecutorAlt));
_orc_debug_init();
_orc_compiler_init();
orc_opcode_init();
orc_c_init();
#ifdef ENABLE_BACKEND_C64X
orc_c64x_c_init();
#endif
#ifdef ENABLE_BACKEND_MMX
orc_mmx_init();
#endif
#ifdef ENABLE_BACKEND_SSE
orc_sse_init();
#endif
#ifdef ENABLE_BACKEND_ALTIVEC
orc_powerpc_init();
#endif
#ifdef ENABLE_BACKEND_ARM
orc_arm_init();
#endif
#ifdef ENABLE_BACKEND_NEON
orc_neon_init();
#endif
#ifdef ENABLE_BACKEND_MIPS
orc_mips_init();
#endif
inited = TRUE;
}
orc_global_mutex_unlock ();
}
}
orc-0.4.18/orc/orccompiler.h 0000664 0001750 0001750 00000007263 12111024531 012562 0000000 0000000
#ifndef _ORC_COMPILER_H_
#define _ORC_COMPILER_H_
#include
#include
#include
#include
#include
#include
#include
#include