Ubuntu 12.04 で XML::LibXML のインストール失敗対処

■ 事象

[email protected]:/home/daisuke# cpanm XML::LibXML::XPathContext
--> Working on XML::LibXML::XPathContext
Fetching http://www.cpan.org/authors/id/S/SH/SHLOMIF/XML-LibXML-2.0116.tar.gz ... OK
Configuring XML-LibXML-2.0116 ... N/A
! Configure failed for XML-LibXML-2.0116. See /root/.cpanm/work/1405829332.1753/build.log for details.
[email protected]:/home/daisuke# less ~/.cpanm/work/1405829332.1753/build.log

■ ヒント
build.logから

Checking for ability to link against xml2...no
Checking for ability to link against libxml2...libxml2, zlib, and/or the Math library (-lm) have not been found.
Try setting LIBS and INC values on the command line
Or get libxml2 from
  http://xmlsoft.org/
If you install via RPMs, make sure you also install the -devel
RPMs, as this is where the headers (.h files) are.

Also, you may try to run perl Makefile.PL with the DEBUG=1 parameter
to see the exact reason why the detection of libxml2 installation
failed or why Makefile.PL was not able to compile a test program.

■ デバッグ

[email protected]:~/.cpanm/work/1405829332.1753/XML-LibXML-2.0116# perl Makefile.PL DEBUG=1
enable native perl UTF8
running xml2-config...xml2-config --version
xml2-config --libs
xml2-config --cflags
ok (2.9.1)
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib8a1c_u9A.c -I/usr/include/libxml2 -o assertlibVPBrBisC
Checking for ability to link against xml2...# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibcW0s7tgb.c -I/usr/include/libxml2 -o assertlibHKkSWz2l
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibqEoPQxXK.c -I/usr/include/libxml2 -o assertlibbR1CNsMf
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibLEyJ3esz.c -I/usr/include/libxml2 -o assertlibWP8ZKaFo
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibnv9tXZ6D.c -I/usr/include/libxml2 -o assertlibk_vYpDgq
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib6xSQDWzA.c -I/usr/include/libxml2 -o assertlibn6fWDWg8
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibdSYyxz_4.c -I/usr/include/libxml2 -o assertlibCijitdaD
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibWL0edMp_.c -I/usr/include/libxml2 -o assertlibJui6jbio
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibS2rrP_jA.c -I/usr/include/libxml2 -o assertliblT2sKzwX
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertliboJAWL9gK.c -I/usr/include/libxml2 -o assertlib_x06aZE5
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibmJhz7A1q.c -I/usr/include/libxml2 -o assertlibA6U4_57D
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib4WMLm_uh.c -I/usr/include/libxml2 -o assertlib9_JPdZW8
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib8XyOtQXq.c -I/usr/include/libxml2 -o assertlib6lU9zclm
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibv3RJNQG5.c -I/usr/include/libxml2 -o assertlibObxxXlOG
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib4vRoxPUT.c -I/usr/include/libxml2 -o assertlibutrfpeCi
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibUh5b8pmv.c -I/usr/include/libxml2 -o assertlib1f9bzoZe
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibzrIyoHXJ.c -I/usr/include/libxml2 -o assertlibvqv9PD8L
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibWMy_NODG.c -I/usr/include/libxml2 -o assertlibOQJuwkHL
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib3frob0oT.c -I/usr/include/libxml2 -o assertlibQ_RCqWzB
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibx7pQXLDE.c -I/usr/include/libxml2 -o assertlibloarDW48
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibx9DvkMbW.c -I/usr/include/libxml2 -o assertlibDg_Dp5fD
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibTIAY3D5i.c -I/usr/include/libxml2 -o assertlibC1gP80xK
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib4O6mwT0v.c -I/usr/include/libxml2 -o assertlibwQznHYrd
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibfTuoCoyU.c -o assertlib3eIBUefk -I/usr/include/libxml2 -lxml2
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibfTuoCoyU.c -o assertlibAkWAN8D9 -I/usr/include/libxml2 -lxml2
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibfTuoCoyU.c -o assertlibu9wfVchg -I/usr/include/libxml2 -lz
/usr/bin/ld: -lz が見つかりません
collect2: error: ld returned 1 exit status
no
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibAAnHJD1f.c -I/usr/include/libxml2 -o assertlibeAzdgjJK
Checking for ability to link against libxml2...# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibZnqfZh9L.c -I/usr/include/libxml2 -o assertlibjfjXaK9n
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibLZVtmamV.c -I/usr/include/libxml2 -o assertlibY0Dc5541
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibxcS05vHf.c -I/usr/include/libxml2 -o assertlibQ6vKXgYn
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibt8qlF7VT.c -I/usr/include/libxml2 -o assertlib8zGUTLGV
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibW5ya49z3.c -I/usr/include/libxml2 -o assertlibMV0HjY3d
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib7tFb0eoq.c -I/usr/include/libxml2 -o assertlibRb4Q22fq
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibrE37gUEn.c -I/usr/include/libxml2 -o assertlibalpXny6w
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib70gmCXES.c -I/usr/include/libxml2 -o assertliblJoF1q0G
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib_yYzJVaX.c -I/usr/include/libxml2 -o assertlib6f3azcoB
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibVgqJQD9v.c -I/usr/include/libxml2 -o assertlib8mvi9mck
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib6be5bgZ2.c -I/usr/include/libxml2 -o assertlibTIy_7lXl
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibDVRN_pQ9.c -I/usr/include/libxml2 -o assertlibhKJ5sgdj
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib3pyAKVRG.c -I/usr/include/libxml2 -o assertlibRhD0hR_W
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibmBBzOgfF.c -I/usr/include/libxml2 -o assertlib96ED4U0c
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib7Xop_MMW.c -I/usr/include/libxml2 -o assertlibod02rvYJ
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibWYb1Pv9g.c -I/usr/include/libxml2 -o assertlibiVS4dp7R
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibH6Qx8yjd.c -I/usr/include/libxml2 -o assertlibCuBWQdx2
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibW8aPNi8z.c -I/usr/include/libxml2 -o assertlibSRvPkRNN
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibWHHa8dCC.c -I/usr/include/libxml2 -o assertlibRYpYd9RT
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibKruvRm8U.c -I/usr/include/libxml2 -o assertlib5jlLoxII
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlib1yZfx7mB.c -I/usr/include/libxml2 -o assertlibVddSGn_v
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibORGjPcSm.c -I/usr/include/libxml2 -o assertlibuInm7PUB
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibAGOsZFPA.c -o assertlib_1rbELpU -I/usr/include/libxml2 -llibxml2
/usr/bin/ld: -llibxml2 が見つかりません
collect2: error: ld returned 1 exit status
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibAGOsZFPA.c -o assertlibPqTo3nh_ -I/usr/include/libxml2 -lxml2
# /usr/bin/cc -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fstack-protector -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fstack-protector -L/usr/local/lib -ldl -lm -lpthread -lc -lcrypt assertlibAGOsZFPA.c -o assertlibagUdC8Il -I/usr/include/libxml2 -lz
/usr/bin/ld: -lz が見つかりません
collect2: error: ld returned 1 exit status
libxml2, zlib, and/or the Math library (-lm) have not been found.
Try setting LIBS and INC values on the command line
Or get libxml2 from
  http://xmlsoft.org/
If you install via RPMs, make sure you also install the -devel
RPMs, as this is where the headers (.h files) are.

Also, you may try to run perl Makefile.PL with the DEBUG=1 parameter
to see the exact reason why the detection of libxml2 installation
failed or why Makefile.PL was not able to compile a test program.

■ 対処

[email protected]:~/.cpanm/work/1405829332.1753/XML-LibXML-2.0116# apt-get install libz-dev

■ 参考
Stackoverflow – “/usr/bin/ld: cannot find -lz”
http://stackoverflow.com/questions/3373995/usr-bin-ld-cannot-find-lz

スポンサーリンク