Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

collectd unable to locate libperl (5.14) #310

Closed
vijaySamanuri opened this issue Apr 25, 2013 · 16 comments
Closed

collectd unable to locate libperl (5.14) #310

vijaySamanuri opened this issue Apr 25, 2013 · 16 comments
Assignees
Labels
Bug A genuine bug
Milestone

Comments

@vijaySamanuri
Copy link

I am using ubuntu 12.4 . perl version 5.14 .
I wanted to install collectd 5.3.0 from source and use perl plugin to store metrics into remote database.
but when i type ./configure
.
.
.
checking for perl... yes (/usr/bin/perl)
checking for libperl... no
.
.
libperl no
.
.
.
perl no(needs libperl)

Collectd is unable to locate my libperl even though it is available
$locate libperl

/usr/lib/libperl.a
/usr/lib/libperl.so
/usr/lib/libperl.so.5.14
/usr/lib/libperl.so.5.14.2
/usr/share/doc/libperl-dev
/usr/share/doc/libperl5.14
/usr/share/lintian/overrides/libperl5.14
/var/cache/apt/archives/libperl-dev_5.14.2-6ubuntu2.3_amd64.deb
/var/lib/dpkg/info/libperl-dev.list
/var/lib/dpkg/info/libperl-dev.md5sums
/var/lib/dpkg/info/libperl5.14.list
/var/lib/dpkg/info/libperl5.14.md5sums
/var/lib/dpkg/info/libperl5.14.postinst

i even tried installing lower versions of perl (5.10) using perlbrew but the problem remains.
Any help would be appreciated :)

@XavM
Copy link

XavM commented Apr 29, 2013

I was facing a similar problem on a CentOS 6.4 when compiling Collectd 5.3

When trying to configure collectd to use perl, I was having this configure error :

** configure: error: "Some plugins are missing dependencies - see the summary above for details" **

The "summary above" was saying :

** perl . . . . . . . . no (needs libperl) **

I had to install the perl module ExtUtils:Embed to get rid of this problem :

On CentOS (Adapt with the corresponding apt-get install on Ubuntu) :
** yum install perl-ExtUtils-Embed.x86_64 **

And then run the "collectd configure" with the following options :
** ./configure --enable-curl_json --with-yajl --enable-perl --with-libperl **


Regards,

Xavier

@vijaySamanuri
Copy link
Author

Hi Xavier, Thanks for your reply :)

i tried installing ExtUtils:Embed perl module from source. ExtUtils-Embed-1.14.tar.gz
http://search.cpan.org/~dougm/ExtUtils-Embed-1.14/lib/ExtUtils/Embed.pm

but the problem still exits :( am i missing anything ?

@vijaySamanuri
Copy link
Author

config log

configure:21765: gcc -o conftest -g -O2 -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/lib/perl/5.14/CORE -Wl,-E -fstack-protector -L/usr/local/lib -L/usr/lib/perl/5.14/CORE -lperl -lgdbm -lgdbm_compat -ldl -lm -lpthread -lc -lcrypt conftest.c -ldl >&5
/usr/bin/ld: cannot find -lgdbm
/usr/bin/ld: cannot find -lgdbm_compat
collect2: ld returned 1 exit status
configure:21765: $? = 1
configure: failed program was:
| /* confdefs.h /
| #define PACKAGE_NAME "collectd"
| #define PACKAGE_TARNAME "collectd"
| #define PACKAGE_VERSION "5.3.0"
| #define PACKAGE_STRING "collectd 5.3.0"
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| #define STDC_HEADERS 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| #define LT_MODULE_EXT ".so"
| #define LT_MODULE_PATH_VAR "LD_LIBRARY_PATH"
| #define LT_DLSEARCH_PATH "/lib:/usr/lib:/usr/lib/i386-linux-gnu/mesa:/lib/i386-linux-gnu:/usr/lib/i386-linux-gnu:/lib/i686-linux-gnu:/usr/lib/i686-linux-gnu:/usr/local/lib:/lib/x86_64-linux-gnu:/usr/lib/x86_64-linux-gnu:/usr/lib/x86_64-linux-gnu/mesa:/lib32:/usr/lib32"
| #define HAVE_LIBDL 1
| #define HAVE_DLERROR 1
| #define HAVE_LIBDLLOADER 1
| #define HAVE_ARGZ_H 1
| #define HAVE_ERROR_T 1
| #define HAVE_ARGZ_ADD 1
| #define HAVE_ARGZ_APPEND 1
| #define HAVE_ARGZ_COUNT 1
| #define HAVE_ARGZ_CREATE_SEP 1
| #define HAVE_ARGZ_INSERT 1
| #define HAVE_ARGZ_NEXT 1
| #define HAVE_ARGZ_STRINGIFY 1
| #define HAVE_WORKING_ARGZ 1
| #define HAVE_PRELOADED_SYMBOLS 1
| #define HAVE_LTDL 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DIRENT_H 1
| #define HAVE_CLOSEDIR 1
| #define HAVE_OPENDIR 1
| #define HAVE_READDIR 1
| #define LT_LIBEXT "a"
| #define LIBTOOL_VERSION 2
| #define PACKAGE "collectd"
| #define VERSION "5.3.0"
| #define YYTEXT_POINTER 1
| #define HAVE_GOOGLE_PROTOBUF_C_PROTOBUF_C_H 1
| #define KERNEL_LINUX 1
| #define STDC_HEADERS 1
| #define HAVE_SYS_WAIT_H 1
| #define HAVE_DIRENT_H 1
| #define HAVE__BOOL 1
| #define HAVE_STDBOOL_H 1
| #define HAVE_STDIO_H 1
| #define HAVE_ERRNO_H 1
| #define HAVE_MATH_H 1
| #define HAVE_STDARG_H 1
| #define HAVE_SYSLOG_H 1
| #define HAVE_FCNTL_H 1
| #define HAVE_SIGNAL_H 1
| #define HAVE_ASSERT_H 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_SOCKET_H 1
| #define HAVE_SYS_SELECT_H 1
| #define HAVE_POLL_H 1
| #define HAVE_NETDB_H 1
| #define HAVE_ARPA_INET_H 1
| #define HAVE_SYS_RESOURCE_H 1
| #define HAVE_SYS_PARAM_H 1
| #define HAVE_REGEX_H 1
| #define HAVE_SYS_IOCTL_H 1
| #define HAVE_ENDIAN_H 1
| #define HAVE_FNMATCH_H 1
| #define HAVE_LIBGEN_H 1
| #define HAVE_NETINET_IN_SYSTM_H 1
| #define HAVE_NETINET_IN_H 1
| #define HAVE_NETINET_IP_H 1
| #define HAVE_NETINET_IP_ICMP_H 1
| #define HAVE_NETINET_IP6_H 1
| #define HAVE_NETINET_ICMP6_H 1
| #define HAVE_NETINET_TCP_H 1
| #define HAVE_NETINET_UDP_H 1
| #define HAVE_SYS_SYSCTL_H 1
| #define HAVE_LINUX_MAJOR_H 1
| #define HAVE_LINUX_RAID_MD_U_H 1
| #define HAVE_LINUX_WIRELESS_H 1
| #define HAVE_SYS_SWAP_H 1
| #define HAVE_UTMP_H 1
| #define HAVE_UTMPX_H 1
| #define HAVE_IFADDRS_H 1
| #define HAVE_NET_IF_H 1
| #define HAVE_LINUX_IF_H 1
| #define HAVE_LINUX_NETDEVICE_H 1
| #define HAVE_LINUX_SOCKIOS_H 1
| #define HAVE_LINUX_ETHTOOL_H 1
| #define HAVE_LINUX_IP_VS_H 1
| #define HAVE_SYS_MOUNT_H 1
| #define HAVE_LINUX_UN_H 1
| #define HAVE_PWD_H 1
| #define HAVE_GRP_H 1
| #define HAVE_SYS_UN_H 1
| #define HAVE_CTYPE_H 1
| #define HAVE_LIMITS_H 1
| #define HAVE_PATHS_H 1
| #define HAVE_MNTENT_H 1
| #define HAVE_SYS_STATFS_H 1
| #define HAVE_SYS_STATVFS_H 1
| #define HAVE_SYS_VFS_H 1
| #define HAVE_WORDEXP_H 1
| #define HAVE_ARPA_NAMESER_H 1
| #define HAVE_ARPA_NAMESER_COMPAT_H 1
| #define HAVE_NET_IF_ARP_H 1
| #define HAVE_NET_PPP_DEFS_H 1
| #define HAVE_NET_IF_PPP_H 1
| #define HAVE_NETINET_IF_ETHER_H 1
| #define HAVE_TERMIOS_H 1
| #define TIME_WITH_SYS_TIME 1
| #define HAVE_GETTIMEOFDAY 1
| #define HAVE_SELECT 1
| #define HAVE_STRDUP 1
| #define HAVE_STRTOL 1
| #define HAVE_GETADDRINFO 1
| #define HAVE_GETNAMEINFO 1
| #define HAVE_STRCHR 1
| #define HAVE_MEMCPY 1
| #define HAVE_STRSTR 1
| #define HAVE_STRCMP 1
| #define HAVE_STRNCMP 1
| #define HAVE_STRNCPY 1
| #define HAVE_STRLEN 1
| #define HAVE_STRNCASECMP 1
| #define HAVE_STRCASECMP 1
| #define HAVE_OPENLOG 1
| #define HAVE_CLOSELOG 1
| #define HAVE_SYSCONF 1
| #define HAVE_SETENV 1
| #define HAVE_IF_INDEXTONAME 1
| #define HAVE_DECL_STRERROR_R 1
| #define HAVE_STRERROR_R 1
| #define HAVE_GETPWNAM_R 1
| #define HAVE_GETGRNAM_R 1
| #define HAVE_SETGROUPS 1
| #define HAVE_REGCOMP 1
| #define HAVE_REGERROR 1
| #define HAVE_REGEXEC 1
| #define HAVE_REGFREE 1
| #define HAVE_SOCKET 1
| #define HAVE_CLOCK_GETTIME 1
| #define HAVE_NANOSLEEP 1
| #define HAVE_SYSCTL 1
| #define HAVE_STATFS 1
| #define HAVE_STATVFS 1
| #define HAVE_GETIFADDRS 1
| #define HAVE_GETLOADAVG 1
| #define HAVE_SYSLOG 1
| #define HAVE_GETUTENT 1
| #define HAVE_GETUTXENT 1
| #define HAVE_STRPTIME 1
| #define STRPTIME_NEEDS_STANDARDS 1
| #define NAN_STATIC_DEFAULT 1
| #define FP_LAYOUT_NEED_NOTHING 1
| #define HAVE_GETMNTENT 1
| #define HAVE_ONE_GETMNTENT 1
| #define HAVE_STRUCT_IP_MREQN_IMR_IFINDEX 1
| #define HAVE_STRUCT_UDPHDR_UH_DPORT 1
| #define HAVE_STRUCT_UDPHDR_UH_SPORT 1
| #define COLLECT_LIBESMTP 0
| #define HAVE_GCRYPT_H 1
| #define HAVE_LIBGCRYPT 1
| #define HAVE_MYSQL_H 1
| #define HAVE_LINUX_GEN_STATS_H 1
| #define HAVE_LINUX_PKT_SCHED_H 1
| #define HAVE_NET_SNMP_NET_SNMP_CONFIG_H 1
| /
end confdefs.h. */
|
| #define PERL_NO_GET_CONTEXT
| #include <EXTERN.h>
| #include <perl.h>
| #include <XSUB.h>
|
| int
| main ()
| {
|
| dTHX;
| load_module (PERL_LOADMOD_NOIMPORT,
| newSVpv ("Collectd::Plugin::FooBar", 24),
| Nullsv);
|
|
| ;
| return 0;
| }
configure:21775: result: no

@vijaySamanuri
Copy link
Author

config.log

configure:21738: checking for libperl
configure:21765: gcc -o conftest -g -O2  -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64  -I/usr/lib/perl/5.14/CORE    -Wl,-E  -fstack-protector -L/usr/local/lib  -L/usr/lib/perl/5.14/CORE -lperl -lgdbm -lgdbm_compat -ldl -lm -lpthread -lc -lcrypt conftest.c -ldl  >&5
/tmp/ccJceeOR.o: In function `main':
/home/bhar/Collectd/collectd-5.3.0/conftest.c:187: undefined reference to `PL_thr_key'
/home/bhar/Collectd/collectd-5.3.0/conftest.c:187: undefined reference to `pthread_getspecific'
/home/bhar/Collectd/collectd-5.3.0/conftest.c:188: undefined reference to `Perl_newSVpv'
/home/bhar/Collectd/collectd-5.3.0/conftest.c:188: undefined reference to `Perl_load_module_nocontext'
collect2: ld returned 1 exit status
configure:21765: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "collectd"
| #define PACKAGE_TARNAME "collectd"
| #define PACKAGE_VERSION "5.3.0"
| #define PACKAGE_STRING "collectd 5.3.0"
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| #define STDC_HEADERS 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_STAT_H 1
| #define HAVE_STDLIB_H 1
| #define HAVE_STRING_H 1
| #define HAVE_MEMORY_H 1
| #define HAVE_STRINGS_H 1
| #define HAVE_INTTYPES_H 1
| #define HAVE_STDINT_H 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DLFCN_H 1
| #define LT_OBJDIR ".libs/"
| #define LT_MODULE_EXT ".so"
| #define LT_MODULE_PATH_VAR "LD_LIBRARY_PATH"
| #define LT_DLSEARCH_PATH "/lib:/usr/lib:/usr/lib/i386-linux-gnu/mesa:/lib/i386-linux-gnu:/usr/lib/i386-linux-gnu:/lib/i686-linux-gnu:/usr/lib/i686-linux-gnu:/usr/local/lib:/lib/x86_64-linux-gnu:/usr/lib/x86_64-linux-gnu:/usr/lib/x86_64-linux-gnu/mesa:/lib32:/usr/lib32"
| #define HAVE_LIBDL 1
| #define HAVE_DLERROR 1
| #define HAVE_LIBDLLOADER 1
| #define HAVE_ARGZ_H 1
| #define HAVE_ERROR_T 1
| #define HAVE_ARGZ_ADD 1
| #define HAVE_ARGZ_APPEND 1
| #define HAVE_ARGZ_COUNT 1
| #define HAVE_ARGZ_CREATE_SEP 1
| #define HAVE_ARGZ_INSERT 1
| #define HAVE_ARGZ_NEXT 1
| #define HAVE_ARGZ_STRINGIFY 1
| #define HAVE_WORKING_ARGZ 1
| #define HAVE_PRELOADED_SYMBOLS 1
| #define HAVE_LTDL 1
| #define HAVE_UNISTD_H 1
| #define HAVE_DIRENT_H 1
| #define HAVE_CLOSEDIR 1
| #define HAVE_OPENDIR 1
| #define HAVE_READDIR 1
| #define LT_LIBEXT "a"
| #define LIBTOOL_VERSION 2
| #define PACKAGE "collectd"
| #define VERSION "5.3.0"
| #define YYTEXT_POINTER 1
| #define HAVE_GOOGLE_PROTOBUF_C_PROTOBUF_C_H 1
| #define KERNEL_LINUX 1
| #define STDC_HEADERS 1
| #define HAVE_SYS_WAIT_H 1
| #define HAVE_DIRENT_H 1
| #define HAVE__BOOL 1
| #define HAVE_STDBOOL_H 1
| #define HAVE_STDIO_H 1
| #define HAVE_ERRNO_H 1
| #define HAVE_MATH_H 1
| #define HAVE_STDARG_H 1
| #define HAVE_SYSLOG_H 1
| #define HAVE_FCNTL_H 1
| #define HAVE_SIGNAL_H 1
| #define HAVE_ASSERT_H 1
| #define HAVE_SYS_TYPES_H 1
| #define HAVE_SYS_SOCKET_H 1
| #define HAVE_SYS_SELECT_H 1
| #define HAVE_POLL_H 1
| #define HAVE_NETDB_H 1
| #define HAVE_ARPA_INET_H 1
| #define HAVE_SYS_RESOURCE_H 1
| #define HAVE_SYS_PARAM_H 1
| #define HAVE_REGEX_H 1
| #define HAVE_SYS_IOCTL_H 1
| #define HAVE_ENDIAN_H 1
| #define HAVE_FNMATCH_H 1
| #define HAVE_LIBGEN_H 1
| #define HAVE_NETINET_IN_SYSTM_H 1
| #define HAVE_NETINET_IN_H 1
| #define HAVE_NETINET_IP_H 1
| #define HAVE_NETINET_IP_ICMP_H 1
| #define HAVE_NETINET_IP6_H 1
| #define HAVE_NETINET_ICMP6_H 1
| #define HAVE_NETINET_TCP_H 1
| #define HAVE_NETINET_UDP_H 1
| #define HAVE_SYS_SYSCTL_H 1
| #define HAVE_LINUX_MAJOR_H 1
| #define HAVE_LINUX_RAID_MD_U_H 1
| #define HAVE_LINUX_WIRELESS_H 1
| #define HAVE_SYS_SWAP_H 1
| #define HAVE_UTMP_H 1
| #define HAVE_UTMPX_H 1
| #define HAVE_IFADDRS_H 1
| #define HAVE_NET_IF_H 1
| #define HAVE_LINUX_IF_H 1
| #define HAVE_LINUX_NETDEVICE_H 1
| #define HAVE_LINUX_SOCKIOS_H 1
| #define HAVE_LINUX_ETHTOOL_H 1
| #define HAVE_LINUX_IP_VS_H 1
| #define HAVE_SYS_MOUNT_H 1
| #define HAVE_LINUX_UN_H 1
| #define HAVE_PWD_H 1
| #define HAVE_GRP_H 1
| #define HAVE_SYS_UN_H 1
| #define HAVE_CTYPE_H 1
| #define HAVE_LIMITS_H 1
| #define HAVE_PATHS_H 1
| #define HAVE_MNTENT_H 1
| #define HAVE_SYS_STATFS_H 1
| #define HAVE_SYS_STATVFS_H 1
| #define HAVE_SYS_VFS_H 1
| #define HAVE_WORDEXP_H 1
| #define HAVE_ARPA_NAMESER_H 1
| #define HAVE_ARPA_NAMESER_COMPAT_H 1
| #define HAVE_NET_IF_ARP_H 1
| #define HAVE_NET_PPP_DEFS_H 1
| #define HAVE_NET_IF_PPP_H 1
| #define HAVE_NETINET_IF_ETHER_H 1
| #define HAVE_TERMIOS_H 1
| #define TIME_WITH_SYS_TIME 1
| #define HAVE_GETTIMEOFDAY 1
| #define HAVE_SELECT 1
| #define HAVE_STRDUP 1
| #define HAVE_STRTOL 1
| #define HAVE_GETADDRINFO 1
| #define HAVE_GETNAMEINFO 1
| #define HAVE_STRCHR 1
| #define HAVE_MEMCPY 1
| #define HAVE_STRSTR 1
| #define HAVE_STRCMP 1
| #define HAVE_STRNCMP 1
| #define HAVE_STRNCPY 1
| #define HAVE_STRLEN 1
| #define HAVE_STRNCASECMP 1
| #define HAVE_STRCASECMP 1
| #define HAVE_OPENLOG 1
| #define HAVE_CLOSELOG 1
| #define HAVE_SYSCONF 1
| #define HAVE_SETENV 1
| #define HAVE_IF_INDEXTONAME 1
| #define HAVE_DECL_STRERROR_R 1
| #define HAVE_STRERROR_R 1
| #define HAVE_GETPWNAM_R 1
| #define HAVE_GETGRNAM_R 1
| #define HAVE_SETGROUPS 1
| #define HAVE_REGCOMP 1
| #define HAVE_REGERROR 1
| #define HAVE_REGEXEC 1
| #define HAVE_REGFREE 1
| #define HAVE_SOCKET 1
| #define HAVE_CLOCK_GETTIME 1
| #define HAVE_NANOSLEEP 1
| #define HAVE_SYSCTL 1
| #define HAVE_STATFS 1
| #define HAVE_STATVFS 1
| #define HAVE_GETIFADDRS 1
| #define HAVE_GETLOADAVG 1
| #define HAVE_SYSLOG 1
| #define HAVE_GETUTENT 1
| #define HAVE_GETUTXENT 1
| #define HAVE_STRPTIME 1
| #define STRPTIME_NEEDS_STANDARDS 1
| #define NAN_STATIC_DEFAULT 1
| #define FP_LAYOUT_NEED_NOTHING 1
| #define HAVE_GETMNTENT 1
| #define HAVE_ONE_GETMNTENT 1
| #define HAVE_STRUCT_IP_MREQN_IMR_IFINDEX 1
| #define HAVE_STRUCT_UDPHDR_UH_DPORT 1
| #define HAVE_STRUCT_UDPHDR_UH_SPORT 1
| #define COLLECT_LIBESMTP 0
| #define HAVE_GCRYPT_H 1
| #define HAVE_LIBGCRYPT 1
| #define HAVE_JNI_H 1
| #define HAVE_MYSQL_H 1
| #define HAVE_LINUX_GEN_STATS_H 1
| #define HAVE_LINUX_PKT_SCHED_H 1
| #define HAVE_NET_SNMP_NET_SNMP_CONFIG_H 1
| /* end confdefs.h.  */
| 
| #define PERL_NO_GET_CONTEXT
| #include <EXTERN.h>
| #include <perl.h>
| #include <XSUB.h>
| 
| int
| main ()
| {
| 
|        dTHX;
|        load_module (PERL_LOADMOD_NOIMPORT,
|            newSVpv ("Collectd::Plugin::FooBar", 24),
|            Nullsv);
| 
| 
|   ;
|   return 0;
| }
configure:21775: result: no

@favoretti
Copy link

Add --with-perl=/usr to configure and:

Should be fixable by the following patch:

root@ubuntu:~/collectd-5.2.0# diff -u src/Makefile.in src/Makefile.in.orig
--- src/Makefile.in 2013-05-22 19:31:48.151880351 +0200
+++ src/Makefile.in.orig    2013-05-22 19:31:36.867879285 +0200
@@ -1166,7 +1166,7 @@
 perl_la_OBJECTS = $(am_perl_la_OBJECTS)
 perl_la_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
    --mode=link $(CCLD) $(perl_la_CFLAGS) $(CFLAGS) \
-   $(perl_la_LDFLAGS) $(LDFLAGS) $(PERL_LIBS) -o $@
+   $(perl_la_LDFLAGS) $(LDFLAGS) -o $@
 @BUILD_PLUGIN_PERL_TRUE@am_perl_la_rpath = -rpath $(pkglibdir)
 pf_la_LIBADD =
 am__pf_la_SOURCES_DIST = pf.c

And yes, I'm compiling 5.2.0 but 5.3.0 has the same issues.

@octo
Copy link
Member

octo commented May 28, 2013

I can reproduce the issue on Ubuntu 12.4: The linker links in perl.so and fails to locate Perl_newSVpv and others. However, these are provided by that shared object. I'll investigate.

@ghost ghost assigned octo May 28, 2013
@ajdiaz
Copy link
Contributor

ajdiaz commented Jun 13, 2013

I can reproduce this bug on Ubuntu 13.04 too. It appears that in some way symbols are not exported by the library. I cannot found a way to fix it manually, is a weird bug :/

@wubr
Copy link

wubr commented Jul 5, 2013

Also ran into this while building a redhat rpm for collectd 5.2.2, and came across both this issue and a debian bug report from 2011: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=637875

I used the patch in that report as a guide to hacking up 5.2.2 and had more success finding libperl on the next build. Haven't tried it for 5.3 (yet), but it might be worth a shot.

@tishon
Copy link

tishon commented Jul 13, 2013

Just installing the following packages before running ./configure, solved the problem for me (tested with collectd 5.3.1):

yum install perl-ExtUtils-Embed perl-ExtUtils-MakeMaker

Courtesy of Hector Castro's Collectd Chef cookbook: https://github.com/hectcastro/chef-collectd/blob/master/recipes/default.rb

@octo
Copy link
Member

octo commented Jul 14, 2013

Thanks for the pointer, @wubr! I'll check if I'm running into the same problem.

@wubr
Copy link

wubr commented Jul 14, 2013

I can also confirm now that sometime in the last week I had the same issue and fix for 5.3 in my environment using the same debian patch as a guide.

@rtkmhart
Copy link
Contributor

This appears to have been fixed in #390 but not merged yet. I performed the following incantation to get it working on Ubuntu 12.04 LTS:

git clone -b collectd-5.4 git@github.com:collectd/collectd.git
cd collectd
git pull git@github.com:radford/collectd.git libperl-ldopts
./build.sh
./configure etc

@mfournier
Copy link

For the record, the root of this problem is mentioned here:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=637875
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=673291
https://bugs.launchpad.net/ubuntu/+source/collectd/+bug/796571

@mfournier
Copy link

Merging #390 fixed this problem. collectd 5.5.x, 5.4.2 and 5.3.2 should correctly detect libperl and build the plugin on ubuntu.

@obfuscurity
Copy link

FWIW, encountered the same problem with CentOS 7. Installing the perl-ExtUtils-Embed and perl-ExtUtils-MakeMaker packages as mentioned in #310 (comment) fixed it for me.

@obfuscurity
Copy link

To clarify, that last comment was regarding collectd 5.5.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug A genuine bug
Projects
None yet
Development

No branches or pull requests

10 participants