* configure.in (WIN32LDFLAGS): Rename to SHARED_LDFLAGS.

(WIN32LIBADD): Rename to SHARED_LIBADD
  (SHARED_DEPENDENCIES): New exported variable.
  (enable_shared): Add dependency upon libbfd.la for non-cygwin based shared library builds.
* Makefile.am (libopcodes_la_DEPENDENCIES): Append SHARED_DEPENDENCIES.
  (libopcodes_la_LIBADD): Rename WIN32LIBADD to SHARED_LIBADD.
  (libopcodes_la_LDFLAGS): Rename WIN32LDFLAGS to SHARED_LDFLAGS.
* configure: Regenerate.
* Makefile.in: Regenerate.
This commit is contained in:
Nick Clifton 2007-10-04 14:06:40 +00:00
parent 8524166df4
commit 45d42143d4
5 changed files with 72 additions and 48 deletions

View file

@ -1,5 +1,17 @@
2007-10-04 Nick Clifton <nickc@redhat.com> 2007-10-04 Nick Clifton <nickc@redhat.com>
* configure.in (WIN32LDFLAGS): Rename to SHARED_LDFLAGS.
(WIN32LIBADD): Rename to SHARED_LIBADD
(SHARED_DEPENDENCIES): New exported variable.
(enable_shared): Add dependency upon libbfd.la for non-cygwin
based shared library builds.
* Makefile.am (libopcodes_la_DEPENDENCIES): Append
SHARED_DEPENDENCIES.
(libopcodes_la_LIBADD): Rename WIN32LIBADD to SHARED_LIBADD.
(libopcodes_la_LDFLAGS): Rename WIN32LDFLAGS to SHARED_LDFLAGS.
* configure: Regenerate.
* Makefile.in: Regenerate.
PR gas/5100 PR gas/5100
* arc-opc.c (insert_offset): Fix spelling mistake in error * arc-opc.c (insert_offset): Fix spelling mistake in error
message. message.

View file

@ -367,10 +367,11 @@ libopcodes_la_SOURCES = dis-buf.c disassemble.c dis-init.c
# Unfortunately this causes libtool to add -L$(libdir), referring to the # Unfortunately this causes libtool to add -L$(libdir), referring to the
# planned install directory of libbfd. This can cause us to pick up an # planned install directory of libbfd. This can cause us to pick up an
# old version of libbfd, or to pick up libbfd for the wrong architecture # old version of libbfd, or to pick up libbfd for the wrong architecture
# if host != build. # if host != build. So for building with shared libraries we use a
libopcodes_la_DEPENDENCIES = $(OFILES) # hardcoded path to libbfd.so instead of relying on the entries in libbfd.la.
libopcodes_la_LIBADD = $(OFILES) @WIN32LIBADD@ libopcodes_la_DEPENDENCIES = $(OFILES) @SHARED_DEPENDENCIES@
libopcodes_la_LDFLAGS = -release `cat ../bfd/libtool-soversion` @WIN32LDFLAGS@ libopcodes_la_LIBADD = $(OFILES) @SHARED_LIBADD@
libopcodes_la_LDFLAGS = -release `cat ../bfd/libtool-soversion` @SHARED_LDFLAGS@
# libtool will build .libs/libopcodes.a. We create libopcodes.a in # libtool will build .libs/libopcodes.a. We create libopcodes.a in
# the build directory so that we don't have to convert all the # the build directory so that we don't have to convert all the

View file

@ -176,16 +176,20 @@ POSUB = @POSUB@
RANLIB = @RANLIB@ RANLIB = @RANLIB@
SED = @SED@ SED = @SED@
SET_MAKE = @SET_MAKE@ SET_MAKE = @SET_MAKE@
SHARED_DEPENDENCIES = @SHARED_DEPENDENCIES@
SHARED_LDFLAGS = @SHARED_LDFLAGS@
SHARED_LIBADD = @SHARED_LIBADD@
SHELL = @SHELL@ SHELL = @SHELL@
STRIP = @STRIP@ STRIP = @STRIP@
USE_NLS = @USE_NLS@ USE_NLS = @USE_NLS@
VERSION = @VERSION@ VERSION = @VERSION@
WARN_CFLAGS = @WARN_CFLAGS@ WARN_CFLAGS = @WARN_CFLAGS@
WIN32LDFLAGS = @WIN32LDFLAGS@
WIN32LIBADD = @WIN32LIBADD@
XGETTEXT = @XGETTEXT@ XGETTEXT = @XGETTEXT@
ac_ct_AR = @ac_ct_AR@
ac_ct_CC = @ac_ct_CC@ ac_ct_CC = @ac_ct_CC@
ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
ac_ct_RANLIB = @ac_ct_RANLIB@
ac_ct_STRIP = @ac_ct_STRIP@
am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
am__include = @am__include@ am__include = @am__include@
@ -204,9 +208,6 @@ build_os = @build_os@
build_vendor = @build_vendor@ build_vendor = @build_vendor@
cgendir = @cgendir@ cgendir = @cgendir@
datadir = @datadir@ datadir = @datadir@
datarootdir = @datarootdir@
docdir = @docdir@
dvidir = @dvidir@
exec_prefix = @exec_prefix@ exec_prefix = @exec_prefix@
host = @host@ host = @host@
host_alias = @host_alias@ host_alias = @host_alias@
@ -214,22 +215,18 @@ host_cpu = @host_cpu@
host_noncanonical = @host_noncanonical@ host_noncanonical = @host_noncanonical@
host_os = @host_os@ host_os = @host_os@
host_vendor = @host_vendor@ host_vendor = @host_vendor@
htmldir = @htmldir@
includedir = @includedir@ includedir = @includedir@
infodir = @infodir@ infodir = @infodir@
install_sh = @install_sh@ install_sh = @install_sh@
libdir = @libdir@ libdir = @libdir@
libexecdir = @libexecdir@ libexecdir = @libexecdir@
localedir = @localedir@
localstatedir = @localstatedir@ localstatedir = @localstatedir@
lt_ECHO = @lt_ECHO@ lt_ECHO = @lt_ECHO@
mandir = @mandir@ mandir = @mandir@
mkdir_p = @mkdir_p@ mkdir_p = @mkdir_p@
oldincludedir = @oldincludedir@ oldincludedir = @oldincludedir@
pdfdir = @pdfdir@
prefix = @prefix@ prefix = @prefix@
program_transform_name = @program_transform_name@ program_transform_name = @program_transform_name@
psdir = @psdir@
sbindir = @sbindir@ sbindir = @sbindir@
sharedstatedir = @sharedstatedir@ sharedstatedir = @sharedstatedir@
sysconfdir = @sysconfdir@ sysconfdir = @sysconfdir@
@ -590,10 +587,11 @@ libopcodes_la_SOURCES = dis-buf.c disassemble.c dis-init.c
# Unfortunately this causes libtool to add -L$(libdir), referring to the # Unfortunately this causes libtool to add -L$(libdir), referring to the
# planned install directory of libbfd. This can cause us to pick up an # planned install directory of libbfd. This can cause us to pick up an
# old version of libbfd, or to pick up libbfd for the wrong architecture # old version of libbfd, or to pick up libbfd for the wrong architecture
# if host != build. # if host != build. So for building with shared libraries we use a
libopcodes_la_DEPENDENCIES = $(OFILES) # hardcoded path to libbfd.so instead of relying on the entries in libbfd.la.
libopcodes_la_LIBADD = $(OFILES) @WIN32LIBADD@ libopcodes_la_DEPENDENCIES = $(OFILES) @SHARED_DEPENDENCIES@
libopcodes_la_LDFLAGS = -release `cat ../bfd/libtool-soversion` @WIN32LDFLAGS@ libopcodes_la_LIBADD = $(OFILES) @SHARED_LIBADD@
libopcodes_la_LDFLAGS = -release `cat ../bfd/libtool-soversion` @SHARED_LDFLAGS@
# libtool will build .libs/libopcodes.a. We create libopcodes.a in # libtool will build .libs/libopcodes.a. We create libopcodes.a in
# the build directory so that we don't have to convert all the # the build directory so that we don't have to convert all the
@ -652,15 +650,15 @@ $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__confi
@for dep in $?; do \ @for dep in $?; do \
case '$(am__configure_deps)' in \ case '$(am__configure_deps)' in \
*$$dep*) \ *$$dep*) \
echo ' cd $(srcdir) && $(AUTOMAKE) --cygnus '; \ echo ' cd $(srcdir) && $(AUTOMAKE) --foreign '; \
cd $(srcdir) && $(AUTOMAKE) --cygnus \ cd $(srcdir) && $(AUTOMAKE) --foreign \
&& exit 0; \ && exit 0; \
exit 1;; \ exit 1;; \
esac; \ esac; \
done; \ done; \
echo ' cd $(top_srcdir) && $(AUTOMAKE) --cygnus Makefile'; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \
cd $(top_srcdir) && \ cd $(top_srcdir) && \
$(AUTOMAKE) --cygnus Makefile $(AUTOMAKE) --foreign Makefile
.PRECIOUS: Makefile .PRECIOUS: Makefile
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
@case '$?' in \ @case '$?' in \

35
opcodes/configure vendored
View file

@ -458,7 +458,7 @@ ac_includes_default="\
# include <unistd.h> # include <unistd.h>
#endif" #endif"
ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE AR ac_ct_AR RANLIB ac_ct_RANLIB LIBTOOL SED EGREP FGREP GREP LD DUMPBIN ac_ct_DUMPBIN NM LN_S lt_ECHO CPP WARN_CFLAGS NO_WERROR MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT INSTALL_LIBBFD_TRUE INSTALL_LIBBFD_FALSE host_noncanonical target_noncanonical bfdlibdir bfdincludedir USE_NLS LIBINTL LIBINTL_DEP INCINTL XGETTEXT GMSGFMT POSUB CATALOGS DATADIRNAME INSTOBJEXT GENCAT CATOBJEXT MKINSTALLDIRS MSGFMT MSGMERGE CC_FOR_BUILD EXEEXT_FOR_BUILD HDEFINES CGEN_MAINT_TRUE CGEN_MAINT_FALSE cgendir WIN32LDFLAGS WIN32LIBADD archdefs BFD_MACHINES LIBOBJS LTLIBOBJS' ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE AR ac_ct_AR RANLIB ac_ct_RANLIB LIBTOOL SED EGREP FGREP GREP LD DUMPBIN ac_ct_DUMPBIN NM LN_S lt_ECHO CPP WARN_CFLAGS NO_WERROR MAINTAINER_MODE_TRUE MAINTAINER_MODE_FALSE MAINT INSTALL_LIBBFD_TRUE INSTALL_LIBBFD_FALSE host_noncanonical target_noncanonical bfdlibdir bfdincludedir USE_NLS LIBINTL LIBINTL_DEP INCINTL XGETTEXT GMSGFMT POSUB CATALOGS DATADIRNAME INSTOBJEXT GENCAT CATOBJEXT MKINSTALLDIRS MSGFMT MSGMERGE CC_FOR_BUILD EXEEXT_FOR_BUILD HDEFINES CGEN_MAINT_TRUE CGEN_MAINT_FALSE cgendir SHARED_LDFLAGS SHARED_LIBADD SHARED_DEPENDENCIES archdefs BFD_MACHINES LIBOBJS LTLIBOBJS'
ac_subst_files='' ac_subst_files=''
# Initialize some variables set by options. # Initialize some variables set by options.
@ -11433,17 +11433,23 @@ fi
using_cgen=no using_cgen=no
# Horrible hacks to build DLLs on Windows. # Horrible hacks to build DLLs on Windows and a shared library elsewhere.
WIN32LDFLAGS= SHARED_LDFLAGS=
WIN32LIBADD= SHARED_LIBADD=
case "${host}" in SHARED_DEPENDENCIES=
*-*-cygwin*) if test "$enable_shared" = "yes"; then
if test "$enable_shared" = "yes"; then case "${host}" in
WIN32LDFLAGS="-no-undefined" *-*-cygwin*)
WIN32LIBADD="-L`pwd`/../bfd -lbfd -L`pwd`/../libiberty -liberty -L`pwd`/../intl -lintl -lcygwin" SHARED_LDFLAGS="-no-undefined"
fi SHARED_LIBADD="-L`pwd`/../bfd -lbfd -L`pwd`/../libiberty -liberty -L`pwd`/../intl -lintl -lcygwin"
;; ;;
esac *)
SHARED_LIBADD="-Wl,`pwd`/../bfd/.libs/libbfd.so"
SHARED_DEPENDENCIES="`pwd`/../bfd/.libs/libbfd.la"
;;
esac
fi
@ -12625,8 +12631,9 @@ s,@HDEFINES@,$HDEFINES,;t t
s,@CGEN_MAINT_TRUE@,$CGEN_MAINT_TRUE,;t t s,@CGEN_MAINT_TRUE@,$CGEN_MAINT_TRUE,;t t
s,@CGEN_MAINT_FALSE@,$CGEN_MAINT_FALSE,;t t s,@CGEN_MAINT_FALSE@,$CGEN_MAINT_FALSE,;t t
s,@cgendir@,$cgendir,;t t s,@cgendir@,$cgendir,;t t
s,@WIN32LDFLAGS@,$WIN32LDFLAGS,;t t s,@SHARED_LDFLAGS@,$SHARED_LDFLAGS,;t t
s,@WIN32LIBADD@,$WIN32LIBADD,;t t s,@SHARED_LIBADD@,$SHARED_LIBADD,;t t
s,@SHARED_DEPENDENCIES@,$SHARED_DEPENDENCIES,;t t
s,@archdefs@,$archdefs,;t t s,@archdefs@,$archdefs,;t t
s,@BFD_MACHINES@,$BFD_MACHINES,;t t s,@BFD_MACHINES@,$BFD_MACHINES,;t t
s,@LIBOBJS@,$LIBOBJS,;t t s,@LIBOBJS@,$LIBOBJS,;t t

