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 » General IBM MQ Support » Build errors on MQ7

Post new topic  Reply to topic
 Build errors on MQ7 « View previous topic :: View next topic » 
Author Message
Felix
PostPosted: Wed Jan 18, 2012 2:13 am    Post subject: Build errors on MQ7 Reply with quote

Newbie

Joined: 18 Jan 2012
Posts: 9
Location: Bangalore

We are getting errors when I try to build my Code. The details are provided below.

The following are the version details on this machine:
Code:

[root@inblr-aircvm04 Modules]# uname --all
Linux inblr-aircvm04 2.6.18-194.el5 #1 SMP Tue Mar 16 21:52:39 EDT 2010 x86_64 x86_64 x86_64 GNU/Linux

[root@inblr-aircvm04 Modules]# gcc --version
gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-48)
Copyright (C) 2006 Free Software Foundation, Inc.


The typical compiler options that are set within the make files:
Code:

CXXFLAGS = -m32

$(TARGET) : $(PROG) Main.cpp $(INCS)
        g++ $(PROG) -lpthread \
        -o $(TARGET) \
        -fsigned-char -I/opt/mqm/inc -L/opt/mqm/lib \
        -Wl,-rpath=/opt/mqm/lib -Wl,-rpath=/usr/lib -libimqc23gl -libimqb23gl -libmqic


And we are getting the following errors:
Code:

MQ.o: In function `MQmessage::MQGet(std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::basic_string<char, std::char_traits<char>, std::allocator<char> >&)':
MQ.cpp:(.text+0x9c4): undefined reference to `ImqObj::setName(char const*)'
MQ.cpp:(.text+0x9e3): undefined reference to `ImqObj::setOpenOptions(long)'
MQ.cpp:(.text+0x9f1): undefined reference to `ImqMsg::ImqMsg()'
MQ.cpp:(.text+0x9fc): undefined reference to `ImqGmo3::ImqGmo3()'
MQ.cpp:(.text+0xa3b): undefined reference to `ImqCac::useEmptyBuffer(char const*, unsigned int)'
MQ.cpp:(.text+0xa54): undefined reference to `ImqMtr::setMessageId(unsigned char const*)'
MQ.cpp:(.text+0xa6e): undefined reference to `ImqMtr::setCorrelationId(unsigned char const*)'
MQ.cpp:(.text+0xacf): undefined reference to `ImqQue::get(ImqMsg&, ImqGmo3&)'
MQ.cpp:(.text+0xaf2): undefined reference to `ImqMsg::formatIs(char const*) const'
MQ.cpp:(.text+0xb0d): undefined reference to `ImqCac::dataLength() const'
MQ.cpp:(.text+0xb5c): undefined reference to `ImqMtr::messageId() const'
MQ.cpp:(.text+0xb77): undefined reference to `ImqBin::operator=(ImqBin const&)'
MQ.cpp:(.text+0xb82): undefined reference to `ImqBin::~ImqBin()'
MQ.cpp:(.text+0xb9b): undefined reference to `ImqBin::~ImqBin()'
MQ.cpp:(.text+0xddb): undefined reference to `ImqGmo3::~ImqGmo3()'
MQ.cpp:(.text+0xdee): undefined reference to `ImqGmo3::~ImqGmo3()'
MQ.cpp:(.text+0xe2b): undefined reference to `ImqMsg::~ImqMsg()'
MQ.cpp:(.text+0xe41): undefined reference to `ImqMsg::~ImqMsg()'



Please let me know if the compiler switch options must be modified. Because the same code just compiles fine on a windows machine.

Thanks in Advance.

-
Felix
Back to top
View user's profile Send private message
mqjeff
PostPosted: Wed Jan 18, 2012 5:12 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

The C++ API is stabilized, and no features have been added to it since at least v6.0.

You're much better off using the plain C API.

That said, you appear to be trying to build a threaded application, and thus should be using the _r versions, not the regular versions.

http://publib.boulder.ibm.com/infocenter/wmqv7/v7r0/topic/com.ibm.mq.amqzan.doc/uc12460_.htm
Back to top
View user's profile Send private message
Felix
PostPosted: Thu Jan 19, 2012 10:24 pm    Post subject: Reply with quote

Newbie

Joined: 18 Jan 2012
Posts: 9
Location: Bangalore

Thank You Jeff.
I used the compiler options for 64-bit threaded application. And it compiled.
_________________
-
Felix
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 » General IBM MQ Support » Build errors on MQ7
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.