Comments (21)
It seems that you don't install thrift. Can you give us more compile information?
from pinpoint-c-agent.
we alwayz get the error message during compiled php-agent.
can anybody help us?
env:
centos 7
php 7.2.9
nginx 1.12.1
boost 1.5.8
thrift 0.11
gcc 6.1
[root@www pinpoint_php]# ./Build.sh
- SOURCE=./Build.sh
- '[' -h ./Build.sh ']'
+++ dirname ./Build.sh
++ cd -P .
++ pwd - DIR=/home/apm/pinpoint-c-agent/pinpoint_php
- source /home/apm/pinpoint-c-agent/pinpoint_php/../bin/env.sh
++ SOURCE=/home/apm/pinpoint-c-agent/pinpoint_php/../bin/env.sh
++ '[' -h /home/apm/pinpoint-c-agent/pinpoint_php/../bin/env.sh ']'
++++ dirname /home/apm/pinpoint-c-agent/pinpoint_php/../bin/env.sh
+++ cd -P /home/apm/pinpoint-c-agent/pinpoint_php/../bin
+++ pwd
++ DIR=/home/apm/pinpoint-c-agent/bin
++++ dirname /home/apm/pinpoint-c-agent/bin
+++ cd -P /home/apm/pinpoint-c-agent
+++ pwd
++ PROJECT_DIR=/home/apm/pinpoint-c-agent
++ PINPOINT_PHP_DIR=/home/apm/pinpoint-c-agent/pinpoint_php
++ PINPOINT_COMMON_DIR=/home/apm/pinpoint-c-agent/pinpoint_common
++ TP_DIR=/home/apm/pinpoint-c-agent/thirdparty
++ TP_PREFIX=/home/apm/pinpoint-c-agent/thirdparty/var
++ THRIFT_DIR=/home/apm/pinpoint-c-agent/thirdparty/thrift
++ BOOST_DIR=/home/apm/pinpoint-c-agent/thirdparty/boost - SHOW_HELP=NO
- JUST_CLEAN=NO
- WITH_DEBUG=NO
- MAKE_PARAS=
- WITH_GCOV=NO
- WITH_CI=NO
- RELEASE=NO
- main
- init_env
- export DISABLE_64BIT=NO
- DISABLE_64BIT=NO
- export DEBUG_FLAG=NO
- DEBUG_FLAG=NO
- [[ -d /include/boost ]]
- [[ -d /usr/local/boost/include/boost ]]
- [[ -d /usr/local/thrift/include/thrift ]]
- echo WITH_BOOST_PATH=/usr/local/boost
WITH_BOOST_PATH=/usr/local/boost - echo WITH_THRIFT_PATH=/usr/local/thrift
WITH_THRIFT_PATH=/usr/local/thrift - echo 'built common library ...'
built common library ... - '[' -z '' ']'
++ cat /proc/cpuinfo
++ grep processor
++ wc -l - export CPUNUM=4
- CPUNUM=4
- phpize -v
Configuring for:
PHP Api Version: 20170718
Zend Module Api No: 20170718
Zend Extension Api No: 320170718 - read_cmd
- '[' NO = YES ']'
- '[' NO = YES ']'
- '[' NO = YES ']'
- '[' NO = YES ']'
- echo 'none gcov '
none gcov - build_common
- cd /home/apm/pinpoint-c-agent/pinpoint_common
- make all -j4
g++ -c -fPIC -Wall -O3 -DNDEBUG -Werror -isystem /usr/local/boost/include -isystem /usr/local/thrift/include -L/usr/local/boost/lib -L/usr/local/thrift/lib -o serializer.o serializer.cpp
g++ -c -fPIC -Wall -O3 -DNDEBUG -Werror -isystem /usr/local/boost/include -isystem /usr/local/thrift/include -L/usr/local/boost/lib -L/usr/local/thrift/lib -o trace_data_sender.o trace_data_sender.cpp
serializer.cpp: 在构造函数‘Pinpoint::Agent::HeaderTBaseSerializer::HeaderTBaseSerializer()’中:
serializer.cpp:117:103: 错误:对‘apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport::TCompactProtocolT(boost::shared_ptrapache::thrift::transport::TMemoryBuffer&)’的调用没有匹配的函数
transportOut(new TMemoryBuffer()), protocolOut(new TCompactProtocol(this->transportOut))
^
In file included from serializer.h:24:0,
from serializer.cpp:18:
/usr/local/include/thrift/protocol/TCompactProtocol.h:89:3: 附注:candidate: apache::thrift::protocol::TCompactProtocolT<Transport_>::TCompactProtocolT(std::shared_ptr<Tp1>, int32_t, int32_t) [with Transport = apache::thrift::transport::TTransport; int32_t = int]
TCompactProtocolT(stdcxx::shared_ptr<Transport_> trans,
^~~~~~~~~~~~~~~~~
/usr/local/include/thrift/protocol/TCompactProtocol.h:89:3: 附注: 备选需要 3 实参,但提供了 1 个
/usr/local/include/thrift/protocol/TCompactProtocol.h:77:3: 附注:candidate: apache::thrift::protocol::TCompactProtocolT<Transport_>::TCompactProtocolT(std::shared_ptr<Tp1>) [with Transport = apache::thrift::transport::TTransport]
TCompactProtocolT(stdcxx::shared_ptr<Transport_> trans)
^~~~~~~~~~~~~~~~~
/usr/local/include/thrift/protocol/TCompactProtocol.h:77:3: 附注: no known conversion for argument 1 from ‘boost::shared_ptrapache::thrift::transport::TMemoryBuffer’ to ‘std::shared_ptrapache::thrift::transport::TTransport’
/usr/local/include/thrift/protocol/TCompactProtocol.h:36:7: 附注:candidate: apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport::TCompactProtocolT(const apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport&)
class TCompactProtocolT : public TVirtualProtocol<TCompactProtocolT<Transport_> > {
^~~~~~~~~~~~~~~~~
/usr/local/include/thrift/protocol/TCompactProtocol.h:36:7: 附注: no known conversion for argument 1 from ‘boost::shared_ptrapache::thrift::transport::TMemoryBuffer’ to ‘const apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport&’
serializer.cpp: 在构造函数‘Pinpoint::Agent::HeaderTBaseDeSerializer::HeaderTBaseDeSerializer()’中:
serializer.cpp:161:103: 错误:对‘apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport::TCompactProtocolT(boost::shared_ptrapache::thrift::transport::TMemoryBuffer&)’的调用没有匹配的函数
transportOut(new TMemoryBuffer()), protocolOut(new TCompactProtocol(this->transportOut))
^
In file included from serializer.h:24:0,
from serializer.cpp:18:
/usr/local/include/thrift/protocol/TCompactProtocol.h:89:3: 附注:candidate: apache::thrift::protocol::TCompactProtocolT<Transport_>::TCompactProtocolT(std::shared_ptr<Tp1>, int32_t, int32_t) [with Transport = apache::thrift::transport::TTransport; int32_t = int]
TCompactProtocolT(stdcxx::shared_ptr<Transport_> trans,
^~~~~~~~~~~~~~~~~
/usr/local/include/thrift/protocol/TCompactProtocol.h:89:3: 附注: 备选需要 3 实参,但提供了 1 个
/usr/local/include/thrift/protocol/TCompactProtocol.h:77:3: 附注:candidate: apache::thrift::protocol::TCompactProtocolT<Transport_>::TCompactProtocolT(std::shared_ptr<Tp1>) [with Transport = apache::thrift::transport::TTransport]
TCompactProtocolT(stdcxx::shared_ptr<Transport_> trans)
^~~~~~~~~~~~~~~~~
/usr/local/include/thrift/protocol/TCompactProtocol.h:77:3: 附注: no known conversion for argument 1 from ‘boost::shared_ptrapache::thrift::transport::TMemoryBuffer’ to ‘std::shared_ptrapache::thrift::transport::TTransport’
/usr/local/include/thrift/protocol/TCompactProtocol.h:36:7: 附注:candidate: apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport::TCompactProtocolT(const apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport&)
class TCompactProtocolT : public TVirtualProtocol<TCompactProtocolT<Transport_> > {
^~~~~~~~~~~~~~~~~
/usr/local/include/thrift/protocol/TCompactProtocol.h:36:7: 附注: no known conversion for argument 1 from ‘boost::shared_ptrapache::thrift::transport::TMemoryBuffer’ to ‘const apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport&’
make: *** [serializer.o] 错误 1
make: *** 正在等待未完成的任务....
trace_data_sender.cpp: 在成员函数‘int32_t Pinpoint::Agent::TraceDataSender::init()’中:
trace_data_sender.cpp:53:89: 错误:对‘apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport::TCompactProtocolT(boost::shared_ptrapache::thrift::transport::TMemoryBuffer&)’的调用没有匹配的函数
TCompactProtocol *tp = new(std::nothrow) TCompactProtocol(this->transportOut);
^
In file included from trace_data_sender.h:19:0,
from trace_data_sender.cpp:16:
/usr/local/include/thrift/protocol/TCompactProtocol.h:89:3: 附注:candidate: apache::thrift::protocol::TCompactProtocolT<Transport_>::TCompactProtocolT(std::shared_ptr<Tp1>, int32_t, int32_t) [with Transport = apache::thrift::transport::TTransport; int32_t = int]
TCompactProtocolT(stdcxx::shared_ptr<Transport_> trans,
^~~~~~~~~~~~~~~~~
/usr/local/include/thrift/protocol/TCompactProtocol.h:89:3: 附注: 备选需要 3 实参,但提供了 1 个
/usr/local/include/thrift/protocol/TCompactProtocol.h:77:3: 附注:candidate: apache::thrift::protocol::TCompactProtocolT<Transport_>::TCompactProtocolT(std::shared_ptr<Tp1>) [with Transport = apache::thrift::transport::TTransport]
TCompactProtocolT(stdcxx::shared_ptr<Transport_> trans)
^~~~~~~~~~~~~~~~~
/usr/local/include/thrift/protocol/TCompactProtocol.h:77:3: 附注: no known conversion for argument 1 from ‘boost::shared_ptrapache::thrift::transport::TMemoryBuffer’ to ‘std::shared_ptrapache::thrift::transport::TTransport’
/usr/local/include/thrift/protocol/TCompactProtocol.h:36:7: 附注:candidate: apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport::TCompactProtocolT(const apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport&)
class TCompactProtocolT : public TVirtualProtocol<TCompactProtocolT<Transport_> > {
^~~~~~~~~~~~~~~~~
/usr/local/include/thrift/protocol/TCompactProtocol.h:36:7: 附注: no known conversion for argument 1 from ‘boost::shared_ptrapache::thrift::transport::TMemoryBuffer’ to ‘const apache::thrift::protocol::TCompactProtocolTapache::thrift::transport::TTransport&’
make: *** [trace_data_sender.o] 错误 1
from pinpoint-c-agent.
@6666422 Do you install thrift here: /usr/local/thrift? Can you show its version?
from pinpoint-c-agent.
yes, as following:
[root@www pinpoint_php]# protoc --version
libprotoc 3.5.0
[root@www pinpoint_php]# thrift --version
Thrift version 0.11.0
[root@www pinpoint_php]# whereis thrift
thrift: /usr/bin/thrift /usr/local/bin/thrift /usr/include/thrift /usr/local/thrift
from pinpoint-c-agent.
@6666422
It seems that there are multi thrift installed in your server. Please set WITH_THRIFT_PATH to the right path.
from pinpoint-c-agent.
@ChenGXQQ
no, no, had set up the path.
[root@www pinpoint_php]# echo $WITH_THRIFT_PATH
/usr/local/thrift
from pinpoint-c-agent.
@6666422
Please show me this file: $WITH_THRIFT_PATH/config.h
from pinpoint-c-agent.
@6666422
Please try 'export $WITH_THRIFT_PATH=/usr '
from pinpoint-c-agent.
@EyelynSu set it, also set '$WITH_BOOST_PATH=/usr', get the message, what we lose to install something?
- make all -j4
g++ -c -fPIC -Wall -O3 -DNDEBUG -isystem /usr/include -isystem /usr/include -L/usr/lib -L/usr/lib -o serializer.o serializer.cpp
g++ -c -fPIC -Wall -O3 -DNDEBUG -isystem /usr/include -isystem /usr/include -L/usr/lib -L/usr/lib -o trace_data_sender.o trace_data_sender.cpp
In file included from /usr/local/include/c++/6.1.0/ext/string_conversions.h:41:0,
from /usr/local/include/c++/6.1.0/bits/basic_string.h:5402,
from /usr/local/include/c++/6.1.0/string:52,
from /usr/include/thrift/Thrift.h:37,
from /usr/include/thrift/transport/TTransport.h:23,
from /usr/include/thrift/protocol/TProtocol.h:23,
from /usr/include/thrift/protocol/TVirtualProtocol.h:23,
from /usr/include/thrift/protocol/TCompactProtocol.h:23,
from trace_data_sender.h:19,
from trace_data_sender.cpp:16:
/usr/local/include/c++/6.1.0/cstdlib:75:25: 致命错误:stdlib.h:没有那个文件或目录
#include_next <stdlib.h>
^
编译中断。
from pinpoint-c-agent.
@6666422
Could please show us your 'ls /usr/include/'?
from pinpoint-c-agent.
@6666422
I recommand that you use our auto-install script. Delete WITH_BOOST_PATH and WITH_THRIFT_PATH. The script will install thrift and boost automaticly.
from pinpoint-c-agent.
@EyelynSu
here is the result.
[root@www ~]# ls /usr/include/boost
accumulators filesystem memory_order.hpp regex.hpp
algorithm filesystem.hpp move scoped_array.hpp
aligned_storage.hpp flyweight mpi scoped_ptr.hpp
any.hpp flyweight.hpp mpi.hpp scope_exit.hpp
archive foreach_fwd.hpp mpl serialization
array.hpp foreach.hpp msm shared_array.hpp
asio format multi_array shared_container_iterator.hpp
asio.hpp format.hpp multi_array.hpp shared_ptr.hpp
assert.hpp function multi_index signal.hpp
assign functional multi_index_container_fwd.hpp signals
assign.hpp functional.hpp multi_index_container.hpp signals2
atomic function_equal.hpp multiprecision signals2.hpp
atomic.hpp function.hpp next_prior.hpp signals.hpp
bimap function_output_iterator.hpp noncopyable.hpp smart_ptr
bimap.hpp function_types nondet_random.hpp smart_ptr.hpp
bind fusion none.hpp spirit
bind.hpp generator_iterator.hpp none_t.hpp spirit.hpp
blank_fwd.hpp geometry non_type.hpp statechart
blank.hpp geometry.hpp numeric static_assert.hpp
call_traits.hpp get_pointer.hpp operators.hpp strong_typedef.hpp
cast.hpp gil optional swap.hpp
cerrno.hpp graph optional.hpp system
checked_delete.hpp heap parameter test
chrono icl parameter.hpp thread
chrono.hpp implicit_cast.hpp pending thread.hpp
circular_buffer indirect_reference.hpp phoenix throw_exception.hpp
circular_buffer_fwd.hpp integer phoenix.hpp timer
circular_buffer.hpp integer_fwd.hpp pointee.hpp timer.hpp
compatibility integer.hpp pointer_cast.hpp token_functions.hpp
compressed_pair.hpp integer_traits.hpp pointer_to_other.hpp token_iterator.hpp
concept interprocess polygon tokenizer.hpp
concept_archetype.hpp intrusive pool tr1
concept_check intrusive_ptr.hpp preprocessor tuple
concept_check.hpp io preprocessor.hpp type.hpp
config io_fwd.hpp program_options typeof
config.hpp iostreams program_options.hpp type_traits
container is_placeholder.hpp progress.hpp type_traits.hpp
context iterator property_map units
coroutine iterator_adaptors.hpp property_tree unordered
crc.hpp iterator.hpp proto unordered_map.hpp
cregex.hpp lambda ptr_container unordered_set.hpp
cstdint.hpp last_value.hpp python utility
cstdlib.hpp lexical_cast.hpp python.hpp utility.hpp
current_function.hpp limits.hpp random uuid
date_time locale random.hpp variant
date_time.hpp locale.hpp range variant.hpp
detail local_function range.hpp version.hpp
dynamic_bitset local_function.hpp ratio visit_each.hpp
dynamic_bitset_fwd.hpp lockfree ratio.hpp wave
dynamic_bitset.hpp logic rational.hpp wave.hpp
enable_shared_from_this.hpp make_shared.hpp ref.hpp weak_ptr.hpp
exception math regex xpressive
exception.hpp math_fwd.hpp regex_fwd.hpp
exception_ptr.hpp mem_fn.hpp regex.h
[root@www ~]# ls /usr/include/thrift
async config.h protocol TApplicationException.h Thrift.h transport
c_glib cxxfunctional.h qt TDispatchProcessor.h TLogging.h TReflectionLocal.h
concurrency processor server thrift-config.h TProcessor.h
from pinpoint-c-agent.
@ChenGXQQ I just do it according the guide, but Build.sh should be in pinpoint_php folder.
from pinpoint-c-agent.
@6666422 If you set the env variables WITH_BOOST_PATH and WITH_THRIFT_PATH, it will use your libraries. Unset the two variables and let the script downloads and compile these libraries automaticly.
from pinpoint-c-agent.
I'm wondering if the problem is related to gcc>4.
I'll try to rebuild the module with gcc4 with the same procedure.
from pinpoint-c-agent.
I found out that GCC >= 4.7 is C++11 (https://gcc.gnu.org/projects/cxx-status.html#cxx11)
When c++11 flags are enable, it offers have full support for std::shared_ptr.
This is the reason thrift is build with std::shared_ptr instead of boost::shared_ptr :-(
To allow thrift to be build with boost::shared_ptr, we have to build thrift with "#define FORCE_BOOST_SMART_PTR" in thrift/stdcxx.h ( See thrift/stdcxx.h for more.)
Refs:
https://jira.apache.org/jira/browse/THRIFT-2221
https://thrift.apache.org/lib/cpp
https://gcc.gnu.org/projects/cxx-status.html#cxx11
Please note you have to apply this patch too to fix some errors too :
--- a/pinpoint_common/Makefile
+++ b/pinpoint_common/Makefile
@@ -16,12 +16,12 @@ ifeq ($(RUN_TEST),1)
CPPFLAGS+=-g3 -DRUN_TEST -DDEBUG $(RUN_TEST_FLAGS)
else ifeq ($(DEBUG), YES)
# debug
- CFLAGS+=-g3 -DDEBUG -Werror
- CPPFLAGS+=-g3 -DDEBUG -Werror
+ CFLAGS+=-g3 -DDEBUG
+ CPPFLAGS+=-g3 -DDEBUG
else
# release
- CFLAGS+=-O3 -DNDEBUG -Werror
- CPPFLAGS+=-O3 -DNDEBUG -Werror
+ CFLAGS+=-O3 -DNDEBUG
+ CPPFLAGS+=-O3 -DNDEBUG
endif
ifeq ($(WITH_BOOST_PATH), $(wildcard $(WITH_BOOST_PATH)))
diff --git a/pinpoint_common/utility.cpp b/pinpoint_common/utility.cpp
index 00683d1..da25012 100644
--- a/pinpoint_common/utility.cpp
+++ b/pinpoint_common/utility.cpp
@@ -331,7 +331,7 @@ namespace Pinpoint
const char* p = value.c_str();
/* skip space */
- for (; p != '\0' && ((char)*p == ' ' || (char)*p == '\t'); p++)
+ for (; p != NULL && ((char)*p == ' ' || (char)*p == '\t'); p++)
;
if (strlen(p) == 0)
diff --git a/pinpoint_php/php_common.cpp b/pinpoint_php/php_common.cpp
index 10e9b83..923366b 100644
--- a/pinpoint_php/php_common.cpp
+++ b/pinpoint_php/php_common.cpp
@@ -74,7 +74,7 @@ static inline std::string getNameFromHeaderMap(const char* pstr)
static uint32_t find_first_of_char(const char*pstr, uint32_t strLen ,char C)
{
uint32_t i =0;
- for( ;pstr != '\0' && i < strLen ;pstr++,i++)
+ for( ;pstr != NULL && i < strLen ;pstr++,i++)
{
if((char)*pstr == C)
break;
Here is my build procedure too:
mkdir -p $HOME/tmp/pp-php72/tgz
mkdir -p $HOME/tmp/pp-php72/3rd-build
mkdir -p $HOME/tmp/pp-php72/3rd-install
cd $HOME/tmp/pp-php72/tgz
wget "https://dl.bintray.com/boostorg/release/1.63.0/source/boost_1_63_0.tar.bz2"
wget "http://apache.crihan.fr/dist/thrift/0.11.0/thrift-0.11.0.tar.gz"
cd $HOME/tmp/pp-php72/3rd-build
tar xvfj ../tgz/boost_1_63_0.tar.bz2
tar xvfz ../tgz/thrift-0.11.0.tar.gz
ln -s thrift-0.11.0 thrift
ln -s boost_1_63_0 boost
cd boost
./bootstrap.sh
./b2 install --prefix=$HOME/tmp/pp-php72/3rd-install/boost
cd ../thrift
./configure --with-cpp=yes --with-go=no --with-csharp=no --with-php=no --with-python=no --with-nodejs=no --with-lua=no --with-boost=$HOME/tmp/pp-php72/3rd-install/boost --prefix=$HOME/tmp/pp-php72/3rd-install/thrift
cd $HOME/tmp/pp-php72/
git clone https://github.com/naver/pinpoint-c-agent.git
cd pinpoint-c-agent/pinpoint_php
export WITH_THRIFT_PATH=$HOME/tmp/pp-php72/3rd-install/thrift
export WITH_BOOST_PATH=$HOME/tmp/pp-php72/3rd-install/boost
./Build.sh
At the moment, I could build the pinpoint php module, but I could not run it because of some inconsistancies on its dependancies:
[olivier@psx pinpoint_php]$ ldd /home/olivier/tmp/pp-php72/pinpoint-c-agent/pinpoint_php/modules/pinpoint.so | egrep "(boost|thr)"
libboost_system.so.1.63.0 => not found
libboost_thread.so.1.63.0 => not found
libboost_filesystem.so.1.63.0 => not found
libboost_date_time.so.1.63.0 => not found
libthrift-0.11.0.so => /home/XXXX/tmp/pp-php72/3rd-install/thrift/lib/libthrift-0.11.0.so (0x00007fc2b40f9000)
I'd be great if boost and thrift code are embedded in the .so itself instead ...
I'll continue working on that.
Hope that helps
Olivier Fauchon
from pinpoint-c-agent.
@ofauchon
Thanks for your help. Your information is useful for us to make full compatibility with C++11.
from pinpoint-c-agent.
Hi,
I could build pinpoint php agent on Arch Linux...
But the module is linked to the custom thrift/boost libraries (see above)
Is it possible to static link boost/thrift to the pinpoint php module ?
Thanks
Olivier
ldd /home/olivier/dev/BUILD-PP-PHP/build/pinpoint-c-agent-ArchBuild/pinpoint_php/modules/pinpoint.so
linux-vdso.so.1 (0x00007ffc879a5000)
libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00007f64a5cb0000)
libboost_system.so.1.63.0 => /home/olivier/dev/BUILD-PP-PHP/install/lib/libboost_system.so.1.63.0 (0x00007f64a5aac000)
libboost_thread.so.1.63.0 => /home/olivier/dev/BUILD-PP-PHP/install/lib/libboost_thread.so.1.63.0 (0x00007f64a5884000)
libboost_filesystem.so.1.63.0 => /home/olivier/dev/BUILD-PP-PHP/install/lib/libboost_filesystem.so.1.63.0 (0x00007f64a566b000)
libboost_date_time.so.1.63.0 => /home/olivier/dev/BUILD-PP-PHP/install/lib/libboost_date_time.so.1.63.0 (0x00007f64a5459000)
libthrift-0.11.0.so => /home/olivier/dev/BUILD-PP-PHP/install/lib/libthrift-0.11.0.so (0x00007f64a50e6000)
libm.so.6 => /usr/lib/libm.so.6 (0x00007f64a4d9a000)
libgcc_s.so.1 => /usr/lib/libgcc_s.so.1 (0x00007f64a4b83000)
libc.so.6 => /usr/lib/libc.so.6 (0x00007f64a47cb000)
/usr/lib64/ld-linux-x86-64.so.2 (0x00007f64a63eb000)
librt.so.1 => /usr/lib/librt.so.1 (0x00007f64a45c3000)
libpthread.so.0 => /usr/lib/libpthread.so.0 (0x00007f64a43a5000)
libssl.so.1.1 => /usr/lib/libssl.so.1.1 (0x00007f64a413b000)
libcrypto.so.1.1 => /usr/lib/libcrypto.so.1.1 (0x00007f64a3cbe000)
libdl.so.2 => /usr/lib/libdl.so.2 (0x00007f64a3aba000)
from pinpoint-c-agent.
I could compile pinpoint.so with thrift/boost embedded by hand :
[olivier@royale pinpoint_php]$ cc -shared .libs/pinpoint_ext.o .libs/aop_hook.o .libs/interceptor.o .libs/php_common.o .libs/php_plugin.o .libs/php_interfaces.o .libs/php_function_helper.o plugins/.libs/request_plugin.o plugins/.libs/internel_functions_plugin.o -Wl,--rpath -Wl,/home/olivier/dev/BUILD-PP-PHP/install/lib -Wl,--rpath -Wl,/home/olivier/dev/BUILD-PP-PHP/install/lib -lstdc++ -L/home/olivier/dev/BUILD-PP-PHP/build/pinpoint-c-agent-ArchBuild/pinpoint_common -lpinpoint_common -L/home/olivier/dev/BUILD-PP-PHP/install/lib ../../../install/lib/libthrift.a ../../../install/lib/libboost_*a -lm -Wl,-soname -Wl,pinpoint.so -o .libs/pinpoint.so
[olivier@royale pinpoint_php]$ ldd .libs/pinpoint.so
linux-vdso.so.1 (0x00007ffea179f000)
libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00007f6d91544000)
libm.so.6 => /usr/lib/libm.so.6 (0x00007f6d911f8000)
libgcc_s.so.1 => /usr/lib/libgcc_s.so.1 (0x00007f6d90fe1000)
libc.so.6 => /usr/lib/libc.so.6 (0x00007f6d90c29000)
/usr/lib64/ld-linux-x86-64.so.2 (0x00007f6d91ca9000)
... But this requires to build boost and thrift with "-fPIC"
(boost) ./b2 cxxflags=-fPIC cflags=-fPIC install --prefix=$WD/install
(thrift) ./configure CXXFLAGS='-DFORCE_BOOST_SMART_PTR -fPIC' -with-cpp=yes --enable-shared --with-pic --with-c_glib=no --with-go=no --with-csharp=no --with-php=no --with-python=no --with-nodejs=no --with-lua=no --with-boost=$WD/install --prefix=$WD/install
from pinpoint-c-agent.
Hi,
For those wanting to build the module on Archlinux (or any other distributions),
please find the following procedure:
mkdir tmp; cd tmp
git clone https://github.com/ofauchon/pinpoint-c-agent.git
git checkout ArchBuild
cd ArchBuild
./build.sh
....
[olivier@royale ArchBuild]$ ldd ../pinpoint_php/modules/pinpoint.so
linux-vdso.so.1 (0x00007ffdf1fa4000)
libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00007f0765c4d000)
libm.so.6 => /usr/lib/libm.so.6 (0x00007f0765901000)
libgcc_s.so.1 => /usr/lib/libgcc_s.so.1 (0x00007f07656ea000)
libc.so.6 => /usr/lib/libc.so.6 (0x00007f0765332000)
/usr/lib64/ld-linux-x86-64.so.2 (0x00007f07663b2000)
Tested on versions:
PHP 7.1.12 (cli) (built: Nov 22 2017 17:43:08) ( NTS )
gcc version 7.2.0 (GCC)
glibc 2.26-6
from pinpoint-c-agent.
Hi, all
We had released https://github.com/naver/pinpoint-c-agent/releases/tag/v0.2.0. This version had removed such annoying dependencies, make agent more easy to use, hope you use it.
So I close this issue.
from pinpoint-c-agent.
Related Issues (20)
- Anyone available for consultation work for Pinpoint python agent for monitoring Django application HOT 4
- remove unique id at agent HOT 1
- send data error:(Broken pipe) fd:(16) HOT 3
- PHP agent 설치 HOT 1
- PHP Agent 설치 HOT 5
- python flask agent registry failed
- Is there a thrift version for collector agent HOT 4
- [BUG] No call chain when python application call MySql HOT 1
- [BUG] no data displying in Pinpoint Web when send requests
- I need some help HOT 66
- need some help. I use pinpointPy==1.2.0, found this: NotImplementedError("set_parent_id") HOT 2
- Not able to trace PostgreSql transactions HOT 4
- [BUG] PinpointPy error handling HOT 3
- [FEATURE] Support for psycopg2-binary HOT 3
- pinpoint-c-agent arm build HOT 3
- Method not found: v1.Agent/RequestAgentInfo HOT 4
- How Get TraceId And SpanId In Flask HOT 3
- [Python] trace exclude url HOT 4
- Python Redis HOT 1
- Redis Collections Not release HOT 10
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pinpoint-c-agent.