-
Notifications
You must be signed in to change notification settings - Fork 252
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
Assume that callbacks are not broken in OpenLDAP when cross-compiling #7743
Conversation
Given that you can already override the result with |
This can override a result of |
Okay, but setting it to
|
Setting it to Honestly, I'd prefer to drop the AC_RUN_IFELSE - it is a check for an OpenLDAP bug that was fixed 16 years ago, I think. |
Our wires are crossed. 😅 If you want the callbacks, then you wouldn't set it at all. I still think a change is needed, I just think it should be: @@ -80,7 +81,8 @@ AC_CHECK_MEMBERS([struct ldap_conncb.lc_arg],
[AC_DEFINE([HAVE_LDAP_CONNCB], [1],
[Define if LDAP connection callbacks are available])],
[AC_MSG_WARN([Found broken callback implementation])],
- [])],
+ [AC_DEFINE([HAVE_LDAP_CONNCB], [1],
+ [Define if LDAP connection callbacks are available])])],
[], [[#include <ldap.h>]])
AC_CHECK_TYPE([LDAPDerefRes], |
Oh, I finally got what you meant. :) Yeah, true, that'd be simpler. I'll make the change. |
7aac435
to
5b27ca0
Compare
PR updated. I'm wondering if it could be also backported to 2.9 and 2.10 branches. |
If we do cross-compiling against a known broken version of OpenLDAP, we can do `export ac_cv_member_struct_ldap_conncb_lc_arg=no` before running configure. This is rather unlikely now, as the test was done to detect a bug that was fixed 16 years ago. This allows the project to be configured successfully when cross-compiling, without disabling connection callbacks.
5b27ca0
to
3c66b0b
Compare
@sumit-bose: Thanks for the review. PR updated. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi,
thank you for the update, ACK.
bye,
Sumit
This adds a LDAP_HAVE_CONNCB_CROSS variable that will be used instead of the runtime check for a broken connection callbacks in ldap library. Set it to yes to assume that connection callbacks are working.This allows the project to be configured successfully when cross-compiling.If we do cross-compiling against a known broken version of OpenLDAP, we can do
export ac_cv_member_struct_ldap_conncb_lc_arg=no
before running configure. This is rather unlikely now, as the test was done to detect a bug that was fixed 16 years ago.This allows the project to be configured successfully when cross-compiling, without disabling connection callbacks.
Tested locally in Flatcar (flatcar/scripts#2501)