Closed Bug 245936 Opened 20 years ago Closed 19 years ago

compilation of negotiateauth fails when locating gssapi with krb5-config

Categories

(Core :: Networking, defect)

defect
Not set
minor

Tracking

()

RESOLVED FIXED
Future

People

(Reporter: msv, Assigned: darin.moz)

References

Details

(Keywords: helpwanted)

Attachments

(2 files, 1 obsolete file)

User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040207 Firefox/0.8 Build Identifier: Reproducible: Always Steps to Reproduce: 1. Have gssapi.h installed somewhere else that /usr/include, /usr/include/gssapi, /usr/kerberos/include or /usr/kerberos/include/gssapi 2. Have a correct krb5-config 3. Compile mozilla Actual Results: The compilation ended in: g++ -o nsHttpGssapiAuth.o -c -DOSTYPE=\"Linux2.4\" -DOSARCH=\"Linux\" -DHAVE_DEP ENDENT_LIBS -I/usr/include/heimdal -I/usr/athena/include -I../../dist/include/xp com -I../../dist/include/string -I../../dist/include/necko -I../../dist/include/ pref -I../../dist/include/negotiateauth -I../../dist/include -I/var/tmp/portage/ mozilla-1.7_rc1-r1/work/mozilla/dist/include/nspr -I. -I/usr/X11R6/include -fPIC -I/usr/X11R6/include -fno-rtti -fno-exceptions -Wall -Wconversion -Wpoin ter-arith -Wcast-align -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy -Wno- non-virtual-dtor -Wno-long-long -fforce-addr -Wno-deprecated -fshort-wchar -pthr ead -pipe -DNDEBUG -DTRIMMED -ffunction-sections -O2 -I/usr/X11R6/include -DMO ZILLA_CLIENT -include ../../mozilla-config.h -Wp,-MD,.deps/nsHttpGssapiAuth.pp n sHttpGssapiAuth.cpp nsHttpGssapiAuth.cpp:104: error: `OM_uint32' was not declared in this scope nsHttpGssapiAuth.cpp:104: error: parsningsfel before `,' token nsHttpGssapiAuth.cpp: In function `void LogGssError(...)': nsHttpGssapiAuth.cpp:106: error: `OM_uint32' undeclared (first use this function) nsHttpGssapiAuth.cpp:106: error: (Each undeclared identifier is reported only once for each function it appears in.) .... (The errors go on.) Expected Results: Succesful compilation! I have heimdal 0.62 installed. I tried to compile the mozilla-1.7_rc1-r1 ebuild from Gentoo. The problem arises in configure.in from overlooking to do AC_CHECK_HEADERS on gssapi.h in the krb5-config case. Because of this HAVE_GSSAPI_H won't be defined and then gssapi.h don't get included in nsHttpGssapiAuth.cpp. I've made a patch which I'll post when it's tested. This might be the same problem as in bug 245467.
looking forward to the patch.
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Target Milestone: --- → mozilla1.8alpha2
Attached patch possible patchSplinter Review
does this patch work?
Attached patch Proposed patch (obsolete) — Splinter Review
I didn't try your patch, but I can see that it suffers from the same subtle problem my first patch did: Since a check for gssapi.h is done earlier the added check won't be performed since the cached (negative) result of the earlier test will be reused. The attached patch worked for me. It's not done against CVS, but since at least this part of configure.in isn't changed it should work fine. I didn't bother doing the check for gssapi/gssapi.g since it shouldn't be needed with a correct krb5-config. I'm not quite pleased with my patch though. Why should only a krb5-config placed in /usr/bin och /usr/kerberos/bin be considered? Also, if libgssapi.so was found but not gssapi.h krb5-config won't be used to try finding gssapi.h. A revised patch will show up shortly.
Attached patch A better patchSplinter Review
Fixes the issues I mentioned. If you set --with-gssapi only krb5-config from given directory will be used (like before) otherwise use ordinary path.
Attachment #150395 - Attachment is obsolete: true
it doesn't build on SUSE 9.1 with heimdal with the same error message. So I understand that it didn't find all components? It's all in /usr/include/heimdal and /usr/lib.
It's not really that simple (see my original description). Anyway, please try my patch and report if it works.
It seems that is not the same problem for me. Yesterday I tried to build firefox and today I tried it with mozilla. The compile-commandline looks good and it should find the Headers but I got another error: Hercules:/usr/src/packages/BUILD/mozilla/extensions/negotiateauth# c++ -o nsHttpGssapiAuth.o -c -DOSTYPE=\"Linux2.6\" -DOSARCH=\"Linux\" -DHAVE_DEPENDENT_LIBS -I/usr/include/heimdal -I../../dist/include/xpcom -I../../dist/include/string -I../../dist/include/necko -I../../dist/include/pref -I../../dist/include/negotiateauth -I../../dist/include -I/usr/src/packages/BUILD/mozilla/dist/include/nspr -I. -I/usr/X11R6/include -fPIC -I/usr/X11R6/include -fno-rtti -fno-exceptions -Wall -Wconversion -Wpointer-arith -Wcast-align -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy -Wno-non-virtual-dtor -Wno-long-long -pedantic -O2 -march=i586 -mcpu=i686 -fmessage-length=0 -Wall -fno-strict-aliasing -fshort-wchar -pthread -pipe -DNDEBUG -DTRIMMED -ffunction-sections -O2 -march=i586 -mcpu=i686 -fmessage-length=0 -Wall -fno-strict-aliasing -I/usr/X11R6/include -DMOZILLA_CLIENT -include ../../mozilla-config.h -Wp,-MD,.deps/nsHttpGssapiAuth.pp nsHttpGssapiAuth.cpp In file included from ../../dist/include/xpcom/nsIServiceManager.h:178, from nsHttpGssapiAuth.cpp:73: ../../dist/include/xpcom/nsIServiceManagerUtils.h:48: warning: `class nsGetServiceByCID' has virtual functions but non-virtual destructor ../../dist/include/xpcom/nsIServiceManagerUtils.h:81: warning: `class nsGetServiceByContractID' has virtual functions but non-virtual destructor ../../dist/include/xpcom/nsIServiceManagerUtils.h:114: warning: `class nsGetServiceFromCategory' has virtual functions but non-virtual destructor nsHttpGssapiAuth.cpp:161: error: syntax error before `)' token nsHttpGssapiAuth.cpp:152: warning: `class nsGssapiContinuationState' has virtual functions but non-virtual destructor nsHttpGssapiAuth.cpp:163: error: ISO C++ forbids defining types within return type nsHttpGssapiAuth.cpp:163: error: syntax error before `;' token nsHttpGssapiAuth.cpp: In constructor `nsGssapiContinuationState::nsGssapiContinuationState()': nsHttpGssapiAuth.cpp:170: error: `OM_uint32' undeclared (first use this function) [many errors to follow] Any idea. To note that this is mozilla 1.7
OK, my error. My problems are only related to configure not configuring correctly for includes in /usr/include/heimdal. It would compile correcly if all the HAVE_ things would be correct IMHO. I can't test the patch easily because my autoconf doesn't like mozilla's configure.in and I'm too stupid for autoconf :-(
This also affects firefox-0.9. The patch supplied worked for me on Gentoo with heimdal against the firefox-0.9 tree. You have to run autoconf (Gentoo suplies all versions of autoconf). <a href="http://bugzilla.mozilla.org/show_bug.cgi?id=245467">Bug 245467</a> addresses same issue, since error messages are the same, only in German.
Blocks: 250014
Target Milestone: mozilla1.8alpha2 → mozilla1.8beta
Please try the patch in bug 245467. I believe it may help in this case as well.
Blocks: 277882
Downgrading to Severity:minor since this impacts relatively few users. I doubt I will have time to improve the build fu for this in time for Gecko 1.8. Patches welcome. Help wanted. Yadda yadda. See also bug 245467.
Severity: normal → minor
Keywords: helpwanted
Target Milestone: mozilla1.8beta1 → Future
Negotiateauth has now been changed to use an internal version of the gssapi.h header file, so any compilation problems with gssapi.h should be a thing of the past. The changes were made as part of the patch for bug #280792.
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
please note that the gentoo people have threatened to hack 1.7 in order to deal with this mess. i know we don't really want to backport stuff to 1.7, but i'd rather not see them hack our stuff *ever*.
(In reply to comment #13) > please note that the gentoo people have threatened to hack 1.7 in order to deal > with this mess. i know we don't really want to backport stuff to 1.7, but i'd > rather not see them hack our stuff *ever*. > If your gonna say gentoo people please include who ( as I am the only current gentoo dev working on mozilla products, this insinuates myself as making comment ) which is utter non-sence.
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: