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

libtool: You should recreate aclocal.m4 with macros from libtool 2.4.6 #784

Closed
pauperis opened this Issue Apr 7, 2016 · 1 comment

Comments

Projects
None yet
1 participant
@pauperis

pauperis commented Apr 7, 2016

I'm trying to compile and install branch php7 of phpredis repository but i'm getting the following error:

/bin/sh /root/phpredis/libtool --mode=compile cc  -I. -I/root/phpredis -    DPHP_ATOM_INC -I/root/phpredis/include -I/root/phpredis/main -I/root/phpredis -I/usr/lib64/php7.0/include/php -I/usr/lib64/php7.0/include/php/main -I/usr/lib64/php7.0/include/php/TSRM -I/usr/lib64/php7.0/include/php/Zend -I/usr/lib64/php7.0/include/php/ext -I/usr/lib64/php7.0/include/php/ext/date/lib  -DHAVE_CONFIG_H  -g -O2   -c         /root/phpredis/redis.c -o redis.lo 
libtool: Version mismatch error.  This is libtool 2.4.6, but the
libtool: definition of this LT_INIT comes from an older release.
libtool: You should recreate aclocal.m4 with macros from libtool 2.4.6
libtool: and run autoconf again.
Makefile:193: recipe for target 'redis.lo' failed
make: *** [redis.lo] Error 63

By now this is are the steps i followed:

git clone https://github.com/phpredis/phpredis.git
cd phpredis/
phpize && ./configure --with-php-config=/usr/bin/php-config && make

Tools versions:

# autoconf --version
autoconf (GNU Autoconf) 2.69

# aclocal --version
aclocal (GNU automake) 1.15

# libtoolize --version
libtoolize (GNU libtool) 2.4.6

Running autoreconf --force --install i get the following:

# autoreconf --force --install
libtoolize: putting auxiliary files in '.'.
libtoolize: copying file './ltmain.sh'
libtoolize: You should add the contents of the following files to 'aclocal.m4':
libtoolize:   '/usr/share/aclocal/libtool.m4'
libtoolize:   '/usr/share/aclocal/ltoptions.m4'
libtoolize:   '/usr/share/aclocal/ltsugar.m4'
libtoolize:   '/usr/share/aclocal/ltversion.m4'
libtoolize:   '/usr/share/aclocal/lt~obsolete.m4'
libtoolize: Consider adding 'AC_CONFIG_MACRO_DIRS([m4])' to configure.in,
libtoolize: and rerunning libtoolize and aclocal.
libtoolize: Consider adding '-I m4' to ACLOCAL_AMFLAGS in Makefile.am.

So then i do:

cat /usr/share/aclocal/libtool.m4 /usr/share/aclocal/ltoptions.m4 /usr/share/aclocal/ltsugar.m4 /usr/share/aclocal/ltversion.m4 /usr/share/aclocal/lt~obsolete.m4 >> aclocal.m4  
echo  'AC_CONFIG_MACRO_DIRS([m4])' > configure.in

And now running autoreconf --force --install gives not output but i still get the same error when trying to compile phpredis.

@pauperis

This comment has been minimized.

Show comment
Hide comment
@pauperis

pauperis Apr 10, 2016

Finally i solved the issue. These are the steps needed to get phpredis running if you encounter an issue like the one above:

git clone https://github.com/phpredis/phpredis.git
cd phpredis/
git checkout php7
rm -f aclocal.m4
phpize
aclocal && libtoolize --force && autoreconf
./configure --with-php-config=/usr/bin/php-config && make
# in my case previous make command installed the redis.so into ~/phpredis/modules/ 
make install #optional

pauperis commented Apr 10, 2016

Finally i solved the issue. These are the steps needed to get phpredis running if you encounter an issue like the one above:

git clone https://github.com/phpredis/phpredis.git
cd phpredis/
git checkout php7
rm -f aclocal.m4
phpize
aclocal && libtoolize --force && autoreconf
./configure --with-php-config=/usr/bin/php-config && make
# in my case previous make command installed the redis.so into ~/phpredis/modules/ 
make install #optional

@pauperis pauperis closed this Apr 10, 2016

@iandoug iandoug referenced this issue Mar 13, 2017

Closed

aclocal #4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment