ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ API Support » AIX /g++ linking problem

Post new topic  Reply to topic
 AIX /g++ linking problem « View previous topic :: View next topic » 
Author Message
mq_blr
PostPosted: Wed Nov 26, 2008 12:59 am    Post subject: AIX /g++ linking problem Reply with quote

Apprentice

Joined: 30 Sep 2005
Posts: 49
Location: Brisbane,Australia

we are using g++ (GCC) 4.2.0 complier to compile some c++ programs which is using MQ API calls in AIX 5.3.0.0 .

Compiling is OK and able to create .o files , but when we link those files using g++ -o
It is giving us errors like

ld: 0711-317 ERROR: Undefined symbol: .ImqObj::setConnectionReference(ImqMgr*)
ld: 0711-317 ERROR: Undefined symbol: typeinfo for ImqErr
ld: 0711-317 ERROR: Undefined symbol: .ImqErr::~ImqErr()
ld: 0711-317 ERROR: Undefined symbol: .ImqMgr::ImqMgr()
ld: 0711-317 ERROR: Undefined symbol: .ImqQue::ImqQue()
ld: 0711-317 ERROR: Undefined symbol: .ImqMsg::ImqMsg()
ld: 0711-317 ERROR: Undefined symbol: .ImqGmo3::ImqGmo3()
ld: 0711-317 ERROR: Undefined symbol: .ImqPmo::ImqPmo()
ld: 0711-317 ERROR: Undefined symbol: .ImqObj::setName(char const*)
ld: 0711-317 ERROR: Undefined symbol: .ImqMgr::connect()
ld: 0711-317 ERROR: Undefined symbol: .ImqObj::setOpenOptions(long)
ld: 0711-317 ERROR: Undefined symbol: .ImqObj::open()
ld: 0711-317 ERROR: Undefined symbol: .ImqCac::useEmptyBuffer(char const*, unsig
ned long)
ld: 0711-317 ERROR: Undefined symbol: .ImqMsg::setFormat(char const*)
ld: 0711-317 ERROR: Undefined symbol: .ImqCac::setMessageLength(unsigned long)
ld: 0711-317 ERROR: Undefined symbol: .ImqBin::ImqBin(void const*, unsigned long
)
ld: 0711-317 ERROR: Undefined symbol: .ImqMtr::setCorrelationId(ImqBin const&)
ld: 0711-317 ERROR: Undefined symbol: .ImqQue::put(ImqMsg&, ImqPmo&)
ld: 0711-317 ERROR: Undefined symbol: .ImqBin::~ImqBin()
ld: 0711-317 ERROR: Undefined symbol: .ImqMtr::setMessageId(unsigned char const*
)
ld: 0711-317 ERROR: Undefined symbol: .ImqQue::get(ImqMsg&, ImqGmo3&)
ld: 0711-317 ERROR: Undefined symbol: .ImqMsg::formatIs(char const*) const
ld: 0711-317 ERROR: Undefined symbol: .ImqCac::dataLength() const
ld: 0711-317 ERROR: Undefined symbol: .ImqObj::close()
ld: 0711-317 ERROR: Undefined symbol: .ImqMgr::disconnect()
ld: 0711-317 ERROR: Undefined symbol: .ImqGmo3::~ImqGmo3()
ld: 0711-317 ERROR: Undefined symbol: .ImqMsg::~ImqMsg()
ld: 0711-317 ERROR: Undefined symbol: .ImqQue::~ImqQue()
ld: 0711-317 ERROR: Undefined symbol: .ImqMgr::~ImqMgr()
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more information.


we are using the commands :-

g++ -c sample1.cpp

g++ -c sample2.cpp

g++ -o out sample1.o sample2.o -L/usr/mqm/lib64 -limqb23ia -limqb23ia_r -limqs23ia.a -limqs23ia_r.a

The required lib files exist in both /usr/mqm/lib64 and current working dir .

It seems the complier not able to find mqlibraries

Can any one able to help on this ?
IS g++ version4.2.0 will support MQ API calls on AIX 5.3.0.0


Best Regards
Durga
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Wed Nov 26, 2008 10:27 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Quote:
-limqb23ia -limqb23ia_r

I thought that mqb23ia_r was the threadsafe version of mqb23ia and as such you would only have one of them on your link table...

But my knowledge in this area is severely restricted so:
- check the programmers manual and reference

It should have enough information for you to get out of this mess.
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
RogerLacroix
PostPosted: Thu Nov 27, 2008 3:12 pm    Post subject: Re: AIX /g++ linking problem Reply with quote

Jedi Knight

Joined: 15 May 2001
Posts: 3264
Location: London, ON Canada

mq_blr wrote:
we are using g++ (GCC) 4.2.0 complier to compile some c++ programs which is using MQ API calls in AIX 5.3.0.0 .

g++ (GCC) is NOT supported on AIX (C++ linked objects are a different kind of beast).

Regards,
Roger Lacroix
_________________
Capitalware: Transforming tomorrow into today.
Connected to MQ!
Twitter
Back to top
View user's profile Send private message Visit poster's website
mq_blr
PostPosted: Sun Nov 30, 2008 4:28 pm    Post subject: Reply with quote

Apprentice

Joined: 30 Sep 2005
Posts: 49
Location: Brisbane,Australia

Thank you very much Roger.
Can you suggest any good free complier for this purpose ,
we just need to compile and link small security exit
Back to top
View user's profile Send private message
mqjeff
PostPosted: Sun Nov 30, 2008 10:14 pm    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

You're writing an exit in C++?

You need to use a supported compiler on AIX to compile any MQ applications, this includes exits. There may not be a free one.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ API Support » AIX /g++ linking problem
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.