Issue 98370

Summary: --with-system-mozilla always sucks in libxul.pc
Product: Build Tools Reporter: rene
Component: configureAssignee: caolanm
Status: CLOSED FIXED QA Contact: issues@tools <issues>
Severity: Trivial    
Priority: P3 CC: issues
Version: current   
Target Milestone: OOo 3.1   
Hardware: All   
OS: All   
Issue Type: DEFECT Latest Confirmation in: ---
Developer Difficulty: ---
Attachments:
Description Flags
How about this none

Description rene 2009-01-22 16:32:42 UTC
Hi,

I currently (probably soon to be changed) with --with-system-mozilla=iceape (=
seamonkey). This works. At least in a clean environment.

*if* you in addition also have xulrunner-dev there, libxul.pc is there and
because this part of configure.in (added by Issue 86670) unconditionally checks
for libxul and just takes its values if it's there the headers from iceape are
not taken..

Regards,

Rene
Comment 1 caolanm 2009-01-27 14:47:01 UTC
Created attachment 59704 [details]
How about this
Comment 2 rene 2009-01-28 10:36:50 UTC
--- configure.in	(revision 266964)
+++ configure.in	(working copy)
@@ -4029,7 +4029,13 @@
       PKG_CHECK_MODULES( MOZ_NSPR, $MOZ_FLAVOUR-nspr )
     fi
 
-    if $PKG_CONFIG --exists libxul ; then
+    if test "$MOZ_FLAVOUR" != "libxul"; then
+      PKG_CHECK_MODULES( MOZILLAXPCOM, $MOZ_FLAVOUR-xpcom, HASXPCOM="TRUE",
HASXPCOM="" )
+      MOZ_INC=`$PKG_CONFIG --variable=includedir $MOZ_FLAVOUR-xpcom`
+      MOZ_LIB=`$PKG_CONFIG --variable=libdir $MOZ_FLAVOUR-xpcom`
+    fi
+
+    if test -z "$HASXPCOM"; then
       PKG_CHECK_MODULES( MOZILLAXPCOM, libxul )
       MOZ_INC=`$PKG_CONFIG --variable=includedir libxul`
       MOZ_LIB=`$PKG_CONFIG --variable=libdir libxul`

why not just if .. else .. fi instead of test -z "$HASXPCOM"?
Comment 3 caolanm 2009-01-28 10:45:47 UTC
To support the case that I *think* might exist for
--with-system-mozilla=xulrunner
which may on some distributions provide "xulrunner-xpcom" while on others only
"libxul"
Comment 4 rene 2009-01-28 11:41:32 UTC
cmc: ah, yes, there was something..

committed to cws configure23
Comment 5 caolanm 2009-01-30 09:35:00 UTC
verified
Comment 6 caolanm 2009-03-20 15:45:22 UTC
integrated, closing