Gmail Calendar Documents Reader Web more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Autotools build system: -D*_AS_STATIC_LIBS not used for static objects
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  3 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Vladimir Panov  
View profile  
 More options Jan 1 2006, 8:17 am
Newsgroups: comp.soft-sys.ace
From: Vladimir Panov <g...@voidland.org>
Date: 1 Jan 2006 07:17:03 -0600
Local: Sun, Jan 1 2006 8:17 am
Subject: [tao-bugs] Autotools build system: -D*_AS_STATIC_LIBS not used for static objects
TAO VERSION: 1.4.8
ACE VERSION: 5.4.8

HOST MACHINE and OPERATING SYSTEM:

Any.

TARGET MACHINE and OPERATING SYSTEM, if different from HOST:

Not different.

COMPILER NAME AND VERSION (AND PATCHLEVEL):

Any.

THE $ACE_ROOT/ace/config.h FILE [if you use a link to a platform-
specific file, simply state which one]:

Not used.

THE $ACE_ROOT/include/makeinclude/platform_macros.GNU FILE [if you
use a link to a platform-specific file, simply state which one
(unless this isn't used in this case, e.g., with Microsoft Visual
C++)]:

Not used.

CONTENTS OF $ACE_ROOT/bin/MakeProjectCreator/config/default.features
(used by MPC when you generate your own makefiles):

// $Id$
// This is an automatically generated file.

ssl=0
qos=1
cidl=0
rwho=0
sctp=0

AREA/CLASS/EXAMPLE AFFECTED:

Building ACE+TAO produces undesired effects.

DOES THE PROBLEM AFFECT:
COMPILATION?
Yes

LINKING?
Yes.

EXECUTION?
Yes.

OTHER (please specify)?
Building ACE+TAO is affected.

SYNOPSIS:
When using the autotools build system on any OS/compiler, static objects are compiled without ACE_AS_STATIC_LIBS (and TAO_AS_STATIC_LIBS when
compiling TAO) defined.

DESCRIPTION:
This produces the following error messages when starting a statically linked program which uses TAO:

ACE_DLL::open failed for TAO_PI: Error: check log for details.
Unable to find service: ORBInitializer_Registry
ACE_DLL::open failed for TAO_Codeset: Error: check log for details.
Unable to find service: TAO_Codeset

These are result of the code been compiled with dlopen() invocations (as if it is in a shared library). See
ACE_wrappers/TAO/tao/ORBInitializer_Registry.cpp#PortableInterceptor::regis ter_orb_initializer(...) for the source of these error messages.

Even worse: under Linux when TAO's shared libraries are in the library search path (i.e. when dlopen() succeeds) then no error messages are printed
but the program dies with a segmentation fault.

REPEAT BY:

cd ACE_wrappers
mkdir objdir
cd objdir
../configure --enable-static
make
Now create a very simple CORBA program which which uses TAO and links with -static. Then run it.

SAMPLE FIX/WORKAROUND:

I don't have a fix. I think that you should introduce separate CPPFLAGS for static and shared objects throughout the Makefile.am's somehow.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
J.T. Conklin  
View profile  
 More options Jan 1 2006, 6:30 pm
Newsgroups: comp.soft-sys.ace
From: j...@acorntoolworks.com (J.T. Conklin)
Date: 1 Jan 2006 17:30:44 -0600
Local: Sun, Jan 1 2006 6:30 pm
Subject: Re: [tao-bugs] Autotools build system: -D*_AS_STATIC_LIBS not used for static objects
Hi,

Vladimir Panov <g...@voidland.org> writes:
> SYNOPSIS:
> When using the autotools build system on any OS/compiler, static
> objects are compiled without ACE_AS_STATIC_LIBS (and
> TAO_AS_STATIC_LIBS when compiling TAO) defined.

This is a known, but not documented limitation of the autoconf build,
which is why the AC_DISABLE_STATIC autoconf macro is used to disable
static libraries.  

The problem stems from the fact that different compiler options have
to be passed for shared and static objects, but autoconf and libtool
don't seem to have taken this use case into account.  I made a half-
hearted attempt on one of the autotools mailing lists to try to find
a solution a couple of months ago, but didn't have much luck.

I agree that being able to build both static and shared libraries in
the same configuration is valuable.  Since autoconf development and
maintenance is not sponsored, Any assistance you can offer to help us
make this happen is most welcome.  At the very least, please consider
submitting this to the DOC group bugzilla server --- as that will
ensure this won't get lost.

    --jtc

--
J.T. Conklin


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Vladimir Panov  
View profile  
 More options Feb 11 2006, 6:18 am
Newsgroups: comp.soft-sys.ace
From: Vladimir Panov <g...@voidland.org>
Date: 11 Feb 2006 05:18:55 -0600
Local: Sat, Feb 11 2006 6:18 am
Subject: Re: [tao-bugs] Autotools build system: -D*_AS_STATIC_LIBS not used for static objects

Hi, J.T.

I can propose you the following workaround:

1. Make it impossible for the user to select both --enable-static and

--enable-shared for a single run of configure.
2. If --enable-static is used, then add -DACE_AS_STATIC_LIBS and
-DTAO_AS_STATIC_LIBS to $CPPFLAGS.

Vlado


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google