View file

@ -97,19 +97,25 @@ AC_SUBST(cgendir)
using_cgen=no using_cgen=no
# Horrible hacks to build DLLs on Windows. # Horrible hacks to build DLLs on Windows and a shared library elsewhere.
WIN32LDFLAGS= SHARED_LDFLAGS=
WIN32LIBADD= SHARED_LIBADD=
case "${host}" in SHARED_DEPENDENCIES=
*-*-cygwin*) if test "$enable_shared" = "yes"; then
if test "$enable_shared" = "yes"; then case "${host}" in
WIN32LDFLAGS="-no-undefined" *-*-cygwin*)
WIN32LIBADD="-L`pwd`/../bfd -lbfd -L`pwd`/../libiberty -liberty -L`pwd`/../intl -lintl -lcygwin" SHARED_LDFLAGS="-no-undefined"
fi SHARED_LIBADD="-L`pwd`/../bfd -lbfd -L`pwd`/../libiberty -liberty -L`pwd`/../intl -lintl -lcygwin"
;; ;;
esac *)
AC_SUBST(WIN32LDFLAGS) SHARED_LIBADD="-Wl,`pwd`/../bfd/.libs/libbfd.so"
AC_SUBST(WIN32LIBADD) SHARED_DEPENDENCIES="`pwd`/../bfd/.libs/libbfd.la"
;;
esac
fi
AC_SUBST(SHARED_LDFLAGS)
AC_SUBST(SHARED_LIBADD)
AC_SUBST(SHARED_DEPENDENCIES)
# target-specific stuff: # target-specific stuff: