[PHP-DEV] gd/config.m4 still busted
Hi, the config.m4 defines several macros like this AC_DEFUN(PHP_GD_JPEG,[ .. PHP_ADD_LIBRARY_WITH_PATH(jpeg, $withval/lib) .. LIBS=$LIBS -L$withval/lib -ljpeg ]) I.e. it correctly adds the library using PHP-specific macros, but then continues in the wrong way by adding some cruft to LIBS manually. I would not be surprised, if this is the reason for the problems Jani described. People are already complaining to me about this mis-feature in 4.0.5 which causes other checks to fail in non-obvious ways. Unfortunately, we cannot simply rip them out as PHP_GD_CHECK_VERSION depends on being able to link a program against libgd.a successfully and that only works, if gd's auxiliary libraries are present. So, what I would propose is to reset the LIBS/LDFLAGS variables after leaving the body of AC_ARG_WITH(gd ..) to the state they had before entering it. That should leave the current functionality intact and it prevents the modifications to infect the rest of the system. Comments? - Sascha Experience IRCG http://schumann.cx/http://schumann.cx/ircg -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DEV] gd/config.m4 still busted
I'm working on this.. --Jani On Wed, 9 May 2001, Sascha Schumann wrote: Hi, the config.m4 defines several macros like this AC_DEFUN(PHP_GD_JPEG,[ .. PHP_ADD_LIBRARY_WITH_PATH(jpeg, $withval/lib) .. LIBS=$LIBS -L$withval/lib -ljpeg ]) I.e. it correctly adds the library using PHP-specific macros, but then continues in the wrong way by adding some cruft to LIBS manually. I would not be surprised, if this is the reason for the problems Jani described. People are already complaining to me about this mis-feature in 4.0.5 which causes other checks to fail in non-obvious ways. Unfortunately, we cannot simply rip them out as PHP_GD_CHECK_VERSION depends on being able to link a program against libgd.a successfully and that only works, if gd's auxiliary libraries are present. So, what I would propose is to reset the LIBS/LDFLAGS variables after leaving the body of AC_ARG_WITH(gd ..) to the state they had before entering it. That should leave the current functionality intact and it prevents the modifications to infect the rest of the system. Comments? - Sascha Experience IRCG http://schumann.cx/http://schumann.cx/ircg -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DEV] gd/config.m4 still busted
On Wed, 9 May 2001, Jani Taskinen wrote: I'm working on this.. Well, then you are probably well-equipped to comment on this. The implementation of the proposal is attached. - Sascha Experience IRCG http://schumann.cx/http://schumann.cx/ircg Index: config.m4 === RCS file: /repository/php4/ext/gd/config.m4,v retrieving revision 1.58 diff -u -r1.58 config.m4 --- config.m4 2001/04/19 14:16:09 1.58 +++ config.m4 2001/05/09 19:11:22 @@ -134,6 +134,8 @@ Set DIR to shared to build as a dl, or shared,DIR to build as a dl and still specify DIR.], [ + gd_saved_LIBS=$LIBS + gd_saved_LDFLAGS=$LDFLAGS PHP_WITH_SHARED old_withval=$withval PHP_GD_JPEG @@ -233,6 +235,8 @@ fi ;; esac + LDFLAGS=$gd_saved_LDFLAGS + LIBS=$gd_saved_LIBS ],[]) -- PHP Development Mailing List http://www.php.net/ To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]