Issue 201 in google-glog: Compilation issue

107 views
Skip to first unread message

codesite...@google.com

unread,
May 4, 2014, 4:49:15 AM5/4/14
to googl...@googlegroups.com
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 201 by limh...@gmail.com: Compilation issue
http://code.google.com/p/google-glog/issues/detail?id=201

What steps will reproduce the problem?
1. Download glog
2. ./configure
3. make

What is the expected output? What do you see instead?

/bin/bash ./libtool --tag=CXX --mode=link g++ -I/usr/local//include
-Wall -Wwrite-strings -Woverloaded-virtual -Wno-sign-compare
-DNO_FRAME_POINTER -DNDEBUG -g -O2 -o libglog.la -rpath /usr/local/lib
libglog_la-logging.lo libglog_la-raw_logging.lo libglog_la-vlog_is_on.lo
libglog_la-utilities.lo libglog_la-demangle.lo libglog_la-symbolize.lo
libglog_la-signalhandler.lo -L/usr/local//lib -lgflags -lpthread
libtool: link: g++ -fPIC -DPIC -shared -nostdlib
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../x86_64-linux-gnu/crti.o
/usr/lib/gcc/x86_64-linux-gnu/4.6/crtbeginS.o .libs/libglog_la-logging.o .libs/libglog_la-raw_logging.o .libs/libglog_la-vlog_is_on.o .libs/libglog_la-utilities.o .libs/libglog_la-demangle.o .libs/libglog_la-symbolize.o .libs/libglog_la-signalhandler.o
-L/usr/local//lib -lgflags -lpthread -L/usr/lib/gcc/x86_64-linux-gnu/4.6
-L/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../x86_64-linux-gnu
-L/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../lib -L/lib/x86_64-linux-gnu
-L/lib/../lib -L/usr/lib/x86_64-linux-gnu -L/usr/lib/../lib
-L/usr/lib/gcc/x86_64-linux-gnu/4.6/../../.. -lstdc++ -lm -lc -lgcc_s
/usr/lib/gcc/x86_64-linux-gnu/4.6/crtendS.o
/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../x86_64-linux-gnu/crtn.o -O2
-Wl,-soname -Wl,libglog.so.0 -o .libs/libglog.so.0.0.0
/usr/bin/ld: /usr/local//lib/libgflags.a(gflags.cc.o): relocation
R_X86_64_32S against `std::basic_string<char, std::char_traits<char>,
std::allocator<char> >::_Rep::_S_empty_rep_storage' can not be used when
making a shared object; recompile with -fPIC
/usr/local//lib/libgflags.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
make: *** [libglog.la] Error 1
asd@asd:~/Codes/glog-0.3.3$

What version of the product are you using? On what operating system?

glog-0.3.3

Distributor ID: Ubuntu
Description: Ubuntu 12.04.2 LTS
Release: 12.04
Codename: precise

Please provide any additional information below.



--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

codesite...@google.com

unread,
Jul 7, 2014, 8:54:26 AM7/7/14
to googl...@googlegroups.com

Comment #1 on issue 201 by cputt...@gmail.com: Compilation issue
http://code.google.com/p/google-glog/issues/detail?id=201

Same error here, building on openSUSE Tumbleweed. Build ends with

/usr/local/lib/libgflags.a: could not read symbols: Bad value
collect2: error: ld returned 1 exit status
make: *** [libglog.la] Error 1

This build attempt immediately followed building and installing gflags
2.1.1 using cmake && make && make install - there is a libgflags.a
installed at the location described. Version compatibility issue?

codesite...@google.com

unread,
Jul 15, 2014, 5:37:32 PM7/15/14
to googl...@googlegroups.com

Comment #2 on issue 201 by Dan.ori...@gmail.com: Compilation issue
http://code.google.com/p/google-glog/issues/detail?id=201

Running in to this same issue on Gentoo, same versions
Gflags 2.1.1 and glog 0.3.3

codesite...@google.com

unread,
Jul 23, 2014, 11:05:26 AM7/23/14
to googl...@googlegroups.com

Comment #3 on issue 201 by cosmin11...@gmail.com: Compilation issue
http://code.google.com/p/google-glog/issues/detail?id=201

Same issue on Ubuntu 14.04, 64 bit, g++ 4.8.2, glibc 2.19
Solved by compiling gflags-2.1.1 with -fPIC:

$ tar -xvf gflags-2.1.1.tar.gz
$ cd gflags-2.1.1 && mkdir build && cd build
$ CXXFLAGS="-fPIC" cmake .. -DGFLAGS_NAMESPACE=google
$ sudo make install

Then install glog-0.3.3 as usual.

codesite...@google.com

unread,
Dec 21, 2014, 4:42:41 AM12/21/14
to googl...@googlegroups.com

Comment #4 on issue 201 by feng9...@gmail.com: Compilation issue
https://code.google.com/p/google-glog/issues/detail?id=201

ubuntu 12.04.4 64bit
gflags 2.1.1
glog 0.3.3
same error!!!

codesite...@google.com

unread,
Jan 29, 2015, 5:34:01 PM1/29/15
to googl...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages