Compile error: cannot find Boost headers

5,603 views
Skip to first unread message

Jason Judge

unread,
Dec 5, 2011, 6:48:25 AM12/5/11
to gearman
I am new to gearman, and it looks like it will fit my needs to handle
submitting jobs (recording of payments made in a shop to a remote CRM,
with PHP at each end).

I have access to a CentOS 4.9 web server and am trying to compile
gearman on that server. The configure script gets through a lot of its
checks and falls over at this point:

checking for Boost headers version >= 1.39.0... no
configure: error: cannot find Boost headers version >= 1.39.0

I have no idea what Boost is, where the headers would be, whether the
server could ever be given Boost of the right version etc. so would
appreciate any clues as to where to go from here.

I've looked at other job queuing systems, and they are all either not
persistent,not distributed, not available under the GPL or are even
more fussy about the C libraries present. I won't be dealing with a
high load, but do want something that will just run quietly in the
background and will handle "making sure stuff happens" that is thrown
at it from various PHP applications. I have root access to the server,
but I can't be doing any big upgrades if that is the only way to solve
this problem.

Thanks.

Yernar Smagulov

unread,
Dec 5, 2011, 8:03:52 AM12/5/11
to gearman
try out this one :
$ sudo apt-get install libboost*

Jason Judge

unread,
Dec 5, 2011, 8:28:39 AM12/5/11
to gearman
We are on CentOS, not Ubuntu. We have yum available, and we are using
the atomic repositories to keep us up-to-date, but not cutting edge.

The server has this installed already:

boost.i386 1.32.0-7.rhel4
installed
boost-devel.i386 1.32.0-7.rhel4
installed

So I am guessing CentOS 4 just doesn't have boost libraries recent
enough?

Jason Judge

unread,
Dec 5, 2011, 8:43:07 AM12/5/11
to gearman
I've contacted the hosting company to see what would be involved in
taking the server up to a later version of CentOS. I'll see what comes
of that. I don't want to break all the sites on the server or take it
down for extensive testing and upgrade for this one thing.

Jason Judge

unread,
Dec 5, 2011, 9:10:26 AM12/5/11
to gearman
On Dec 5, 1:41 pm, Tobia Tesan <tobia.te...@gmail.com> wrote:

> On Mon, Dec 5, 2011 at 2:28 PM, Jason Judge <jason.dju...@gmail.com> wrote:
> > boost.i386                               1.32.0-7.rhel4
> > installed
> > boost-devel.i386                         1.32.0-7.rhel4
> > installed
>
> > So I am guessing CentOS 4 just doesn't have boost libraries recent
> > enough?
>
> Is EPEL of any help?
> If not, you may as well have to compile the thing yourself.

I've taken a look, but (if I'm understanding the structure of the
site) it is also stuck at boost 1.32 for my version of CentOS.

I don't think I want to go down the route of compiling from source,
because all that is going to do is move the problem on to to all the
missing or outdated packages that boost will inevitably depend on.
This is a live webserver so I don't want to mess around with it too
much, and I have limited time to learn a whole new area of
development. If I can't fix this quickly, I will probably to write my
own message queue (drop messages into local database tables and have
scheduled processes that move the messages to their destination server
and run the worker processes - I don't need the complete loop that
gearman provides, with results getting back to the client process, but
just a one-way queue for processes to throw stuff at then move on, and
firing up a process every 15 minutes to move messages on will not be a
problem in this application). I would come back to gearman at a later
date as it does look pretty cool.

Anyway, fingers crossed that I can find a simple solution to avoid
having to reinvent unnecessary wheels ;-)

-- Jason

Herman Radtke

unread,
Dec 5, 2011, 12:46:03 PM12/5/11
to gea...@googlegroups.com

There are a number of existing email threads that discuss how to get
around various Boost issues on CentOS.

--
Herman Radtke
herman...@gmail.com | http://hermanradtke.com

Jason Judge

unread,
Dec 5, 2011, 4:13:28 PM12/5/11
to gearman


>
> There are a number of existing email threads that discuss how to get
> around various Boost issues on CentOS.
>

I'll have a more careful dig around and see what I can find.

I did try building the boost libraries, and got a gazillion errors and
warnings. It compiled about 80% of the libraries, but I don't think I
have a hope in working out how to get it all to compile fully. It is
massive - I just assumed it was one little library, but it looks like
it is more-or-less half an operating system on its own.

-- JJ

Jason Judge

unread,
Dec 6, 2011, 6:36:18 PM12/6/11
to gearman
I found this post:

http://groups.google.com/group/gearman/browse_thread/thread/fa552d98db87b5cf/2e6205a362f8b773?lnk=gst&q=boost141#2e6205a362f8b773

which helped a lot. I had installed boost141 from EPEL repository, but
that version of boost in installed in a different directory. The post
above shows how to get around that and configure now works to enable a
build. I did not physically move the boost141 libraries so turned on --
enable-static-boost so that gearman would not have to know where those
libraries were at runtime (I hope that's what it does).

Now, when I run make, it stops with this error:

tests/stress_worker.cc: In function `test_return_t
worker_ramp_TEST(void*)':
tests/stress_worker.cc:113: error: `pthread_timedjoin_np' was not
declared in this scope
tests/stress_worker.cc:113: warning: unused variable
'pthread_timedjoin_np'
make[1]: *** [tests/stress_worker.o] Error 1
make[1]: Leaving directory `/var/www/vhosts/acadweb.co.uk/private/
gearmand-0.25'
make: *** [all] Error 2

So far as I can see, the build is not complete at this point. There is
a gearadmin and a gearman executable in the bin directory, but no
gearmand

There is nothing on the gearman threads concerning this error, so I'll
do some wider digging to see what I can find.

-- Jason


On Dec 5, 5:46 pm, Herman Radtke <hermanrad...@gmail.com> wrote:

> hermanrad...@gmail.com |http://hermanradtke.com

Reply all
Reply to author
Forward
Message has been deleted
0 new messages