From 6c2022d1f41326dfdbd6921d6e27cc281b11a9d5 Mon Sep 17 00:00:00 2001 From: Kartikaya Gupta Date: Tue, 27 Dec 2011 00:56:57 -0500 Subject: [PATCH 01/28] Bug 712386 - Limit how much zoom can be applied. r=Cwiiis --- mobile/android/base/ui/PanZoomController.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/mobile/android/base/ui/PanZoomController.java b/mobile/android/base/ui/PanZoomController.java index 7e623476d50..7f3f244de0c 100644 --- a/mobile/android/base/ui/PanZoomController.java +++ b/mobile/android/base/ui/PanZoomController.java @@ -937,6 +937,14 @@ public class PanZoomController synchronized (mController) { float newZoomFactor = mController.getZoomFactor() * spanRatio; + if (newZoomFactor >= MAX_ZOOM) { + // apply resistance when zooming past MAX_ZOOM, + // such that it asymptotically reaches MAX_ZOOM + 1.0 + // but never exceeds that + float excessZoom = newZoomFactor - MAX_ZOOM; + excessZoom = 1.0f - (float)Math.exp(-excessZoom); + newZoomFactor = MAX_ZOOM + excessZoom; + } mController.scrollBy(new PointF(mLastZoomFocus.x - detector.getFocusX(), mLastZoomFocus.y - detector.getFocusY())); From 4edd9d9b6310ea4b6cf47de051d81e51855fd29d Mon Sep 17 00:00:00 2001 From: Kartikaya Gupta Date: Tue, 27 Dec 2011 00:57:27 -0500 Subject: [PATCH 02/28] Bug 710297 - Send page size updates to Java more often during load. r=Cwiiis --- mobile/android/chrome/content/browser.js | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/mobile/android/chrome/content/browser.js b/mobile/android/chrome/content/browser.js index 6278f22cc99..83865569014 100644 --- a/mobile/android/chrome/content/browser.js +++ b/mobile/android/chrome/content/browser.js @@ -1338,12 +1338,8 @@ Tab.prototype = { this._viewport.x = Math.round(this._viewport.x * this._viewport.zoom); this._viewport.y = Math.round(this._viewport.y * this._viewport.zoom); - /* - * Don't alter the page size until we hit DOMContentLoaded, because this causes the page size - * to jump around wildly during page load. - */ let doc = this.browser.contentDocument; - if (doc != null && doc.readyState === 'complete') { + if (doc != null) { let pageWidth = this._viewport.width, pageHeight = this._viewport.height; let body = doc.body || { scrollWidth: pageWidth, scrollHeight: pageHeight }; let html = doc.documentElement || { scrollWidth: pageWidth, scrollHeight: pageHeight }; @@ -1351,8 +1347,18 @@ Tab.prototype = { pageHeight = Math.max(body.scrollHeight, html.scrollHeight); /* Transform the page width and height based on the zoom factor. */ - this._viewport.pageWidth = Math.round(pageWidth * this._viewport.zoom); - this._viewport.pageHeight = Math.round(pageHeight * this._viewport.zoom); + pageWidth = Math.round(pageWidth * this._viewport.zoom); + pageHeight = Math.round(pageHeight * this._viewport.zoom); + + /* + * Avoid sending page sizes of less than screen size before we hit DOMContentLoaded, because + * this causes the page size to jump around wildly during page load. After the page is loaded, + * send updates regardless of page size; we'll zoom to fit the content as needed. + */ + if (doc.readyState === 'complete' || (pageWidth >= gScreenWidth && pageHeight >= gScreenHeight)) { + this._viewport.pageWidth = pageWidth; + this._viewport.pageHeight = pageHeight; + } } return this._viewport; From 65d41960bfde54910039176a9c5df84afb3dd08d Mon Sep 17 00:00:00 2001 From: Kartikaya Gupta Date: Tue, 27 Dec 2011 00:58:18 -0500 Subject: [PATCH 03/28] Bug 712761 - Fix returning incorrect object from openURI. r=dougt --- mobile/android/chrome/content/browser.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mobile/android/chrome/content/browser.js b/mobile/android/chrome/content/browser.js index 83865569014..f13d9882c9e 100644 --- a/mobile/android/chrome/content/browser.js +++ b/mobile/android/chrome/content/browser.js @@ -1085,7 +1085,7 @@ nsBrowserAccess.prototype = { openURI: function browser_openURI(aURI, aOpener, aWhere, aContext) { let browser = this._getBrowser(aURI, aOpener, aWhere, aContext); - return browser ? browser.QueryInterface(Ci.nsIFrameLoaderOwner) : null; + return browser ? browser.contentWindow : null; }, openURIInFrame: function browser_openURIInFrame(aURI, aOpener, aWhere, aContext) { From f3b3adf40a6999db724146b667b2530e66a33b93 Mon Sep 17 00:00:00 2001 From: Brad Lassey Date: Mon, 26 Dec 2011 10:19:27 -0500 Subject: [PATCH 04/28] Bug 712980 - java.lang.NullPointerException @ org.mozilla.gecko.GeckoPreferences.onPreferenceChange [r=mfinkle] --- mobile/android/base/GeckoPreferences.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mobile/android/base/GeckoPreferences.java b/mobile/android/base/GeckoPreferences.java index 6f815a60e45..b772003c47d 100644 --- a/mobile/android/base/GeckoPreferences.java +++ b/mobile/android/base/GeckoPreferences.java @@ -142,7 +142,7 @@ public class GeckoPreferences @Override public boolean onPreferenceChange(Preference preference, Object newValue) { String prefName = preference.getKey(); - if (prefName.equals("privacy.masterpassword.enabled")) { + if (prefName != null && prefName.equals("privacy.masterpassword.enabled")) { showDialog((Boolean)newValue ? DIALOG_CREATE_MASTER_PASSWORD : DIALOG_REMOVE_MASTER_PASSWORD); return false; } From 5fcd647a311a949ec74498586cc73c0c91bc018d Mon Sep 17 00:00:00 2001 From: Mark Finkle Date: Tue, 27 Dec 2011 01:07:41 -0500 Subject: [PATCH 05/28] Bug 713578 - java.lang.NullPointerException at org.mozilla.gecko.Tabs.closeTab [r=blassey] --- mobile/android/base/Tabs.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mobile/android/base/Tabs.java b/mobile/android/base/Tabs.java index 8a82e54cdd6..f12a2db1de5 100644 --- a/mobile/android/base/Tabs.java +++ b/mobile/android/base/Tabs.java @@ -141,7 +141,7 @@ public class Tabs implements GeckoEventListener { /** Close tab and then select nextTab */ public void closeTab(Tab tab, Tab nextTab) { - if (tab == null) + if (tab == null || nextTab == null) return; GeckoAppShell.sendEventToGecko(new GeckoEvent("Tab:Select", String.valueOf(nextTab.getId()))); From 6dae755e01f8953f25f20cc36ddb58737ff41454 Mon Sep 17 00:00:00 2001 From: Mark Finkle Date: Tue, 27 Dec 2011 01:07:44 -0500 Subject: [PATCH 06/28] Bug 713600 - MasterPassword helper is missing _tokenName [r=blassey] --- mobile/android/chrome/content/browser.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mobile/android/chrome/content/browser.js b/mobile/android/chrome/content/browser.js index f13d9882c9e..2ba0b78d028 100644 --- a/mobile/android/chrome/content/browser.js +++ b/mobile/android/chrome/content/browser.js @@ -3503,6 +3503,8 @@ var PermissionsHelper = { var MasterPassword = { pref: "privacy.masterpassword.enabled", + _tokenName: "", + get _secModuleDB() { delete this._secModuleDB; return this._secModuleDB = Cc["@mozilla.org/security/pkcs11moduledb;1"].getService(Ci.nsIPKCS11ModuleDB); From 1b41effe9259b21c0dc25121a870dcf44c9d6b90 Mon Sep 17 00:00:00 2001 From: Wesley Johnston Date: Tue, 27 Dec 2011 01:07:46 -0500 Subject: [PATCH 07/28] Bug 712627 - Fennec crashes if a long tap is performed in AwesomeBar/History [r=mfinkle] --- mobile/android/base/AwesomeBar.java | 65 ++++++++++++++++++++--------- 1 file changed, 46 insertions(+), 19 deletions(-) diff --git a/mobile/android/base/AwesomeBar.java b/mobile/android/base/AwesomeBar.java index 6bfae373fa9..8509f031cbb 100644 --- a/mobile/android/base/AwesomeBar.java +++ b/mobile/android/base/AwesomeBar.java @@ -68,10 +68,13 @@ import android.widget.AdapterView; import android.widget.AdapterView.AdapterContextMenuInfo; import android.widget.Button; import android.widget.EditText; +import android.widget.ExpandableListView; import android.widget.ImageButton; import android.widget.RelativeLayout; import android.widget.ListView; +import java.util.Map; + import org.mozilla.gecko.db.BrowserDB.URLColumns; import org.mozilla.gecko.db.BrowserDB; @@ -386,48 +389,76 @@ public class AwesomeBar extends Activity implements GeckoEventListener { GeckoAppShell.unregisterGeckoEventListener("SearchEngines:Data", this); } - private Cursor mContextMenuCursor = null; + private Object mContextMenuSubject = null; @Override public void onCreateContextMenu(ContextMenu menu, View view, ContextMenuInfo menuInfo) { super.onCreateContextMenu(menu, view, menuInfo); - - AdapterView.AdapterContextMenuInfo info = (AdapterView.AdapterContextMenuInfo) menuInfo; ListView list = (ListView) view; - Object selecteditem = list.getItemAtPosition(info.position); + Object selectedItem = null; + String title = ""; - if (!(selecteditem instanceof Cursor)) { - mContextMenuCursor = null; + if (view == (ListView)findViewById(R.id.history_list)) { + ExpandableListView.ExpandableListContextMenuInfo info = (ExpandableListView.ExpandableListContextMenuInfo) menuInfo; + ExpandableListView exList = (ExpandableListView)list; + int childPosition = exList.getPackedPositionChild(info.packedPosition); + int groupPosition = exList.getPackedPositionGroup(info.packedPosition); + Log.i(LOGTAG, "wesj - Got position " + groupPosition + " - " + childPosition); + selectedItem = exList.getExpandableListAdapter().getChild(groupPosition, childPosition); + + Map map = (Map)selectedItem; + title = (String)map.get(URLColumns.TITLE); + } else { + AdapterView.AdapterContextMenuInfo info = (AdapterView.AdapterContextMenuInfo) menuInfo; + selectedItem = list.getItemAtPosition(info.position); + + Cursor cursor = (Cursor)selectedItem; + title = cursor.getString(cursor.getColumnIndexOrThrow(URLColumns.TITLE)); + } + + if (selectedItem == null || !((selectedItem instanceof Cursor) || (selectedItem instanceof Map))) { + mContextMenuSubject = null; return; } - mContextMenuCursor = (Cursor) selecteditem; + mContextMenuSubject = selectedItem; MenuInflater inflater = getMenuInflater(); inflater.inflate(R.menu.awesomebar_contextmenu, menu); - String title = mContextMenuCursor.getString(mContextMenuCursor.getColumnIndexOrThrow(URLColumns.TITLE)); menu.setHeaderTitle(title); } @Override public boolean onContextItemSelected(MenuItem item) { - if (mContextMenuCursor == null) + if (mContextMenuSubject == null) return false; - AdapterContextMenuInfo info = (AdapterContextMenuInfo) item.getMenuInfo(); + String url = ""; + byte[] b = null; + String title = ""; + if (mContextMenuSubject instanceof Cursor) { + Cursor cursor = (Cursor)mContextMenuSubject; + url = cursor.getString(cursor.getColumnIndexOrThrow(URLColumns.URL)); + b = (byte[]) cursor.getBlob(cursor.getColumnIndexOrThrow(URLColumns.FAVICON)); + title = cursor.getString(cursor.getColumnIndexOrThrow(URLColumns.TITLE)); + } else if (mContextMenuSubject instanceof Map) { + Map map = (Map)mContextMenuSubject; + url = (String)map.get(URLColumns.URL); + b = (byte[]) map.get(URLColumns.FAVICON); + title = (String)map.get(URLColumns.TITLE); + } else { + return false; + } + + mContextMenuSubject = null; switch (item.getItemId()) { case R.id.open_new_tab: { - String url = mContextMenuCursor.getString(mContextMenuCursor.getColumnIndexOrThrow(URLColumns.URL)); GeckoApp.mAppContext.loadUrl(url, AwesomeBar.Type.ADD); break; } case R.id.add_to_launcher: { - String url = mContextMenuCursor.getString(mContextMenuCursor.getColumnIndexOrThrow(URLColumns.URL)); - byte[] b = (byte[]) mContextMenuCursor.getBlob(mContextMenuCursor.getColumnIndexOrThrow(URLColumns.FAVICON)); - String title = mContextMenuCursor.getString(mContextMenuCursor.getColumnIndexOrThrow(URLColumns.TITLE)); - Bitmap bitmap = null; if (b != null) bitmap = BitmapFactory.decodeByteArray(b, 0, b.length); @@ -436,18 +467,14 @@ public class AwesomeBar extends Activity implements GeckoEventListener { break; } case R.id.share: { - String url = mContextMenuCursor.getString(mContextMenuCursor.getColumnIndexOrThrow(URLColumns.URL)); - String title = mContextMenuCursor.getString(mContextMenuCursor.getColumnIndexOrThrow(URLColumns.TITLE)); GeckoAppShell.openUriExternal(url, "text/plain", "", "", Intent.ACTION_SEND, title); break; } default: { - mContextMenuCursor = null; return super.onContextItemSelected(item); } } - mContextMenuCursor = null; return true; } From bed1be399a69e39cbb52ac19054389435fa35f27 Mon Sep 17 00:00:00 2001 From: Mark Finkle Date: Tue, 27 Dec 2011 01:13:25 -0500 Subject: [PATCH 08/28] Bug 712627 - Fennec crashes if a long tap is performed in AwesomeBar/History (forgot to qref) [r=mfinkle] --- mobile/android/base/AwesomeBar.java | 1 - 1 file changed, 1 deletion(-) diff --git a/mobile/android/base/AwesomeBar.java b/mobile/android/base/AwesomeBar.java index 8509f031cbb..3b221bd5c52 100644 --- a/mobile/android/base/AwesomeBar.java +++ b/mobile/android/base/AwesomeBar.java @@ -403,7 +403,6 @@ public class AwesomeBar extends Activity implements GeckoEventListener { ExpandableListView exList = (ExpandableListView)list; int childPosition = exList.getPackedPositionChild(info.packedPosition); int groupPosition = exList.getPackedPositionGroup(info.packedPosition); - Log.i(LOGTAG, "wesj - Got position " + groupPosition + " - " + childPosition); selectedItem = exList.getExpandableListAdapter().getChild(groupPosition, childPosition); Map map = (Map)selectedItem; From 795395c3906b01a7d9fb6823e28fa1c3f6dbe097 Mon Sep 17 00:00:00 2001 From: Margaret Leibovic Date: Thu, 22 Dec 2011 11:50:44 -0800 Subject: [PATCH 09/28] Bug 712588 - Clear location not available in 'Clear Site Settings' [r=mfinkle] --- mobile/android/chrome/content/browser.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/mobile/android/chrome/content/browser.js b/mobile/android/chrome/content/browser.js index 2ba0b78d028..1536127a11f 100644 --- a/mobile/android/chrome/content/browser.js +++ b/mobile/android/chrome/content/browser.js @@ -3347,7 +3347,7 @@ var PluginHelper = { var PermissionsHelper = { - _permissonTypes: ["password", "geo", "popup", "indexedDB", + _permissonTypes: ["password", "geolocation", "popup", "indexedDB", "offline-app", "desktop-notification"], _permissionStrings: { "password": { @@ -3355,10 +3355,10 @@ var PermissionsHelper = { allowed: "password.remember", denied: "password.never" }, - "geo": { + "geolocation": { label: "geolocation.shareLocation", - allowed: "geolocation.alwaysShare", - denied: "geolocation.neverShare" + allowed: "geolocation.alwaysAllow", + denied: "geolocation.neverAllow" }, "popup": { label: "blockPopups.label", @@ -3450,7 +3450,7 @@ var PermissionsHelper = { * * @param aType * The permission type string stored in permission manager. - * e.g. "cookie", "geo", "indexedDB", "popup", "image" + * e.g. "geolocation", "indexedDB", "popup" * * @return A permission value defined in nsIPermissionManager. */ @@ -3471,7 +3471,7 @@ var PermissionsHelper = { } // Geolocation consumers use testExactPermission - if (aType == "geo") + if (aType == "geolocation") return Services.perms.testExactPermission(aURI, aType); return Services.perms.testPermission(aURI, aType); @@ -3482,7 +3482,7 @@ var PermissionsHelper = { * * @param aType * The permission type string stored in permission manager. - * e.g. "cookie", "geo", "indexedDB", "popup", "image" + * e.g. "geolocation", "indexedDB", "popup" */ clearPermission: function clearPermission(aURI, aType) { // Password saving isn't a nsIPermissionManager permission type, so handle From b9786eb1902e904121e9307df411a8668e18279a Mon Sep 17 00:00:00 2001 From: Margaret Leibovic Date: Wed, 21 Dec 2011 17:03:21 -0800 Subject: [PATCH 10/28] Bug 711216 - Form autocomplete popup doesn't disappear when input gets out of view after pinch zoom [r=mfinkle] --- mobile/android/base/ui/PanZoomController.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mobile/android/base/ui/PanZoomController.java b/mobile/android/base/ui/PanZoomController.java index 7f3f244de0c..6800252b66b 100644 --- a/mobile/android/base/ui/PanZoomController.java +++ b/mobile/android/base/ui/PanZoomController.java @@ -967,6 +967,7 @@ public class PanZoomController mState = PanZoomState.PINCHING; mLastZoomFocus = new PointF(detector.getFocusX(), detector.getFocusY()); GeckoApp.mAppContext.hidePluginViews(); + GeckoApp.mAppContext.mAutoCompletePopup.hide(); cancelTouch(); return true; @@ -1083,6 +1084,7 @@ public class PanZoomController private boolean animatedZoomTo(RectF zoomToRect) { GeckoApp.mAppContext.hidePluginViews(); + GeckoApp.mAppContext.mAutoCompletePopup.hide(); mState = PanZoomState.ANIMATED_ZOOM; final float startZoom = mController.getZoomFactor(); From cbe01cbc5bf8c0559b5617293fe319edbcbe1cc6 Mon Sep 17 00:00:00 2001 From: Bernd Date: Tue, 27 Dec 2011 09:31:09 +0100 Subject: [PATCH 11/28] bug 711359 - mark all subsequent rows as damaged r=mats --- layout/reftests/bugs/711359-1-ref.html | 13 +++++++++ layout/reftests/bugs/711359-1.html | 32 +++++++++++++++++++++ layout/reftests/bugs/712849-1-ref.html | 31 ++++++++++++++++++++ layout/reftests/bugs/712849-1.html | 39 ++++++++++++++++++++++++++ layout/reftests/bugs/reftest.list | 2 ++ layout/tables/nsCellMap.cpp | 14 ++++++--- 6 files changed, 127 insertions(+), 4 deletions(-) create mode 100644 layout/reftests/bugs/711359-1-ref.html create mode 100644 layout/reftests/bugs/711359-1.html create mode 100644 layout/reftests/bugs/712849-1-ref.html create mode 100644 layout/reftests/bugs/712849-1.html diff --git a/layout/reftests/bugs/711359-1-ref.html b/layout/reftests/bugs/711359-1-ref.html new file mode 100644 index 00000000000..1c66a54dd31 --- /dev/null +++ b/layout/reftests/bugs/711359-1-ref.html @@ -0,0 +1,13 @@ + + + + + + + + + +
 
 
 
+ + diff --git a/layout/reftests/bugs/711359-1.html b/layout/reftests/bugs/711359-1.html new file mode 100644 index 00000000000..871d6c17934 --- /dev/null +++ b/layout/reftests/bugs/711359-1.html @@ -0,0 +1,32 @@ + + + + + + + + + + + + + +
 
 
 
+ + diff --git a/layout/reftests/bugs/712849-1-ref.html b/layout/reftests/bugs/712849-1-ref.html new file mode 100644 index 00000000000..5c9c909f280 --- /dev/null +++ b/layout/reftests/bugs/712849-1-ref.html @@ -0,0 +1,31 @@ + + + + testcase + + + + + + + + +
 
 
 
 
+ + diff --git a/layout/reftests/bugs/712849-1.html b/layout/reftests/bugs/712849-1.html new file mode 100644 index 00000000000..83b4c434059 --- /dev/null +++ b/layout/reftests/bugs/712849-1.html @@ -0,0 +1,39 @@ + + + + testcase + + + + + + + + + +
 
 
 
 
+ + diff --git a/layout/reftests/bugs/reftest.list b/layout/reftests/bugs/reftest.list index bfe29a1a33a..3c98d8f0885 100644 --- a/layout/reftests/bugs/reftest.list +++ b/layout/reftests/bugs/reftest.list @@ -1677,3 +1677,5 @@ fails-if(layersGPUAccelerated&&cocoaWidget) == 654950-1.html 654950-1-ref.html # needs-focus == 703186-1.html 703186-1-ref.html needs-focus == 703186-2.html 703186-2-ref.html needs-focus != 703186-1.html 703186-2.html +== 711359-1.html 711359-1-ref.html +== 712849-1.html 712849-1-ref.html diff --git a/layout/tables/nsCellMap.cpp b/layout/tables/nsCellMap.cpp index b95b7e807d9..9362fb21957 100644 --- a/layout/tables/nsCellMap.cpp +++ b/layout/tables/nsCellMap.cpp @@ -1860,8 +1860,11 @@ nsCellMap::ExpandWithRows(nsTableCellMap& aMap, } newRowIndex++; } - SetDamageArea(0, aRgFirstRowIndex + startRowIndex, aMap.GetColCount(), - 1 + endRowIndex - startRowIndex, aDamageArea); + // mark all following rows damaged, they might contain a previously set + // damage area which we can not shift. + PRInt32 firstDamagedRow = aRgFirstRowIndex + startRowIndex; + SetDamageArea(0, firstDamagedRow, aMap.GetColCount(), + aMap.GetRowCount() - firstDamagedRow, aDamageArea); } void nsCellMap::ExpandWithCells(nsTableCellMap& aMap, @@ -2028,8 +2031,11 @@ void nsCellMap::ShrinkWithoutRows(nsTableCellMap& aMap, mContentRowCount--; } aMap.RemoveColsAtEnd(); - SetDamageArea(0, aRgFirstRowIndex + aStartRowIndex, aMap.GetColCount(), 0, - aDamageArea); + // mark all following rows damaged, they might contain a previously set + // damage area which we can not shift. + PRInt32 firstDamagedRow = aRgFirstRowIndex + aStartRowIndex; + SetDamageArea(0, firstDamagedRow, aMap.GetColCount(), + aMap.GetRowCount() - firstDamagedRow, aDamageArea); } PRInt32 nsCellMap::GetColSpanForNewCell(nsTableCellFrame& aCellFrameToAdd, From 4b0051c41952600c111f2d697c34cb417c637f7a Mon Sep 17 00:00:00 2001 From: Bernd Date: Tue, 27 Dec 2011 09:31:10 +0100 Subject: [PATCH 12/28] bug 531200 - always set the desiredHeight, also if SplitSpanningCells does not split any cell r=dholbert --- layout/reftests/bugs/531200-1-ref.html | 38 ++++++++++++++++++++++++++ layout/reftests/bugs/531200-1.html | 38 ++++++++++++++++++++++++++ layout/reftests/bugs/reftest.list | 1 + layout/tables/nsTableRowGroupFrame.cpp | 5 ++++ 4 files changed, 82 insertions(+) create mode 100644 layout/reftests/bugs/531200-1-ref.html create mode 100644 layout/reftests/bugs/531200-1.html diff --git a/layout/reftests/bugs/531200-1-ref.html b/layout/reftests/bugs/531200-1-ref.html new file mode 100644 index 00000000000..d9631a4336c --- /dev/null +++ b/layout/reftests/bugs/531200-1-ref.html @@ -0,0 +1,38 @@ + + +push rowspan on to next page if it can't be splitted + + + +
+ + + + + + + + + + + + + + + +
+ +
+ +
+ +
+ +
+ + diff --git a/layout/reftests/bugs/531200-1.html b/layout/reftests/bugs/531200-1.html new file mode 100644 index 00000000000..7751ddf76ac --- /dev/null +++ b/layout/reftests/bugs/531200-1.html @@ -0,0 +1,38 @@ + + +push rowspan on to next page if it can't be splitted + + + +
+ + + + + + + + + + + + + + + +
+ +
+ +
+ +
+ +
+ + diff --git a/layout/reftests/bugs/reftest.list b/layout/reftests/bugs/reftest.list index 3c98d8f0885..e132e5e833d 100644 --- a/layout/reftests/bugs/reftest.list +++ b/layout/reftests/bugs/reftest.list @@ -1445,6 +1445,7 @@ random-if(d2d) == 523468-1.html 523468-1-ref.html == 528096-1.html 528096-1-ref.html == 530686-1.html 530686-1-ref.html == 531098-1.html 531098-1-ref.html +== 531200-1.html 531200-1-ref.html == 531371-1.html 531371-1-ref.html == 534526-1a.html 534526-1-ref.html == 534526-1b.html 534526-1-ref.html diff --git a/layout/tables/nsTableRowGroupFrame.cpp b/layout/tables/nsTableRowGroupFrame.cpp index 1e6333703cf..a1638f304fb 100644 --- a/layout/tables/nsTableRowGroupFrame.cpp +++ b/layout/tables/nsTableRowGroupFrame.cpp @@ -955,6 +955,7 @@ nsTableRowGroupFrame::SplitSpanningCells(nsPresContext& aPresContext, static_cast(aTable.GetFirstInFlow())->IsBorderCollapse(); PRInt32 lastRowIndex = aLastRow.GetRowIndex(); bool wasLast = false; + bool haveRowSpan = false; // Iterate the rows between aFirstRow and aLastRow for (nsTableRowFrame* row = &aFirstRow; !wasLast; row = row->GetNextRow()) { wasLast = (row == &aLastRow); @@ -966,6 +967,7 @@ nsTableRowGroupFrame::SplitSpanningCells(nsPresContext& aPresContext, // Only reflow rowspan > 1 cells which span aLastRow. Those which don't span aLastRow // were reflowed correctly during the unconstrained height reflow. if ((rowSpan > 1) && (rowIndex + rowSpan > lastRowIndex)) { + haveRowSpan = true; nsReflowStatus status; // Ask the row to reflow the cell to the height of all the rows it spans up through aLastRow // aAvailHeight is the space between the row group start and the end of the page @@ -1021,6 +1023,9 @@ nsTableRowGroupFrame::SplitSpanningCells(nsPresContext& aPresContext, } } } + if (!haveRowSpan) { + aDesiredHeight = aLastRow.GetRect().YMost(); + } } // Remove the next-in-flow of the row, its cells and their cell blocks. This From ae31b5a0e88b04bbd4be77d42757847c31e55cd2 Mon Sep 17 00:00:00 2001 From: Andrew Quartey Date: Tue, 27 Dec 2011 09:31:22 +0100 Subject: [PATCH 13/28] Bug 507419-Consistent ordering of AppendFrames and InsertFrames --- layout/tables/nsTableRowFrame.cpp | 30 +++++++++--------------------- 1 file changed, 9 insertions(+), 21 deletions(-) diff --git a/layout/tables/nsTableRowFrame.cpp b/layout/tables/nsTableRowFrame.cpp index 6835b1d968c..eeb0b012269 100644 --- a/layout/tables/nsTableRowFrame.cpp +++ b/layout/tables/nsTableRowFrame.cpp @@ -206,20 +206,14 @@ nsTableRowFrame::AppendFrames(ChildListID aListID, { NS_ASSERTION(aListID == kPrincipalList, "unexpected child list"); - // Append the frames - // XXXbz why do we append here first, then append to table, while - // for InsertFrames we do it in the other order? Bug 507419 covers this. const nsFrameList::Slice& newCells = mFrames.AppendFrames(nsnull, aFrameList); // Add the new cell frames to the table nsTableFrame *tableFrame = nsTableFrame::GetTableFrame(this); for (nsFrameList::Enumerator e(newCells) ; !e.AtEnd(); e.Next()) { - nsTableCellFrame *cellFrame = do_QueryFrame(e.get()); - NS_ASSERTION(cellFrame, "Unexpected frame"); - if (cellFrame) { - // Add the cell to the cell map - tableFrame->AppendCell(*cellFrame, GetRowIndex()); - } + nsIFrame *childFrame = e.get(); + NS_ASSERTION(IS_TABLE_CELL(childFrame->GetType()),"Not a table cell frame/pseudo frame construction failure"); + tableFrame->AppendCell(static_cast(*childFrame), GetRowIndex()); } PresContext()->PresShell()->FrameNeedsReflow(this, nsIPresShell::eTreeChange, @@ -238,22 +232,19 @@ nsTableRowFrame::InsertFrames(ChildListID aListID, NS_ASSERTION(aListID == kPrincipalList, "unexpected child list"); NS_ASSERTION(!aPrevFrame || aPrevFrame->GetParent() == this, "inserting after sibling frame with different parent"); + //Insert Frames in the frame list + const nsFrameList::Slice& newCells = mFrames.InsertFrames(nsnull, aPrevFrame, aFrameList); // Get the table frame nsTableFrame* tableFrame = nsTableFrame::GetTableFrame(this); - // gather the new frames (only those which are cells) into an array - // XXXbz there shouldn't be any other ones here... can we just put - // them all in the array and not do all this QI nonsense? nsIAtom* cellFrameType = (tableFrame->IsBorderCollapse()) ? nsGkAtoms::bcTableCellFrame : nsGkAtoms::tableCellFrame; nsTableCellFrame* prevCellFrame = (nsTableCellFrame *)nsTableFrame::GetFrameAtOrBefore(this, aPrevFrame, cellFrameType); nsTArray cellChildren; - for (nsFrameList::Enumerator e(aFrameList); !e.AtEnd(); e.Next()) { - nsTableCellFrame *cellFrame = do_QueryFrame(e.get()); - NS_ASSERTION(cellFrame, "Unexpected frame"); - if (cellFrame) { - cellChildren.AppendElement(cellFrame); - } + for (nsFrameList::Enumerator e(newCells); !e.AtEnd(); e.Next()) { + nsIFrame *childFrame = e.get(); + NS_ASSERTION(IS_TABLE_CELL(childFrame->GetType()),"Not a table cell frame/pseudo frame construction failure"); + cellChildren.AppendElement(static_cast(childFrame)); } // insert the cells into the cell map PRInt32 colIndex = -1; @@ -261,9 +252,6 @@ nsTableRowFrame::InsertFrames(ChildListID aListID, prevCellFrame->GetColIndex(colIndex); } tableFrame->InsertCells(cellChildren, GetRowIndex(), colIndex); - - // Insert the frames in the frame list - mFrames.InsertFrames(nsnull, aPrevFrame, aFrameList); PresContext()->PresShell()->FrameNeedsReflow(this, nsIPresShell::eTreeChange, NS_FRAME_HAS_DIRTY_CHILDREN); From 03d5fe82abb32be8b46a0b29e507d5d5d2d8aa15 Mon Sep 17 00:00:00 2001 From: Makoto Kato Date: Tue, 27 Dec 2011 18:01:12 +0900 Subject: [PATCH 14/28] Bug 712870 - Skia works on non-tier1 cpu. r=mattwoodrow --- gfx/skia/Makefile.in | 27 ++++++++++++++++++++------- 1 file changed, 20 insertions(+), 7 deletions(-) diff --git a/gfx/skia/Makefile.in b/gfx/skia/Makefile.in index 9bcac806ead..1a41171fa19 100644 --- a/gfx/skia/Makefile.in +++ b/gfx/skia/Makefile.in @@ -302,22 +302,15 @@ EXPORTS_skia += \ $(NULL) CPPSRCS += \ SkFontHost_mac_coretext.cpp \ - SkBitmapProcState_opts_SSE2.cpp \ - SkBlitRow_opts_SSE2.cpp \ - SkUtils_opts_SSE2.cpp \ - opts_check_SSE2.cpp \ SkTime_Unix.cpp \ $(NULL) endif ifeq (android,$(MOZ_WIDGET_TOOLKIT)) CPPSRCS += \ - SkBitmapProcState_opts_arm.cpp \ - SkBlitRow_opts_arm.cpp \ SkFontHost_FreeType.cpp \ SkFontHost_android.cpp \ SkFontHost_gamma.cpp \ - SkUtils_opts_none.cpp \ SkMMapStream.cpp \ SkTime_Unix.cpp \ $(NULL) @@ -334,11 +327,31 @@ EXPORTS_skia += \ CPPSRCS += \ SkFontHost_win.cpp \ SkTime_win.cpp \ + $(NULL) +endif + +ifneq (,$(INTEL_ARCHITECTURE)) +CPPSRCS += \ SkBitmapProcState_opts_SSE2.cpp \ SkBlitRow_opts_SSE2.cpp \ SkUtils_opts_SSE2.cpp \ opts_check_SSE2.cpp \ $(NULL) +else +ifeq ($(CPU_ARCH)_$(GNU_CC),arm_1) +CPPSRCS += \ + SkBitmapProcState_opts_arm.cpp \ + SkBlitRow_opts_arm.cpp \ + opts_check_arm.cpp \ + $(NULL) +SSRCS += memset.arm.S +else +CPPSRCS += \ + SkBitmapProcState_opts_none.cpp \ + SkBlitRow_opts_none.cpp \ + SkUtils_opts_none.cpp \ + $(NULL) +endif endif include $(topsrcdir)/config/rules.mk From 17bd600d2e42bb8d7d6613b5a5aa92cd62efd183 Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Fri, 23 Dec 2011 13:21:35 +0100 Subject: [PATCH 15/28] Bug 712254 - Use StdInt.h in platform.h r=BenWa --HG-- extra : rebase_source : 5f5fcf8fff315097638829d95594e347052955ed --- tools/profiler/sps/platform-linux.cc | 1 - tools/profiler/sps/platform-macos.cc | 1 - tools/profiler/sps/platform-win32.cc | 1 - tools/profiler/sps/platform.h | 13 ++----------- tools/profiler/sps/v8-support.h | 6 +----- 5 files changed, 3 insertions(+), 19 deletions(-) diff --git a/tools/profiler/sps/platform-linux.cc b/tools/profiler/sps/platform-linux.cc index 3ed85b25450..8a855ad5269 100644 --- a/tools/profiler/sps/platform-linux.cc +++ b/tools/profiler/sps/platform-linux.cc @@ -34,7 +34,6 @@ #include // index #include #include -#include "v8-support.h" #include "platform.h" #include diff --git a/tools/profiler/sps/platform-macos.cc b/tools/profiler/sps/platform-macos.cc index 78fe23bb338..e3bb2bfcaf9 100644 --- a/tools/profiler/sps/platform-macos.cc +++ b/tools/profiler/sps/platform-macos.cc @@ -25,7 +25,6 @@ #include -#include "v8-support.h" #include "platform.h" // this port is based off of v8 svn revision 9837 diff --git a/tools/profiler/sps/platform-win32.cc b/tools/profiler/sps/platform-win32.cc index 3513650985c..f59ad45a315 100644 --- a/tools/profiler/sps/platform-win32.cc +++ b/tools/profiler/sps/platform-win32.cc @@ -3,7 +3,6 @@ // found in the LICENSE file. #include -#include "v8-support.h" #include "platform.h" #include diff --git a/tools/profiler/sps/platform.h b/tools/profiler/sps/platform.h index f7c7d5f7c80..092113928f6 100644 --- a/tools/profiler/sps/platform.h +++ b/tools/profiler/sps/platform.h @@ -8,6 +8,7 @@ #define __android_log_print(a, ...) #endif +#include "mozilla/StdInt.h" #include "mozilla/Util.h" #include "mozilla/unused.h" #include "mozilla/TimeStamp.h" @@ -21,17 +22,7 @@ #define LOG(text) printf("Profiler: %s\n", text) #endif -#ifdef _MSC_VER - typedef __int8 byte; - typedef __int32 int32_t; - typedef unsigned __int32 uint32_t; - typedef __int64 int64_t; - typedef unsigned __int64 uint64_t; -#else - #include - typedef uint8 byte; -#endif -typedef byte* Address; +typedef uint8_t* Address; class MapEntry { public: diff --git a/tools/profiler/sps/v8-support.h b/tools/profiler/sps/v8-support.h index e7ddd446c53..3478a61b79c 100644 --- a/tools/profiler/sps/v8-support.h +++ b/tools/profiler/sps/v8-support.h @@ -51,11 +51,7 @@ #warning Please add support for your architecture in chromium_types.h #endif -#ifdef _WIN32 - typedef __int32 Atomic32; -#else - typedef int32_t Atomic32; -#endif +typedef int32_t Atomic32; #if defined(V8_HOST_ARCH_X64) || defined(V8_HOST_ARCH_IA32) || defined(V8_HOST_ARCH_ARM) inline void NoBarrier_Store(volatile Atomic32* ptr, Atomic32 value) { From ae667ff63c6657f08f9e275b07cd01fb1bd1b339 Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Fri, 23 Dec 2011 13:22:48 +0100 Subject: [PATCH 16/28] Bug 712594 - libffi fails to build on mingw-w64 r=bsmedberg --HG-- extra : rebase_source : 498652c35d8f628d276a938f2c526e2a44a6eb07 --- js/src/ctypes/libffi/aclocal.m4 | 805 +++++++++++++ js/src/ctypes/libffi/configure | 58 + js/src/ctypes/libffi/configure.ac | 7 + js/src/ctypes/libffi/src/x86/win64.S | 22 +- .../ctypes/patches-libffi/03-bug-712594.patch | 1072 +++++++++++++++++ 5 files changed, 1957 insertions(+), 7 deletions(-) create mode 100644 js/src/ctypes/patches-libffi/03-bug-712594.patch diff --git a/js/src/ctypes/libffi/aclocal.m4 b/js/src/ctypes/libffi/aclocal.m4 index d5eb6a612fd..41012e3f319 100644 --- a/js/src/ctypes/libffi/aclocal.m4 +++ b/js/src/ctypes/libffi/aclocal.m4 @@ -7364,6 +7364,811 @@ _LT_EOF esac ]) +# ltdl.m4 - Configure ltdl for the target system. -*-Autoconf-*- +# +# Copyright (C) 1999-2006, 2007, 2008 Free Software Foundation, Inc. +# Written by Thomas Tanner, 1999 +# +# This file is free software; the Free Software Foundation gives +# unlimited permission to copy and/or distribute it, with or without +# modifications, as long as this notice is preserved. + +# serial 17 LTDL_INIT + +# LT_CONFIG_LTDL_DIR(DIRECTORY, [LTDL-MODE]) +# ------------------------------------------ +# DIRECTORY contains the libltdl sources. It is okay to call this +# function multiple times, as long as the same DIRECTORY is always given. +AC_DEFUN([LT_CONFIG_LTDL_DIR], +[AC_BEFORE([$0], [LTDL_INIT]) +_$0($*) +])# LT_CONFIG_LTDL_DIR + +# We break this out into a separate macro, so that we can call it safely +# internally without being caught accidentally by the sed scan in libtoolize. +m4_defun([_LT_CONFIG_LTDL_DIR], +[dnl remove trailing slashes +m4_pushdef([_ARG_DIR], m4_bpatsubst([$1], [/*$])) +m4_case(_LTDL_DIR, + [], [dnl only set lt_ltdl_dir if _ARG_DIR is not simply `.' + m4_if(_ARG_DIR, [.], + [], + [m4_define([_LTDL_DIR], _ARG_DIR) + _LT_SHELL_INIT([lt_ltdl_dir=']_ARG_DIR['])])], + [m4_if(_ARG_DIR, _LTDL_DIR, + [], + [m4_fatal([multiple libltdl directories: `]_LTDL_DIR[', `]_ARG_DIR['])])]) +m4_popdef([_ARG_DIR]) +])# _LT_CONFIG_LTDL_DIR + +# Initialise: +m4_define([_LTDL_DIR], []) + + +# _LT_BUILD_PREFIX +# ---------------- +# If Autoconf is new enough, expand to `${top_build_prefix}', otherwise +# to `${top_builddir}/'. +m4_define([_LT_BUILD_PREFIX], +[m4_ifdef([AC_AUTOCONF_VERSION], + [m4_if(m4_version_compare(m4_defn([AC_AUTOCONF_VERSION]), [2.62]), + [-1], [m4_ifdef([_AC_HAVE_TOP_BUILD_PREFIX], + [${top_build_prefix}], + [${top_builddir}/])], + [${top_build_prefix}])], + [${top_builddir}/])[]dnl +]) + + +# LTDL_CONVENIENCE +# ---------------- +# sets LIBLTDL to the link flags for the libltdl convenience library and +# LTDLINCL to the include flags for the libltdl header and adds +# --enable-ltdl-convenience to the configure arguments. Note that +# AC_CONFIG_SUBDIRS is not called here. LIBLTDL will be prefixed with +# '${top_build_prefix}' if available, otherwise with '${top_builddir}/', +# and LTDLINCL will be prefixed with '${top_srcdir}/' (note the single +# quotes!). If your package is not flat and you're not using automake, +# define top_build_prefix, top_builddir, and top_srcdir appropriately +# in your Makefiles. +AC_DEFUN([LTDL_CONVENIENCE], +[AC_BEFORE([$0], [LTDL_INIT])dnl +dnl Although the argument is deprecated and no longer documented, +dnl LTDL_CONVENIENCE used to take a DIRECTORY orgument, if we have one +dnl here make sure it is the same as any other declaration of libltdl's +dnl location! This also ensures lt_ltdl_dir is set when configure.ac is +dnl not yet using an explicit LT_CONFIG_LTDL_DIR. +m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl +_$0() +])# LTDL_CONVENIENCE + +# AC_LIBLTDL_CONVENIENCE accepted a directory argument in older libtools, +# now we have LT_CONFIG_LTDL_DIR: +AU_DEFUN([AC_LIBLTDL_CONVENIENCE], +[_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])]) +_LTDL_CONVENIENCE]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBLTDL_CONVENIENCE], []) + + +# _LTDL_CONVENIENCE +# ----------------- +# Code shared by LTDL_CONVENIENCE and LTDL_INIT([convenience]). +m4_defun([_LTDL_CONVENIENCE], +[case $enable_ltdl_convenience in + no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; + "") enable_ltdl_convenience=yes + ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; +esac +LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdlc.la" +LTDLDEPS=$LIBLTDL +LTDLINCL='-I${top_srcdir}'"${lt_ltdl_dir+/$lt_ltdl_dir}" + +AC_SUBST([LIBLTDL]) +AC_SUBST([LTDLDEPS]) +AC_SUBST([LTDLINCL]) + +# For backwards non-gettext consistent compatibility... +INCLTDL="$LTDLINCL" +AC_SUBST([INCLTDL]) +])# _LTDL_CONVENIENCE + + +# LTDL_INSTALLABLE +# ---------------- +# sets LIBLTDL to the link flags for the libltdl installable library +# and LTDLINCL to the include flags for the libltdl header and adds +# --enable-ltdl-install to the configure arguments. Note that +# AC_CONFIG_SUBDIRS is not called from here. If an installed libltdl +# is not found, LIBLTDL will be prefixed with '${top_build_prefix}' if +# available, otherwise with '${top_builddir}/', and LTDLINCL will be +# prefixed with '${top_srcdir}/' (note the single quotes!). If your +# package is not flat and you're not using automake, define top_build_prefix, +# top_builddir, and top_srcdir appropriately in your Makefiles. +# In the future, this macro may have to be called after LT_INIT. +AC_DEFUN([LTDL_INSTALLABLE], +[AC_BEFORE([$0], [LTDL_INIT])dnl +dnl Although the argument is deprecated and no longer documented, +dnl LTDL_INSTALLABLE used to take a DIRECTORY orgument, if we have one +dnl here make sure it is the same as any other declaration of libltdl's +dnl location! This also ensures lt_ltdl_dir is set when configure.ac is +dnl not yet using an explicit LT_CONFIG_LTDL_DIR. +m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl +_$0() +])# LTDL_INSTALLABLE + +# AC_LIBLTDL_INSTALLABLE accepted a directory argument in older libtools, +# now we have LT_CONFIG_LTDL_DIR: +AU_DEFUN([AC_LIBLTDL_INSTALLABLE], +[_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])]) +_LTDL_INSTALLABLE]) + +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIBLTDL_INSTALLABLE], []) + + +# _LTDL_INSTALLABLE +# ----------------- +# Code shared by LTDL_INSTALLABLE and LTDL_INIT([installable]). +m4_defun([_LTDL_INSTALLABLE], +[if test -f $prefix/lib/libltdl.la; then + lt_save_LDFLAGS="$LDFLAGS" + LDFLAGS="-L$prefix/lib $LDFLAGS" + AC_CHECK_LIB([ltdl], [lt_dlinit], [lt_lib_ltdl=yes]) + LDFLAGS="$lt_save_LDFLAGS" + if test x"${lt_lib_ltdl-no}" = xyes; then + if test x"$enable_ltdl_install" != xyes; then + # Don't overwrite $prefix/lib/libltdl.la without --enable-ltdl-install + AC_MSG_WARN([not overwriting libltdl at $prefix, force with `--enable-ltdl-install']) + enable_ltdl_install=no + fi + elif test x"$enable_ltdl_install" = xno; then + AC_MSG_WARN([libltdl not installed, but installation disabled]) + fi +fi + +# If configure.ac declared an installable ltdl, and the user didn't override +# with --disable-ltdl-install, we will install the shipped libltdl. +case $enable_ltdl_install in + no) ac_configure_args="$ac_configure_args --enable-ltdl-install=no" + LIBLTDL="-lltdl" + LTDLDEPS= + LTDLINCL= + ;; + *) enable_ltdl_install=yes + ac_configure_args="$ac_configure_args --enable-ltdl-install" + LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdl.la" + LTDLDEPS=$LIBLTDL + LTDLINCL='-I${top_srcdir}'"${lt_ltdl_dir+/$lt_ltdl_dir}" + ;; +esac + +AC_SUBST([LIBLTDL]) +AC_SUBST([LTDLDEPS]) +AC_SUBST([LTDLINCL]) + +# For backwards non-gettext consistent compatibility... +INCLTDL="$LTDLINCL" +AC_SUBST([INCLTDL]) +])# LTDL_INSTALLABLE + + +# _LTDL_MODE_DISPATCH +# ------------------- +m4_define([_LTDL_MODE_DISPATCH], +[dnl If _LTDL_DIR is `.', then we are configuring libltdl itself: +m4_if(_LTDL_DIR, [], + [], + dnl if _LTDL_MODE was not set already, the default value is `subproject': + [m4_case(m4_default(_LTDL_MODE, [subproject]), + [subproject], [AC_CONFIG_SUBDIRS(_LTDL_DIR) + _LT_SHELL_INIT([lt_dlopen_dir="$lt_ltdl_dir"])], + [nonrecursive], [_LT_SHELL_INIT([lt_dlopen_dir="$lt_ltdl_dir"; lt_libobj_prefix="$lt_ltdl_dir/"])], + [recursive], [], + [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])])dnl +dnl Be careful not to expand twice: +m4_define([$0], []) +])# _LTDL_MODE_DISPATCH + + +# _LT_LIBOBJ(MODULE_NAME) +# ----------------------- +# Like AC_LIBOBJ, except that MODULE_NAME goes into _LT_LIBOBJS instead +# of into LIBOBJS. +AC_DEFUN([_LT_LIBOBJ], [ + m4_pattern_allow([^_LT_LIBOBJS$]) + _LT_LIBOBJS="$_LT_LIBOBJS $1.$ac_objext" +])# _LT_LIBOBJS + + +# LTDL_INIT([OPTIONS]) +# -------------------- +# Clients of libltdl can use this macro to allow the installer to +# choose between a shipped copy of the ltdl sources or a preinstalled +# version of the library. If the shipped ltdl sources are not in a +# subdirectory named libltdl, the directory name must be given by +# LT_CONFIG_LTDL_DIR. +AC_DEFUN([LTDL_INIT], +[dnl Parse OPTIONS +_LT_SET_OPTIONS([$0], [$1]) + +dnl We need to keep our own list of libobjs separate from our parent project, +dnl and the easiest way to do that is redefine the AC_LIBOBJs macro while +dnl we look for our own LIBOBJs. +m4_pushdef([AC_LIBOBJ], m4_defn([_LT_LIBOBJ])) +m4_pushdef([AC_LIBSOURCES]) + +dnl If not otherwise defined, default to the 1.5.x compatible subproject mode: +m4_if(_LTDL_MODE, [], + [m4_define([_LTDL_MODE], m4_default([$2], [subproject])) + m4_if([-1], [m4_bregexp(_LTDL_MODE, [\(subproject\|\(non\)?recursive\)])], + [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])]) + +AC_ARG_WITH([included_ltdl], + [AS_HELP_STRING([--with-included-ltdl], + [use the GNU ltdl sources included here])]) + +if test "x$with_included_ltdl" != xyes; then + # We are not being forced to use the included libltdl sources, so + # decide whether there is a useful installed version we can use. + AC_CHECK_HEADER([ltdl.h], + [AC_CHECK_DECL([lt_dlinterface_register], + [AC_CHECK_LIB([ltdl], [lt_dladvise_preload], + [with_included_ltdl=no], + [with_included_ltdl=yes])], + [with_included_ltdl=yes], + [AC_INCLUDES_DEFAULT + #include ])], + [with_included_ltdl=yes], + [AC_INCLUDES_DEFAULT] + ) +fi + +dnl If neither LT_CONFIG_LTDL_DIR, LTDL_CONVENIENCE nor LTDL_INSTALLABLE +dnl was called yet, then for old times' sake, we assume libltdl is in an +dnl eponymous directory: +AC_PROVIDE_IFELSE([LT_CONFIG_LTDL_DIR], [], [_LT_CONFIG_LTDL_DIR([libltdl])]) + +AC_ARG_WITH([ltdl_include], + [AS_HELP_STRING([--with-ltdl-include=DIR], + [use the ltdl headers installed in DIR])]) + +if test -n "$with_ltdl_include"; then + if test -f "$with_ltdl_include/ltdl.h"; then : + else + AC_MSG_ERROR([invalid ltdl include directory: `$with_ltdl_include']) + fi +else + with_ltdl_include=no +fi + +AC_ARG_WITH([ltdl_lib], + [AS_HELP_STRING([--with-ltdl-lib=DIR], + [use the libltdl.la installed in DIR])]) + +if test -n "$with_ltdl_lib"; then + if test -f "$with_ltdl_lib/libltdl.la"; then : + else + AC_MSG_ERROR([invalid ltdl library directory: `$with_ltdl_lib']) + fi +else + with_ltdl_lib=no +fi + +case ,$with_included_ltdl,$with_ltdl_include,$with_ltdl_lib, in + ,yes,no,no,) + m4_case(m4_default(_LTDL_TYPE, [convenience]), + [convenience], [_LTDL_CONVENIENCE], + [installable], [_LTDL_INSTALLABLE], + [m4_fatal([unknown libltdl build type: ]_LTDL_TYPE)]) + ;; + ,no,no,no,) + # If the included ltdl is not to be used, then use the + # preinstalled libltdl we found. + AC_DEFINE([HAVE_LTDL], [1], + [Define this if a modern libltdl is already installed]) + LIBLTDL=-lltdl + LTDLDEPS= + LTDLINCL= + ;; + ,no*,no,*) + AC_MSG_ERROR([`--with-ltdl-include' and `--with-ltdl-lib' options must be used together]) + ;; + *) with_included_ltdl=no + LIBLTDL="-L$with_ltdl_lib -lltdl" + LTDLDEPS= + LTDLINCL="-I$with_ltdl_include" + ;; +esac +INCLTDL="$LTDLINCL" + +# Report our decision... +AC_MSG_CHECKING([where to find libltdl headers]) +AC_MSG_RESULT([$LTDLINCL]) +AC_MSG_CHECKING([where to find libltdl library]) +AC_MSG_RESULT([$LIBLTDL]) + +_LTDL_SETUP + +dnl restore autoconf definition. +m4_popdef([AC_LIBOBJ]) +m4_popdef([AC_LIBSOURCES]) + +AC_CONFIG_COMMANDS_PRE([ + _ltdl_libobjs= + _ltdl_ltlibobjs= + if test -n "$_LT_LIBOBJS"; then + # Remove the extension. + _lt_sed_drop_objext='s/\.o$//;s/\.obj$//' + for i in `for i in $_LT_LIBOBJS; do echo "$i"; done | sed "$_lt_sed_drop_objext" | sort -u`; do + _ltdl_libobjs="$_ltdl_libobjs $lt_libobj_prefix$i.$ac_objext" + _ltdl_ltlibobjs="$_ltdl_ltlibobjs $lt_libobj_prefix$i.lo" + done + fi + AC_SUBST([ltdl_LIBOBJS], [$_ltdl_libobjs]) + AC_SUBST([ltdl_LTLIBOBJS], [$_ltdl_ltlibobjs]) +]) + +# Only expand once: +m4_define([LTDL_INIT]) +])# LTDL_INIT + +# Old names: +AU_DEFUN([AC_LIB_LTDL], [LTDL_INIT($@)]) +AU_DEFUN([AC_WITH_LTDL], [LTDL_INIT($@)]) +AU_DEFUN([LT_WITH_LTDL], [LTDL_INIT($@)]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LIB_LTDL], []) +dnl AC_DEFUN([AC_WITH_LTDL], []) +dnl AC_DEFUN([LT_WITH_LTDL], []) + + +# _LTDL_SETUP +# ----------- +# Perform all the checks necessary for compilation of the ltdl objects +# -- including compiler checks and header checks. This is a public +# interface mainly for the benefit of libltdl's own configure.ac, most +# other users should call LTDL_INIT instead. +AC_DEFUN([_LTDL_SETUP], +[AC_REQUIRE([AC_PROG_CC])dnl +AC_REQUIRE([LT_SYS_MODULE_EXT])dnl +AC_REQUIRE([LT_SYS_MODULE_PATH])dnl +AC_REQUIRE([LT_SYS_DLSEARCH_PATH])dnl +AC_REQUIRE([LT_LIB_DLLOAD])dnl +AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl +AC_REQUIRE([LT_FUNC_DLSYM_USCORE])dnl +AC_REQUIRE([LT_SYS_DLOPEN_DEPLIBS])dnl +AC_REQUIRE([gl_FUNC_ARGZ])dnl + +m4_require([_LT_CHECK_OBJDIR])dnl +m4_require([_LT_HEADER_DLFCN])dnl +m4_require([_LT_CHECK_DLPREOPEN])dnl +m4_require([_LT_DECL_SED])dnl + +dnl Don't require this, or it will be expanded earlier than the code +dnl that sets the variables it relies on: +_LT_ENABLE_INSTALL + +dnl _LTDL_MODE specific code must be called at least once: +_LTDL_MODE_DISPATCH + +# In order that ltdl.c can compile, find out the first AC_CONFIG_HEADERS +# the user used. This is so that ltdl.h can pick up the parent projects +# config.h file, The first file in AC_CONFIG_HEADERS must contain the +# definitions required by ltdl.c. +# FIXME: Remove use of undocumented AC_LIST_HEADERS (2.59 compatibility). +AC_CONFIG_COMMANDS_PRE([dnl +m4_pattern_allow([^LT_CONFIG_H$])dnl +m4_ifset([AH_HEADER], + [LT_CONFIG_H=AH_HEADER], + [m4_ifset([AC_LIST_HEADERS], + [LT_CONFIG_H=`echo "AC_LIST_HEADERS" | $SED 's,^[[ ]]*,,;s,[[ :]].*$,,'`], + [])])]) +AC_SUBST([LT_CONFIG_H]) + +AC_CHECK_HEADERS([unistd.h dl.h sys/dl.h dld.h mach-o/dyld.h dirent.h], + [], [], [AC_INCLUDES_DEFAULT]) + +AC_CHECK_FUNCS([closedir opendir readdir], [], [AC_LIBOBJ([lt__dirent])]) +AC_CHECK_FUNCS([strlcat strlcpy], [], [AC_LIBOBJ([lt__strl])]) + +AC_DEFINE_UNQUOTED([LT_LIBEXT],["$libext"],[The archive extension]) + +name=ltdl +LTDLOPEN=`eval "\\$ECHO \"$libname_spec\""` +AC_SUBST([LTDLOPEN]) +])# _LTDL_SETUP + + +# _LT_ENABLE_INSTALL +# ------------------ +m4_define([_LT_ENABLE_INSTALL], +[AC_ARG_ENABLE([ltdl-install], + [AS_HELP_STRING([--enable-ltdl-install], [install libltdl])]) + +case ,${enable_ltdl_install},${enable_ltdl_convenience} in + *yes*) ;; + *) enable_ltdl_convenience=yes ;; +esac + +m4_ifdef([AM_CONDITIONAL], +[AM_CONDITIONAL(INSTALL_LTDL, test x"${enable_ltdl_install-no}" != xno) + AM_CONDITIONAL(CONVENIENCE_LTDL, test x"${enable_ltdl_convenience-no}" != xno)]) +])# _LT_ENABLE_INSTALL + + +# LT_SYS_DLOPEN_DEPLIBS +# --------------------- +AC_DEFUN([LT_SYS_DLOPEN_DEPLIBS], +[AC_REQUIRE([AC_CANONICAL_HOST])dnl +AC_CACHE_CHECK([whether deplibs are loaded by dlopen], + [lt_cv_sys_dlopen_deplibs], + [# PORTME does your system automatically load deplibs for dlopen? + # or its logical equivalent (e.g. shl_load for HP-UX < 11) + # For now, we just catch OSes we know something about -- in the + # future, we'll try test this programmatically. + lt_cv_sys_dlopen_deplibs=unknown + case $host_os in + aix3*|aix4.1.*|aix4.2.*) + # Unknown whether this is true for these versions of AIX, but + # we want this `case' here to explicitly catch those versions. + lt_cv_sys_dlopen_deplibs=unknown + ;; + aix[[4-9]]*) + lt_cv_sys_dlopen_deplibs=yes + ;; + amigaos*) + case $host_cpu in + powerpc) + lt_cv_sys_dlopen_deplibs=no + ;; + esac + ;; + darwin*) + # Assuming the user has installed a libdl from somewhere, this is true + # If you are looking for one http://www.opendarwin.org/projects/dlcompat + lt_cv_sys_dlopen_deplibs=yes + ;; + freebsd* | dragonfly*) + lt_cv_sys_dlopen_deplibs=yes + ;; + gnu* | linux* | k*bsd*-gnu) + # GNU and its variants, using gnu ld.so (Glibc) + lt_cv_sys_dlopen_deplibs=yes + ;; + hpux10*|hpux11*) + lt_cv_sys_dlopen_deplibs=yes + ;; + interix*) + lt_cv_sys_dlopen_deplibs=yes + ;; + irix[[12345]]*|irix6.[[01]]*) + # Catch all versions of IRIX before 6.2, and indicate that we don't + # know how it worked for any of those versions. + lt_cv_sys_dlopen_deplibs=unknown + ;; + irix*) + # The case above catches anything before 6.2, and it's known that + # at 6.2 and later dlopen does load deplibs. + lt_cv_sys_dlopen_deplibs=yes + ;; + netbsd*) + lt_cv_sys_dlopen_deplibs=yes + ;; + openbsd*) + lt_cv_sys_dlopen_deplibs=yes + ;; + osf[[1234]]*) + # dlopen did load deplibs (at least at 4.x), but until the 5.x series, + # it did *not* use an RPATH in a shared library to find objects the + # library depends on, so we explicitly say `no'. + lt_cv_sys_dlopen_deplibs=no + ;; + osf5.0|osf5.0a|osf5.1) + # dlopen *does* load deplibs and with the right loader patch applied + # it even uses RPATH in a shared library to search for shared objects + # that the library depends on, but there's no easy way to know if that + # patch is installed. Since this is the case, all we can really + # say is unknown -- it depends on the patch being installed. If + # it is, this changes to `yes'. Without it, it would be `no'. + lt_cv_sys_dlopen_deplibs=unknown + ;; + osf*) + # the two cases above should catch all versions of osf <= 5.1. Read + # the comments above for what we know about them. + # At > 5.1, deplibs are loaded *and* any RPATH in a shared library + # is used to find them so we can finally say `yes'. + lt_cv_sys_dlopen_deplibs=yes + ;; + qnx*) + lt_cv_sys_dlopen_deplibs=yes + ;; + solaris*) + lt_cv_sys_dlopen_deplibs=yes + ;; + sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) + libltdl_cv_sys_dlopen_deplibs=yes + ;; + esac + ]) +if test "$lt_cv_sys_dlopen_deplibs" != yes; then + AC_DEFINE([LTDL_DLOPEN_DEPLIBS], [1], + [Define if the OS needs help to load dependent libraries for dlopen().]) +fi +])# LT_SYS_DLOPEN_DEPLIBS + +# Old name: +AU_ALIAS([AC_LTDL_SYS_DLOPEN_DEPLIBS], [LT_SYS_DLOPEN_DEPLIBS]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LTDL_SYS_DLOPEN_DEPLIBS], []) + + +# LT_SYS_MODULE_EXT +# ----------------- +AC_DEFUN([LT_SYS_MODULE_EXT], +[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl +AC_CACHE_CHECK([which extension is used for runtime loadable modules], + [libltdl_cv_shlibext], +[ +module=yes +eval libltdl_cv_shlibext=$shrext_cmds + ]) +if test -n "$libltdl_cv_shlibext"; then + m4_pattern_allow([LT_MODULE_EXT])dnl + AC_DEFINE_UNQUOTED([LT_MODULE_EXT], ["$libltdl_cv_shlibext"], + [Define to the extension used for runtime loadable modules, say, ".so".]) +fi +])# LT_SYS_MODULE_EXT + +# Old name: +AU_ALIAS([AC_LTDL_SHLIBEXT], [LT_SYS_MODULE_EXT]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LTDL_SHLIBEXT], []) + + +# LT_SYS_MODULE_PATH +# ------------------ +AC_DEFUN([LT_SYS_MODULE_PATH], +[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl +AC_CACHE_CHECK([which variable specifies run-time module search path], + [lt_cv_module_path_var], [lt_cv_module_path_var="$shlibpath_var"]) +if test -n "$lt_cv_module_path_var"; then + m4_pattern_allow([LT_MODULE_PATH_VAR])dnl + AC_DEFINE_UNQUOTED([LT_MODULE_PATH_VAR], ["$lt_cv_module_path_var"], + [Define to the name of the environment variable that determines the run-time module search path.]) +fi +])# LT_SYS_MODULE_PATH + +# Old name: +AU_ALIAS([AC_LTDL_SHLIBPATH], [LT_SYS_MODULE_PATH]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LTDL_SHLIBPATH], []) + + +# LT_SYS_DLSEARCH_PATH +# -------------------- +AC_DEFUN([LT_SYS_DLSEARCH_PATH], +[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl +AC_CACHE_CHECK([for the default library search path], + [lt_cv_sys_dlsearch_path], + [lt_cv_sys_dlsearch_path="$sys_lib_dlsearch_path_spec"]) +if test -n "$lt_cv_sys_dlsearch_path"; then + sys_dlsearch_path= + for dir in $lt_cv_sys_dlsearch_path; do + if test -z "$sys_dlsearch_path"; then + sys_dlsearch_path="$dir" + else + sys_dlsearch_path="$sys_dlsearch_path$PATH_SEPARATOR$dir" + fi + done + m4_pattern_allow([LT_DLSEARCH_PATH])dnl + AC_DEFINE_UNQUOTED([LT_DLSEARCH_PATH], ["$sys_dlsearch_path"], + [Define to the system default library search path.]) +fi +])# LT_SYS_DLSEARCH_PATH + +# Old name: +AU_ALIAS([AC_LTDL_SYSSEARCHPATH], [LT_SYS_DLSEARCH_PATH]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LTDL_SYSSEARCHPATH], []) + + +# _LT_CHECK_DLPREOPEN +# ------------------- +m4_defun([_LT_CHECK_DLPREOPEN], +[m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl +AC_CACHE_CHECK([whether libtool supports -dlopen/-dlpreopen], + [libltdl_cv_preloaded_symbols], + [if test -n "$lt_cv_sys_global_symbol_pipe"; then + libltdl_cv_preloaded_symbols=yes + else + libltdl_cv_preloaded_symbols=no + fi + ]) +if test x"$libltdl_cv_preloaded_symbols" = xyes; then + AC_DEFINE([HAVE_PRELOADED_SYMBOLS], [1], + [Define if libtool can extract symbol lists from object files.]) +fi +])# _LT_CHECK_DLPREOPEN + + +# LT_LIB_DLLOAD +# ------------- +AC_DEFUN([LT_LIB_DLLOAD], +[m4_pattern_allow([^LT_DLLOADERS$]) +LT_DLLOADERS= +AC_SUBST([LT_DLLOADERS]) + +AC_LANG_PUSH([C]) + +LIBADD_DLOPEN= +AC_SEARCH_LIBS([dlopen], [dl], + [AC_DEFINE([HAVE_LIBDL], [1], + [Define if you have the libdl library or equivalent.]) + if test "$ac_cv_search_dlopen" != "none required" ; then + LIBADD_DLOPEN="-ldl" + fi + libltdl_cv_lib_dl_dlopen="yes" + LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"], + [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#if HAVE_DLFCN_H +# include +#endif + ]], [[dlopen(0, 0);]])], + [AC_DEFINE([HAVE_LIBDL], [1], + [Define if you have the libdl library or equivalent.]) + libltdl_cv_func_dlopen="yes" + LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"], + [AC_CHECK_LIB([svld], [dlopen], + [AC_DEFINE([HAVE_LIBDL], [1], + [Define if you have the libdl library or equivalent.]) + LIBADD_DLOPEN="-lsvld" libltdl_cv_func_dlopen="yes" + LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"])])]) +if test x"$libltdl_cv_func_dlopen" = xyes || test x"$libltdl_cv_lib_dl_dlopen" = xyes +then + lt_save_LIBS="$LIBS" + LIBS="$LIBS $LIBADD_DLOPEN" + AC_CHECK_FUNCS([dlerror]) + LIBS="$lt_save_LIBS" +fi +AC_SUBST([LIBADD_DLOPEN]) + +LIBADD_SHL_LOAD= +AC_CHECK_FUNC([shl_load], + [AC_DEFINE([HAVE_SHL_LOAD], [1], + [Define if you have the shl_load function.]) + LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la"], + [AC_CHECK_LIB([dld], [shl_load], + [AC_DEFINE([HAVE_SHL_LOAD], [1], + [Define if you have the shl_load function.]) + LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la" + LIBADD_SHL_LOAD="-ldld"])]) +AC_SUBST([LIBADD_SHL_LOAD]) + +case $host_os in +darwin[[1567]].*) +# We only want this for pre-Mac OS X 10.4. + AC_CHECK_FUNC([_dyld_func_lookup], + [AC_DEFINE([HAVE_DYLD], [1], + [Define if you have the _dyld_func_lookup function.]) + LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dyld.la"]) + ;; +beos*) + LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}load_add_on.la" + ;; +cygwin* | mingw* | os2* | pw32*) + AC_CHECK_DECLS([cygwin_conv_path], [], [], [[#include ]]) + LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}loadlibrary.la" + ;; +esac + +AC_CHECK_LIB([dld], [dld_link], + [AC_DEFINE([HAVE_DLD], [1], + [Define if you have the GNU dld library.]) + LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dld_link.la"]) +AC_SUBST([LIBADD_DLD_LINK]) + +m4_pattern_allow([^LT_DLPREOPEN$]) +LT_DLPREOPEN= +if test -n "$LT_DLLOADERS" +then + for lt_loader in $LT_DLLOADERS; do + LT_DLPREOPEN="$LT_DLPREOPEN-dlpreopen $lt_loader " + done + AC_DEFINE([HAVE_LIBDLLOADER], [1], + [Define if libdlloader will be built on this platform]) +fi +AC_SUBST([LT_DLPREOPEN]) + +dnl This isn't used anymore, but set it for backwards compatibility +LIBADD_DL="$LIBADD_DLOPEN $LIBADD_SHL_LOAD" +AC_SUBST([LIBADD_DL]) + +AC_LANG_POP +])# LT_LIB_DLLOAD + +# Old name: +AU_ALIAS([AC_LTDL_DLLIB], [LT_LIB_DLLOAD]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LTDL_DLLIB], []) + + +# LT_SYS_SYMBOL_USCORE +# -------------------- +# does the compiler prefix global symbols with an underscore? +AC_DEFUN([LT_SYS_SYMBOL_USCORE], +[m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl +AC_CACHE_CHECK([for _ prefix in compiled symbols], + [lt_cv_sys_symbol_underscore], + [lt_cv_sys_symbol_underscore=no + cat > conftest.$ac_ext <<_LT_EOF +void nm_test_func(){} +int main(){nm_test_func;return 0;} +_LT_EOF + if AC_TRY_EVAL(ac_compile); then + # Now try to grab the symbols. + ac_nlist=conftest.nm + if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist) && test -s "$ac_nlist"; then + # See whether the symbols have a leading underscore. + if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then + lt_cv_sys_symbol_underscore=yes + else + if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then + : + else + echo "configure: cannot find nm_test_func in $ac_nlist" >&AS_MESSAGE_LOG_FD + fi + fi + else + echo "configure: cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD + fi + else + echo "configure: failed program was:" >&AS_MESSAGE_LOG_FD + cat conftest.c >&AS_MESSAGE_LOG_FD + fi + rm -rf conftest* + ]) + sys_symbol_underscore=$lt_cv_sys_symbol_underscore + AC_SUBST([sys_symbol_underscore]) +])# LT_SYS_SYMBOL_USCORE + +# Old name: +AU_ALIAS([AC_LTDL_SYMBOL_USCORE], [LT_SYS_SYMBOL_USCORE]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LTDL_SYMBOL_USCORE], []) + + +# LT_FUNC_DLSYM_USCORE +# -------------------- +AC_DEFUN([LT_FUNC_DLSYM_USCORE], +[AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl +if test x"$lt_cv_sys_symbol_underscore" = xyes; then + if test x"$libltdl_cv_func_dlopen" = xyes || + test x"$libltdl_cv_lib_dl_dlopen" = xyes ; then + AC_CACHE_CHECK([whether we have to add an underscore for dlsym], + [libltdl_cv_need_uscore], + [libltdl_cv_need_uscore=unknown + save_LIBS="$LIBS" + LIBS="$LIBS $LIBADD_DLOPEN" + _LT_TRY_DLOPEN_SELF( + [libltdl_cv_need_uscore=no], [libltdl_cv_need_uscore=yes], + [], [libltdl_cv_need_uscore=cross]) + LIBS="$save_LIBS" + ]) + fi +fi + +if test x"$libltdl_cv_need_uscore" = xyes; then + AC_DEFINE([NEED_USCORE], [1], + [Define if dlsym() requires a leading underscore in symbol names.]) +fi +])# LT_FUNC_DLSYM_USCORE + +# Old name: +AU_ALIAS([AC_LTDL_DLSYM_USCORE], [LT_FUNC_DLSYM_USCORE]) +dnl aclocal-1.4 backwards compatibility: +dnl AC_DEFUN([AC_LTDL_DLSYM_USCORE], []) + # Helper functions for option handling. -*- Autoconf -*- # # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. diff --git a/js/src/ctypes/libffi/configure b/js/src/ctypes/libffi/configure index 37e30551450..be82780669d 100755 --- a/js/src/ctypes/libffi/configure +++ b/js/src/ctypes/libffi/configure @@ -752,6 +752,7 @@ FFI_DEBUG_FALSE FFI_DEBUG_TRUE TARGETDIR TARGET +sys_symbol_underscore HAVE_LONG_DOUBLE ALLOCA PA64_HPUX_FALSE @@ -12361,6 +12362,63 @@ $as_echo "#define HAVE_AS_STRING_PSEUDO_OP 1" >>confdefs.h fi fi +if test x$TARGET = xX86_WIN64; then + { $as_echo "$as_me:$LINENO: checking for _ prefix in compiled symbols" >&5 +$as_echo_n "checking for _ prefix in compiled symbols... " >&6; } +if test "${lt_cv_sys_symbol_underscore+set}" = set; then + $as_echo_n "(cached) " >&6 +else + lt_cv_sys_symbol_underscore=no + cat > conftest.$ac_ext <<_LT_EOF +void nm_test_func(){} +int main(){nm_test_func;return 0;} +_LT_EOF + if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); }; then + # Now try to grab the symbols. + ac_nlist=conftest.nm + if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist\"") >&5 + (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist) 2>&5 + ac_status=$? + $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 + (exit $ac_status); } && test -s "$ac_nlist"; then + # See whether the symbols have a leading underscore. + if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then + lt_cv_sys_symbol_underscore=yes + else + if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then + : + else + echo "configure: cannot find nm_test_func in $ac_nlist" >&5 + fi + fi + else + echo "configure: cannot run $lt_cv_sys_global_symbol_pipe" >&5 + fi + else + echo "configure: failed program was:" >&5 + cat conftest.c >&5 + fi + rm -rf conftest* + +fi +{ $as_echo "$as_me:$LINENO: result: $lt_cv_sys_symbol_underscore" >&5 +$as_echo "$lt_cv_sys_symbol_underscore" >&6; } + sys_symbol_underscore=$lt_cv_sys_symbol_underscore + + + if test "x$sys_symbol_underscore" = xyes; then + +cat >>confdefs.h <<\_ACEOF +#define SYMBOL_UNDERSCORE 1 +_ACEOF + + fi +fi + case "$target" in *-apple-darwin1* | *-*-freebsd* | *-*-openbsd* | *-pc-solaris*) diff --git a/js/src/ctypes/libffi/configure.ac b/js/src/ctypes/libffi/configure.ac index 1db02ce004d..d149b2e8efe 100644 --- a/js/src/ctypes/libffi/configure.ac +++ b/js/src/ctypes/libffi/configure.ac @@ -315,6 +315,13 @@ if test x$TARGET = xX86 || test x$TARGET = xX86_WIN32 || test x$TARGET = xX86_64 fi fi +if test x$TARGET = xX86_WIN64; then + LT_SYS_SYMBOL_USCORE + if test "x$sys_symbol_underscore" = xyes; then + AC_DEFINE(SYMBOL_UNDERSCORE, 1, [Define if symbols are underscored.]) + fi +fi + case "$target" in # Darwin 10 (OSX 10.6) and beyond allocate non-executable pages *-apple-darwin1* | *-*-freebsd* | *-*-openbsd* | *-pc-solaris*) diff --git a/js/src/ctypes/libffi/src/x86/win64.S b/js/src/ctypes/libffi/src/x86/win64.S index 6e9181867de..fcdb270faf5 100644 --- a/js/src/ctypes/libffi/src/x86/win64.S +++ b/js/src/ctypes/libffi/src/x86/win64.S @@ -232,10 +232,18 @@ ret_void$: ffi_call_win64 ENDP _TEXT ENDS END -#else + +#else + +#ifdef SYMBOL_UNDERSCORE +#define SYMBOL_NAME(name) _##name +#else +#define SYMBOL_NAME(name) name +#endif + .text -.extern _ffi_closure_win64_inner +.extern SYMBOL_NAME(ffi_closure_win64_inner) # ffi_closure_win64 will be called with these registers set: # rax points to 'closure' @@ -246,8 +254,8 @@ END # call ffi_closure_win64_inner for the actual work, then return the result. # .balign 16 - .globl _ffi_closure_win64 -_ffi_closure_win64: + .globl SYMBOL_NAME(ffi_closure_win64) +SYMBOL_NAME(ffi_closure_win64): # copy register arguments onto stack test $1,%r11 jne .Lfirst_is_float @@ -287,7 +295,7 @@ _ffi_closure_win64: mov %rax, %rcx # context is first parameter mov %rsp, %rdx # stack is second parameter add $48, %rdx # point to start of arguments - mov $_ffi_closure_win64_inner, %rax + mov $SYMBOL_NAME(ffi_closure_win64_inner), %rax callq *%rax # call the real closure function add $40, %rsp movq %rax, %xmm0 # If the closure returned a float, @@ -296,8 +304,8 @@ _ffi_closure_win64: .ffi_closure_win64_end: .balign 16 - .globl _ffi_call_win64 -_ffi_call_win64: + .globl SYMBOL_NAME(ffi_call_win64) +SYMBOL_NAME(ffi_call_win64): # copy registers onto stack mov %r9,32(%rsp) mov %r8,24(%rsp) diff --git a/js/src/ctypes/patches-libffi/03-bug-712594.patch b/js/src/ctypes/patches-libffi/03-bug-712594.patch new file mode 100644 index 00000000000..1d62ad77449 --- /dev/null +++ b/js/src/ctypes/patches-libffi/03-bug-712594.patch @@ -0,0 +1,1072 @@ +commit 5b9cd52784339a42e417174a55e310e214d435f9 +Author: Anthony Green +Date: Mon Nov 22 15:19:57 2010 -0500 + + win64-underscore patch + +diff --git a/aclocal.m4 b/aclocal.m4 +index 0ef4b09..4079f82 100644 +--- a/aclocal.m4 ++++ b/aclocal.m4 +@@ -7364,6 +7364,811 @@ _LT_EOF + esac + ]) + ++# ltdl.m4 - Configure ltdl for the target system. -*-Autoconf-*- ++# ++# Copyright (C) 1999-2006, 2007, 2008 Free Software Foundation, Inc. ++# Written by Thomas Tanner, 1999 ++# ++# This file is free software; the Free Software Foundation gives ++# unlimited permission to copy and/or distribute it, with or without ++# modifications, as long as this notice is preserved. ++ ++# serial 17 LTDL_INIT ++ ++# LT_CONFIG_LTDL_DIR(DIRECTORY, [LTDL-MODE]) ++# ------------------------------------------ ++# DIRECTORY contains the libltdl sources. It is okay to call this ++# function multiple times, as long as the same DIRECTORY is always given. ++AC_DEFUN([LT_CONFIG_LTDL_DIR], ++[AC_BEFORE([$0], [LTDL_INIT]) ++_$0($*) ++])# LT_CONFIG_LTDL_DIR ++ ++# We break this out into a separate macro, so that we can call it safely ++# internally without being caught accidentally by the sed scan in libtoolize. ++m4_defun([_LT_CONFIG_LTDL_DIR], ++[dnl remove trailing slashes ++m4_pushdef([_ARG_DIR], m4_bpatsubst([$1], [/*$])) ++m4_case(_LTDL_DIR, ++ [], [dnl only set lt_ltdl_dir if _ARG_DIR is not simply `.' ++ m4_if(_ARG_DIR, [.], ++ [], ++ [m4_define([_LTDL_DIR], _ARG_DIR) ++ _LT_SHELL_INIT([lt_ltdl_dir=']_ARG_DIR['])])], ++ [m4_if(_ARG_DIR, _LTDL_DIR, ++ [], ++ [m4_fatal([multiple libltdl directories: `]_LTDL_DIR[', `]_ARG_DIR['])])]) ++m4_popdef([_ARG_DIR]) ++])# _LT_CONFIG_LTDL_DIR ++ ++# Initialise: ++m4_define([_LTDL_DIR], []) ++ ++ ++# _LT_BUILD_PREFIX ++# ---------------- ++# If Autoconf is new enough, expand to `${top_build_prefix}', otherwise ++# to `${top_builddir}/'. ++m4_define([_LT_BUILD_PREFIX], ++[m4_ifdef([AC_AUTOCONF_VERSION], ++ [m4_if(m4_version_compare(m4_defn([AC_AUTOCONF_VERSION]), [2.62]), ++ [-1], [m4_ifdef([_AC_HAVE_TOP_BUILD_PREFIX], ++ [${top_build_prefix}], ++ [${top_builddir}/])], ++ [${top_build_prefix}])], ++ [${top_builddir}/])[]dnl ++]) ++ ++ ++# LTDL_CONVENIENCE ++# ---------------- ++# sets LIBLTDL to the link flags for the libltdl convenience library and ++# LTDLINCL to the include flags for the libltdl header and adds ++# --enable-ltdl-convenience to the configure arguments. Note that ++# AC_CONFIG_SUBDIRS is not called here. LIBLTDL will be prefixed with ++# '${top_build_prefix}' if available, otherwise with '${top_builddir}/', ++# and LTDLINCL will be prefixed with '${top_srcdir}/' (note the single ++# quotes!). If your package is not flat and you're not using automake, ++# define top_build_prefix, top_builddir, and top_srcdir appropriately ++# in your Makefiles. ++AC_DEFUN([LTDL_CONVENIENCE], ++[AC_BEFORE([$0], [LTDL_INIT])dnl ++dnl Although the argument is deprecated and no longer documented, ++dnl LTDL_CONVENIENCE used to take a DIRECTORY orgument, if we have one ++dnl here make sure it is the same as any other declaration of libltdl's ++dnl location! This also ensures lt_ltdl_dir is set when configure.ac is ++dnl not yet using an explicit LT_CONFIG_LTDL_DIR. ++m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl ++_$0() ++])# LTDL_CONVENIENCE ++ ++# AC_LIBLTDL_CONVENIENCE accepted a directory argument in older libtools, ++# now we have LT_CONFIG_LTDL_DIR: ++AU_DEFUN([AC_LIBLTDL_CONVENIENCE], ++[_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])]) ++_LTDL_CONVENIENCE]) ++ ++dnl aclocal-1.4 backwards compatibility: ++dnl AC_DEFUN([AC_LIBLTDL_CONVENIENCE], []) ++ ++ ++# _LTDL_CONVENIENCE ++# ----------------- ++# Code shared by LTDL_CONVENIENCE and LTDL_INIT([convenience]). ++m4_defun([_LTDL_CONVENIENCE], ++[case $enable_ltdl_convenience in ++ no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; ++ "") enable_ltdl_convenience=yes ++ ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; ++esac ++LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdlc.la" ++LTDLDEPS=$LIBLTDL ++LTDLINCL='-I${top_srcdir}'"${lt_ltdl_dir+/$lt_ltdl_dir}" ++ ++AC_SUBST([LIBLTDL]) ++AC_SUBST([LTDLDEPS]) ++AC_SUBST([LTDLINCL]) ++ ++# For backwards non-gettext consistent compatibility... ++INCLTDL="$LTDLINCL" ++AC_SUBST([INCLTDL]) ++])# _LTDL_CONVENIENCE ++ ++ ++# LTDL_INSTALLABLE ++# ---------------- ++# sets LIBLTDL to the link flags for the libltdl installable library ++# and LTDLINCL to the include flags for the libltdl header and adds ++# --enable-ltdl-install to the configure arguments. Note that ++# AC_CONFIG_SUBDIRS is not called from here. If an installed libltdl ++# is not found, LIBLTDL will be prefixed with '${top_build_prefix}' if ++# available, otherwise with '${top_builddir}/', and LTDLINCL will be ++# prefixed with '${top_srcdir}/' (note the single quotes!). If your ++# package is not flat and you're not using automake, define top_build_prefix, ++# top_builddir, and top_srcdir appropriately in your Makefiles. ++# In the future, this macro may have to be called after LT_INIT. ++AC_DEFUN([LTDL_INSTALLABLE], ++[AC_BEFORE([$0], [LTDL_INIT])dnl ++dnl Although the argument is deprecated and no longer documented, ++dnl LTDL_INSTALLABLE used to take a DIRECTORY orgument, if we have one ++dnl here make sure it is the same as any other declaration of libltdl's ++dnl location! This also ensures lt_ltdl_dir is set when configure.ac is ++dnl not yet using an explicit LT_CONFIG_LTDL_DIR. ++m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl ++_$0() ++])# LTDL_INSTALLABLE ++ ++# AC_LIBLTDL_INSTALLABLE accepted a directory argument in older libtools, ++# now we have LT_CONFIG_LTDL_DIR: ++AU_DEFUN([AC_LIBLTDL_INSTALLABLE], ++[_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])]) ++_LTDL_INSTALLABLE]) ++ ++dnl aclocal-1.4 backwards compatibility: ++dnl AC_DEFUN([AC_LIBLTDL_INSTALLABLE], []) ++ ++ ++# _LTDL_INSTALLABLE ++# ----------------- ++# Code shared by LTDL_INSTALLABLE and LTDL_INIT([installable]). ++m4_defun([_LTDL_INSTALLABLE], ++[if test -f $prefix/lib/libltdl.la; then ++ lt_save_LDFLAGS="$LDFLAGS" ++ LDFLAGS="-L$prefix/lib $LDFLAGS" ++ AC_CHECK_LIB([ltdl], [lt_dlinit], [lt_lib_ltdl=yes]) ++ LDFLAGS="$lt_save_LDFLAGS" ++ if test x"${lt_lib_ltdl-no}" = xyes; then ++ if test x"$enable_ltdl_install" != xyes; then ++ # Don't overwrite $prefix/lib/libltdl.la without --enable-ltdl-install ++ AC_MSG_WARN([not overwriting libltdl at $prefix, force with `--enable-ltdl-install']) ++ enable_ltdl_install=no ++ fi ++ elif test x"$enable_ltdl_install" = xno; then ++ AC_MSG_WARN([libltdl not installed, but installation disabled]) ++ fi ++fi ++ ++# If configure.ac declared an installable ltdl, and the user didn't override ++# with --disable-ltdl-install, we will install the shipped libltdl. ++case $enable_ltdl_install in ++ no) ac_configure_args="$ac_configure_args --enable-ltdl-install=no" ++ LIBLTDL="-lltdl" ++ LTDLDEPS= ++ LTDLINCL= ++ ;; ++ *) enable_ltdl_install=yes ++ ac_configure_args="$ac_configure_args --enable-ltdl-install" ++ LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdl.la" ++ LTDLDEPS=$LIBLTDL ++ LTDLINCL='-I${top_srcdir}'"${lt_ltdl_dir+/$lt_ltdl_dir}" ++ ;; ++esac ++ ++AC_SUBST([LIBLTDL]) ++AC_SUBST([LTDLDEPS]) ++AC_SUBST([LTDLINCL]) ++ ++# For backwards non-gettext consistent compatibility... ++INCLTDL="$LTDLINCL" ++AC_SUBST([INCLTDL]) ++])# LTDL_INSTALLABLE ++ ++ ++# _LTDL_MODE_DISPATCH ++# ------------------- ++m4_define([_LTDL_MODE_DISPATCH], ++[dnl If _LTDL_DIR is `.', then we are configuring libltdl itself: ++m4_if(_LTDL_DIR, [], ++ [], ++ dnl if _LTDL_MODE was not set already, the default value is `subproject': ++ [m4_case(m4_default(_LTDL_MODE, [subproject]), ++ [subproject], [AC_CONFIG_SUBDIRS(_LTDL_DIR) ++ _LT_SHELL_INIT([lt_dlopen_dir="$lt_ltdl_dir"])], ++ [nonrecursive], [_LT_SHELL_INIT([lt_dlopen_dir="$lt_ltdl_dir"; lt_libobj_prefix="$lt_ltdl_dir/"])], ++ [recursive], [], ++ [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])])dnl ++dnl Be careful not to expand twice: ++m4_define([$0], []) ++])# _LTDL_MODE_DISPATCH ++ ++ ++# _LT_LIBOBJ(MODULE_NAME) ++# ----------------------- ++# Like AC_LIBOBJ, except that MODULE_NAME goes into _LT_LIBOBJS instead ++# of into LIBOBJS. ++AC_DEFUN([_LT_LIBOBJ], [ ++ m4_pattern_allow([^_LT_LIBOBJS$]) ++ _LT_LIBOBJS="$_LT_LIBOBJS $1.$ac_objext" ++])# _LT_LIBOBJS ++ ++ ++# LTDL_INIT([OPTIONS]) ++# -------------------- ++# Clients of libltdl can use this macro to allow the installer to ++# choose between a shipped copy of the ltdl sources or a preinstalled ++# version of the library. If the shipped ltdl sources are not in a ++# subdirectory named libltdl, the directory name must be given by ++# LT_CONFIG_LTDL_DIR. ++AC_DEFUN([LTDL_INIT], ++[dnl Parse OPTIONS ++_LT_SET_OPTIONS([$0], [$1]) ++ ++dnl We need to keep our own list of libobjs separate from our parent project, ++dnl and the easiest way to do that is redefine the AC_LIBOBJs macro while ++dnl we look for our own LIBOBJs. ++m4_pushdef([AC_LIBOBJ], m4_defn([_LT_LIBOBJ])) ++m4_pushdef([AC_LIBSOURCES]) ++ ++dnl If not otherwise defined, default to the 1.5.x compatible subproject mode: ++m4_if(_LTDL_MODE, [], ++ [m4_define([_LTDL_MODE], m4_default([$2], [subproject])) ++ m4_if([-1], [m4_bregexp(_LTDL_MODE, [\(subproject\|\(non\)?recursive\)])], ++ [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])]) ++ ++AC_ARG_WITH([included_ltdl], ++ [AS_HELP_STRING([--with-included-ltdl], ++ [use the GNU ltdl sources included here])]) ++ ++if test "x$with_included_ltdl" != xyes; then ++ # We are not being forced to use the included libltdl sources, so ++ # decide whether there is a useful installed version we can use. ++ AC_CHECK_HEADER([ltdl.h], ++ [AC_CHECK_DECL([lt_dlinterface_register], ++ [AC_CHECK_LIB([ltdl], [lt_dladvise_preload], ++ [with_included_ltdl=no], ++ [with_included_ltdl=yes])], ++ [with_included_ltdl=yes], ++ [AC_INCLUDES_DEFAULT ++ #include ])], ++ [with_included_ltdl=yes], ++ [AC_INCLUDES_DEFAULT] ++ ) ++fi ++ ++dnl If neither LT_CONFIG_LTDL_DIR, LTDL_CONVENIENCE nor LTDL_INSTALLABLE ++dnl was called yet, then for old times' sake, we assume libltdl is in an ++dnl eponymous directory: ++AC_PROVIDE_IFELSE([LT_CONFIG_LTDL_DIR], [], [_LT_CONFIG_LTDL_DIR([libltdl])]) ++ ++AC_ARG_WITH([ltdl_include], ++ [AS_HELP_STRING([--with-ltdl-include=DIR], ++ [use the ltdl headers installed in DIR])]) ++ ++if test -n "$with_ltdl_include"; then ++ if test -f "$with_ltdl_include/ltdl.h"; then : ++ else ++ AC_MSG_ERROR([invalid ltdl include directory: `$with_ltdl_include']) ++ fi ++else ++ with_ltdl_include=no ++fi ++ ++AC_ARG_WITH([ltdl_lib], ++ [AS_HELP_STRING([--with-ltdl-lib=DIR], ++ [use the libltdl.la installed in DIR])]) ++ ++if test -n "$with_ltdl_lib"; then ++ if test -f "$with_ltdl_lib/libltdl.la"; then : ++ else ++ AC_MSG_ERROR([invalid ltdl library directory: `$with_ltdl_lib']) ++ fi ++else ++ with_ltdl_lib=no ++fi ++ ++case ,$with_included_ltdl,$with_ltdl_include,$with_ltdl_lib, in ++ ,yes,no,no,) ++ m4_case(m4_default(_LTDL_TYPE, [convenience]), ++ [convenience], [_LTDL_CONVENIENCE], ++ [installable], [_LTDL_INSTALLABLE], ++ [m4_fatal([unknown libltdl build type: ]_LTDL_TYPE)]) ++ ;; ++ ,no,no,no,) ++ # If the included ltdl is not to be used, then use the ++ # preinstalled libltdl we found. ++ AC_DEFINE([HAVE_LTDL], [1], ++ [Define this if a modern libltdl is already installed]) ++ LIBLTDL=-lltdl ++ LTDLDEPS= ++ LTDLINCL= ++ ;; ++ ,no*,no,*) ++ AC_MSG_ERROR([`--with-ltdl-include' and `--with-ltdl-lib' options must be used together]) ++ ;; ++ *) with_included_ltdl=no ++ LIBLTDL="-L$with_ltdl_lib -lltdl" ++ LTDLDEPS= ++ LTDLINCL="-I$with_ltdl_include" ++ ;; ++esac ++INCLTDL="$LTDLINCL" ++ ++# Report our decision... ++AC_MSG_CHECKING([where to find libltdl headers]) ++AC_MSG_RESULT([$LTDLINCL]) ++AC_MSG_CHECKING([where to find libltdl library]) ++AC_MSG_RESULT([$LIBLTDL]) ++ ++_LTDL_SETUP ++ ++dnl restore autoconf definition. ++m4_popdef([AC_LIBOBJ]) ++m4_popdef([AC_LIBSOURCES]) ++ ++AC_CONFIG_COMMANDS_PRE([ ++ _ltdl_libobjs= ++ _ltdl_ltlibobjs= ++ if test -n "$_LT_LIBOBJS"; then ++ # Remove the extension. ++ _lt_sed_drop_objext='s/\.o$//;s/\.obj$//' ++ for i in `for i in $_LT_LIBOBJS; do echo "$i"; done | sed "$_lt_sed_drop_objext" | sort -u`; do ++ _ltdl_libobjs="$_ltdl_libobjs $lt_libobj_prefix$i.$ac_objext" ++ _ltdl_ltlibobjs="$_ltdl_ltlibobjs $lt_libobj_prefix$i.lo" ++ done ++ fi ++ AC_SUBST([ltdl_LIBOBJS], [$_ltdl_libobjs]) ++ AC_SUBST([ltdl_LTLIBOBJS], [$_ltdl_ltlibobjs]) ++]) ++ ++# Only expand once: ++m4_define([LTDL_INIT]) ++])# LTDL_INIT ++ ++# Old names: ++AU_DEFUN([AC_LIB_LTDL], [LTDL_INIT($@)]) ++AU_DEFUN([AC_WITH_LTDL], [LTDL_INIT($@)]) ++AU_DEFUN([LT_WITH_LTDL], [LTDL_INIT($@)]) ++dnl aclocal-1.4 backwards compatibility: ++dnl AC_DEFUN([AC_LIB_LTDL], []) ++dnl AC_DEFUN([AC_WITH_LTDL], []) ++dnl AC_DEFUN([LT_WITH_LTDL], []) ++ ++ ++# _LTDL_SETUP ++# ----------- ++# Perform all the checks necessary for compilation of the ltdl objects ++# -- including compiler checks and header checks. This is a public ++# interface mainly for the benefit of libltdl's own configure.ac, most ++# other users should call LTDL_INIT instead. ++AC_DEFUN([_LTDL_SETUP], ++[AC_REQUIRE([AC_PROG_CC])dnl ++AC_REQUIRE([LT_SYS_MODULE_EXT])dnl ++AC_REQUIRE([LT_SYS_MODULE_PATH])dnl ++AC_REQUIRE([LT_SYS_DLSEARCH_PATH])dnl ++AC_REQUIRE([LT_LIB_DLLOAD])dnl ++AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl ++AC_REQUIRE([LT_FUNC_DLSYM_USCORE])dnl ++AC_REQUIRE([LT_SYS_DLOPEN_DEPLIBS])dnl ++AC_REQUIRE([gl_FUNC_ARGZ])dnl ++ ++m4_require([_LT_CHECK_OBJDIR])dnl ++m4_require([_LT_HEADER_DLFCN])dnl ++m4_require([_LT_CHECK_DLPREOPEN])dnl ++m4_require([_LT_DECL_SED])dnl ++ ++dnl Don't require this, or it will be expanded earlier than the code ++dnl that sets the variables it relies on: ++_LT_ENABLE_INSTALL ++ ++dnl _LTDL_MODE specific code must be called at least once: ++_LTDL_MODE_DISPATCH ++ ++# In order that ltdl.c can compile, find out the first AC_CONFIG_HEADERS ++# the user used. This is so that ltdl.h can pick up the parent projects ++# config.h file, The first file in AC_CONFIG_HEADERS must contain the ++# definitions required by ltdl.c. ++# FIXME: Remove use of undocumented AC_LIST_HEADERS (2.59 compatibility). ++AC_CONFIG_COMMANDS_PRE([dnl ++m4_pattern_allow([^LT_CONFIG_H$])dnl ++m4_ifset([AH_HEADER], ++ [LT_CONFIG_H=AH_HEADER], ++ [m4_ifset([AC_LIST_HEADERS], ++ [LT_CONFIG_H=`echo "AC_LIST_HEADERS" | $SED 's,^[[ ]]*,,;s,[[ :]].*$,,'`], ++ [])])]) ++AC_SUBST([LT_CONFIG_H]) ++ ++AC_CHECK_HEADERS([unistd.h dl.h sys/dl.h dld.h mach-o/dyld.h dirent.h], ++ [], [], [AC_INCLUDES_DEFAULT]) ++ ++AC_CHECK_FUNCS([closedir opendir readdir], [], [AC_LIBOBJ([lt__dirent])]) ++AC_CHECK_FUNCS([strlcat strlcpy], [], [AC_LIBOBJ([lt__strl])]) ++ ++AC_DEFINE_UNQUOTED([LT_LIBEXT],["$libext"],[The archive extension]) ++ ++name=ltdl ++LTDLOPEN=`eval "\\$ECHO \"$libname_spec\""` ++AC_SUBST([LTDLOPEN]) ++])# _LTDL_SETUP ++ ++ ++# _LT_ENABLE_INSTALL ++# ------------------ ++m4_define([_LT_ENABLE_INSTALL], ++[AC_ARG_ENABLE([ltdl-install], ++ [AS_HELP_STRING([--enable-ltdl-install], [install libltdl])]) ++ ++case ,${enable_ltdl_install},${enable_ltdl_convenience} in ++ *yes*) ;; ++ *) enable_ltdl_convenience=yes ;; ++esac ++ ++m4_ifdef([AM_CONDITIONAL], ++[AM_CONDITIONAL(INSTALL_LTDL, test x"${enable_ltdl_install-no}" != xno) ++ AM_CONDITIONAL(CONVENIENCE_LTDL, test x"${enable_ltdl_convenience-no}" != xno)]) ++])# _LT_ENABLE_INSTALL ++ ++ ++# LT_SYS_DLOPEN_DEPLIBS ++# --------------------- ++AC_DEFUN([LT_SYS_DLOPEN_DEPLIBS], ++[AC_REQUIRE([AC_CANONICAL_HOST])dnl ++AC_CACHE_CHECK([whether deplibs are loaded by dlopen], ++ [lt_cv_sys_dlopen_deplibs], ++ [# PORTME does your system automatically load deplibs for dlopen? ++ # or its logical equivalent (e.g. shl_load for HP-UX < 11) ++ # For now, we just catch OSes we know something about -- in the ++ # future, we'll try test this programmatically. ++ lt_cv_sys_dlopen_deplibs=unknown ++ case $host_os in ++ aix3*|aix4.1.*|aix4.2.*) ++ # Unknown whether this is true for these versions of AIX, but ++ # we want this `case' here to explicitly catch those versions. ++ lt_cv_sys_dlopen_deplibs=unknown ++ ;; ++ aix[[4-9]]*) ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ amigaos*) ++ case $host_cpu in ++ powerpc) ++ lt_cv_sys_dlopen_deplibs=no ++ ;; ++ esac ++ ;; ++ darwin*) ++ # Assuming the user has installed a libdl from somewhere, this is true ++ # If you are looking for one http://www.opendarwin.org/projects/dlcompat ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ freebsd* | dragonfly*) ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ gnu* | linux* | k*bsd*-gnu) ++ # GNU and its variants, using gnu ld.so (Glibc) ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ hpux10*|hpux11*) ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ interix*) ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ irix[[12345]]*|irix6.[[01]]*) ++ # Catch all versions of IRIX before 6.2, and indicate that we don't ++ # know how it worked for any of those versions. ++ lt_cv_sys_dlopen_deplibs=unknown ++ ;; ++ irix*) ++ # The case above catches anything before 6.2, and it's known that ++ # at 6.2 and later dlopen does load deplibs. ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ netbsd*) ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ openbsd*) ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ osf[[1234]]*) ++ # dlopen did load deplibs (at least at 4.x), but until the 5.x series, ++ # it did *not* use an RPATH in a shared library to find objects the ++ # library depends on, so we explicitly say `no'. ++ lt_cv_sys_dlopen_deplibs=no ++ ;; ++ osf5.0|osf5.0a|osf5.1) ++ # dlopen *does* load deplibs and with the right loader patch applied ++ # it even uses RPATH in a shared library to search for shared objects ++ # that the library depends on, but there's no easy way to know if that ++ # patch is installed. Since this is the case, all we can really ++ # say is unknown -- it depends on the patch being installed. If ++ # it is, this changes to `yes'. Without it, it would be `no'. ++ lt_cv_sys_dlopen_deplibs=unknown ++ ;; ++ osf*) ++ # the two cases above should catch all versions of osf <= 5.1. Read ++ # the comments above for what we know about them. ++ # At > 5.1, deplibs are loaded *and* any RPATH in a shared library ++ # is used to find them so we can finally say `yes'. ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ qnx*) ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ solaris*) ++ lt_cv_sys_dlopen_deplibs=yes ++ ;; ++ sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) ++ libltdl_cv_sys_dlopen_deplibs=yes ++ ;; ++ esac ++ ]) ++if test "$lt_cv_sys_dlopen_deplibs" != yes; then ++ AC_DEFINE([LTDL_DLOPEN_DEPLIBS], [1], ++ [Define if the OS needs help to load dependent libraries for dlopen().]) ++fi ++])# LT_SYS_DLOPEN_DEPLIBS ++ ++# Old name: ++AU_ALIAS([AC_LTDL_SYS_DLOPEN_DEPLIBS], [LT_SYS_DLOPEN_DEPLIBS]) ++dnl aclocal-1.4 backwards compatibility: ++dnl AC_DEFUN([AC_LTDL_SYS_DLOPEN_DEPLIBS], []) ++ ++ ++# LT_SYS_MODULE_EXT ++# ----------------- ++AC_DEFUN([LT_SYS_MODULE_EXT], ++[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl ++AC_CACHE_CHECK([which extension is used for runtime loadable modules], ++ [libltdl_cv_shlibext], ++[ ++module=yes ++eval libltdl_cv_shlibext=$shrext_cmds ++ ]) ++if test -n "$libltdl_cv_shlibext"; then ++ m4_pattern_allow([LT_MODULE_EXT])dnl ++ AC_DEFINE_UNQUOTED([LT_MODULE_EXT], ["$libltdl_cv_shlibext"], ++ [Define to the extension used for runtime loadable modules, say, ".so".]) ++fi ++])# LT_SYS_MODULE_EXT ++ ++# Old name: ++AU_ALIAS([AC_LTDL_SHLIBEXT], [LT_SYS_MODULE_EXT]) ++dnl aclocal-1.4 backwards compatibility: ++dnl AC_DEFUN([AC_LTDL_SHLIBEXT], []) ++ ++ ++# LT_SYS_MODULE_PATH ++# ------------------ ++AC_DEFUN([LT_SYS_MODULE_PATH], ++[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl ++AC_CACHE_CHECK([which variable specifies run-time module search path], ++ [lt_cv_module_path_var], [lt_cv_module_path_var="$shlibpath_var"]) ++if test -n "$lt_cv_module_path_var"; then ++ m4_pattern_allow([LT_MODULE_PATH_VAR])dnl ++ AC_DEFINE_UNQUOTED([LT_MODULE_PATH_VAR], ["$lt_cv_module_path_var"], ++ [Define to the name of the environment variable that determines the run-time module search path.]) ++fi ++])# LT_SYS_MODULE_PATH ++ ++# Old name: ++AU_ALIAS([AC_LTDL_SHLIBPATH], [LT_SYS_MODULE_PATH]) ++dnl aclocal-1.4 backwards compatibility: ++dnl AC_DEFUN([AC_LTDL_SHLIBPATH], []) ++ ++ ++# LT_SYS_DLSEARCH_PATH ++# -------------------- ++AC_DEFUN([LT_SYS_DLSEARCH_PATH], ++[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl ++AC_CACHE_CHECK([for the default library search path], ++ [lt_cv_sys_dlsearch_path], ++ [lt_cv_sys_dlsearch_path="$sys_lib_dlsearch_path_spec"]) ++if test -n "$lt_cv_sys_dlsearch_path"; then ++ sys_dlsearch_path= ++ for dir in $lt_cv_sys_dlsearch_path; do ++ if test -z "$sys_dlsearch_path"; then ++ sys_dlsearch_path="$dir" ++ else ++ sys_dlsearch_path="$sys_dlsearch_path$PATH_SEPARATOR$dir" ++ fi ++ done ++ m4_pattern_allow([LT_DLSEARCH_PATH])dnl ++ AC_DEFINE_UNQUOTED([LT_DLSEARCH_PATH], ["$sys_dlsearch_path"], ++ [Define to the system default library search path.]) ++fi ++])# LT_SYS_DLSEARCH_PATH ++ ++# Old name: ++AU_ALIAS([AC_LTDL_SYSSEARCHPATH], [LT_SYS_DLSEARCH_PATH]) ++dnl aclocal-1.4 backwards compatibility: ++dnl AC_DEFUN([AC_LTDL_SYSSEARCHPATH], []) ++ ++ ++# _LT_CHECK_DLPREOPEN ++# ------------------- ++m4_defun([_LT_CHECK_DLPREOPEN], ++[m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl ++AC_CACHE_CHECK([whether libtool supports -dlopen/-dlpreopen], ++ [libltdl_cv_preloaded_symbols], ++ [if test -n "$lt_cv_sys_global_symbol_pipe"; then ++ libltdl_cv_preloaded_symbols=yes ++ else ++ libltdl_cv_preloaded_symbols=no ++ fi ++ ]) ++if test x"$libltdl_cv_preloaded_symbols" = xyes; then ++ AC_DEFINE([HAVE_PRELOADED_SYMBOLS], [1], ++ [Define if libtool can extract symbol lists from object files.]) ++fi ++])# _LT_CHECK_DLPREOPEN ++ ++ ++# LT_LIB_DLLOAD ++# ------------- ++AC_DEFUN([LT_LIB_DLLOAD], ++[m4_pattern_allow([^LT_DLLOADERS$]) ++LT_DLLOADERS= ++AC_SUBST([LT_DLLOADERS]) ++ ++AC_LANG_PUSH([C]) ++ ++LIBADD_DLOPEN= ++AC_SEARCH_LIBS([dlopen], [dl], ++ [AC_DEFINE([HAVE_LIBDL], [1], ++ [Define if you have the libdl library or equivalent.]) ++ if test "$ac_cv_search_dlopen" != "none required" ; then ++ LIBADD_DLOPEN="-ldl" ++ fi ++ libltdl_cv_lib_dl_dlopen="yes" ++ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"], ++ [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#if HAVE_DLFCN_H ++# include ++#endif ++ ]], [[dlopen(0, 0);]])], ++ [AC_DEFINE([HAVE_LIBDL], [1], ++ [Define if you have the libdl library or equivalent.]) ++ libltdl_cv_func_dlopen="yes" ++ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"], ++ [AC_CHECK_LIB([svld], [dlopen], ++ [AC_DEFINE([HAVE_LIBDL], [1], ++ [Define if you have the libdl library or equivalent.]) ++ LIBADD_DLOPEN="-lsvld" libltdl_cv_func_dlopen="yes" ++ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"])])]) ++if test x"$libltdl_cv_func_dlopen" = xyes || test x"$libltdl_cv_lib_dl_dlopen" = xyes ++then ++ lt_save_LIBS="$LIBS" ++ LIBS="$LIBS $LIBADD_DLOPEN" ++ AC_CHECK_FUNCS([dlerror]) ++ LIBS="$lt_save_LIBS" ++fi ++AC_SUBST([LIBADD_DLOPEN]) ++ ++LIBADD_SHL_LOAD= ++AC_CHECK_FUNC([shl_load], ++ [AC_DEFINE([HAVE_SHL_LOAD], [1], ++ [Define if you have the shl_load function.]) ++ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la"], ++ [AC_CHECK_LIB([dld], [shl_load], ++ [AC_DEFINE([HAVE_SHL_LOAD], [1], ++ [Define if you have the shl_load function.]) ++ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la" ++ LIBADD_SHL_LOAD="-ldld"])]) ++AC_SUBST([LIBADD_SHL_LOAD]) ++ ++case $host_os in ++darwin[[1567]].*) ++# We only want this for pre-Mac OS X 10.4. ++ AC_CHECK_FUNC([_dyld_func_lookup], ++ [AC_DEFINE([HAVE_DYLD], [1], ++ [Define if you have the _dyld_func_lookup function.]) ++ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dyld.la"]) ++ ;; ++beos*) ++ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}load_add_on.la" ++ ;; ++cygwin* | mingw* | os2* | pw32*) ++ AC_CHECK_DECLS([cygwin_conv_path], [], [], [[#include ]]) ++ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}loadlibrary.la" ++ ;; ++esac ++ ++AC_CHECK_LIB([dld], [dld_link], ++ [AC_DEFINE([HAVE_DLD], [1], ++ [Define if you have the GNU dld library.]) ++ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dld_link.la"]) ++AC_SUBST([LIBADD_DLD_LINK]) ++ ++m4_pattern_allow([^LT_DLPREOPEN$]) ++LT_DLPREOPEN= ++if test -n "$LT_DLLOADERS" ++then ++ for lt_loader in $LT_DLLOADERS; do ++ LT_DLPREOPEN="$LT_DLPREOPEN-dlpreopen $lt_loader " ++ done ++ AC_DEFINE([HAVE_LIBDLLOADER], [1], ++ [Define if libdlloader will be built on this platform]) ++fi ++AC_SUBST([LT_DLPREOPEN]) ++ ++dnl This isn't used anymore, but set it for backwards compatibility ++LIBADD_DL="$LIBADD_DLOPEN $LIBADD_SHL_LOAD" ++AC_SUBST([LIBADD_DL]) ++ ++AC_LANG_POP ++])# LT_LIB_DLLOAD ++ ++# Old name: ++AU_ALIAS([AC_LTDL_DLLIB], [LT_LIB_DLLOAD]) ++dnl aclocal-1.4 backwards compatibility: ++dnl AC_DEFUN([AC_LTDL_DLLIB], []) ++ ++ ++# LT_SYS_SYMBOL_USCORE ++# -------------------- ++# does the compiler prefix global symbols with an underscore? ++AC_DEFUN([LT_SYS_SYMBOL_USCORE], ++[m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl ++AC_CACHE_CHECK([for _ prefix in compiled symbols], ++ [lt_cv_sys_symbol_underscore], ++ [lt_cv_sys_symbol_underscore=no ++ cat > conftest.$ac_ext <<_LT_EOF ++void nm_test_func(){} ++int main(){nm_test_func;return 0;} ++_LT_EOF ++ if AC_TRY_EVAL(ac_compile); then ++ # Now try to grab the symbols. ++ ac_nlist=conftest.nm ++ if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist) && test -s "$ac_nlist"; then ++ # See whether the symbols have a leading underscore. ++ if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then ++ lt_cv_sys_symbol_underscore=yes ++ else ++ if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then ++ : ++ else ++ echo "configure: cannot find nm_test_func in $ac_nlist" >&AS_MESSAGE_LOG_FD ++ fi ++ fi ++ else ++ echo "configure: cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD ++ fi ++ else ++ echo "configure: failed program was:" >&AS_MESSAGE_LOG_FD ++ cat conftest.c >&AS_MESSAGE_LOG_FD ++ fi ++ rm -rf conftest* ++ ]) ++ sys_symbol_underscore=$lt_cv_sys_symbol_underscore ++ AC_SUBST([sys_symbol_underscore]) ++])# LT_SYS_SYMBOL_USCORE ++ ++# Old name: ++AU_ALIAS([AC_LTDL_SYMBOL_USCORE], [LT_SYS_SYMBOL_USCORE]) ++dnl aclocal-1.4 backwards compatibility: ++dnl AC_DEFUN([AC_LTDL_SYMBOL_USCORE], []) ++ ++ ++# LT_FUNC_DLSYM_USCORE ++# -------------------- ++AC_DEFUN([LT_FUNC_DLSYM_USCORE], ++[AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl ++if test x"$lt_cv_sys_symbol_underscore" = xyes; then ++ if test x"$libltdl_cv_func_dlopen" = xyes || ++ test x"$libltdl_cv_lib_dl_dlopen" = xyes ; then ++ AC_CACHE_CHECK([whether we have to add an underscore for dlsym], ++ [libltdl_cv_need_uscore], ++ [libltdl_cv_need_uscore=unknown ++ save_LIBS="$LIBS" ++ LIBS="$LIBS $LIBADD_DLOPEN" ++ _LT_TRY_DLOPEN_SELF( ++ [libltdl_cv_need_uscore=no], [libltdl_cv_need_uscore=yes], ++ [], [libltdl_cv_need_uscore=cross]) ++ LIBS="$save_LIBS" ++ ]) ++ fi ++fi ++ ++if test x"$libltdl_cv_need_uscore" = xyes; then ++ AC_DEFINE([NEED_USCORE], [1], ++ [Define if dlsym() requires a leading underscore in symbol names.]) ++fi ++])# LT_FUNC_DLSYM_USCORE ++ ++# Old name: ++AU_ALIAS([AC_LTDL_DLSYM_USCORE], [LT_FUNC_DLSYM_USCORE]) ++dnl aclocal-1.4 backwards compatibility: ++dnl AC_DEFUN([AC_LTDL_DLSYM_USCORE], []) ++ + # Helper functions for option handling. -*- Autoconf -*- + # + # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. +diff --git a/configure b/configure +index da1cb4d..e086c65 100755 +--- a/configure ++++ b/configure +@@ -795,6 +795,7 @@ FFI_DEBUG_FALSE + FFI_DEBUG_TRUE + TARGETDIR + TARGET ++sys_symbol_underscore + HAVE_LONG_DOUBLE + ALLOCA + PA64_HPUX_FALSE +@@ -4782,13 +4783,13 @@ if test "${lt_cv_nm_interface+set}" = set; then + else + lt_cv_nm_interface="BSD nm" + echo "int some_variable = 0;" > conftest.$ac_ext +- (eval echo "\"\$as_me:4785: $ac_compile\"" >&5) ++ (eval echo "\"\$as_me:4786: $ac_compile\"" >&5) + (eval "$ac_compile" 2>conftest.err) + cat conftest.err >&5 +- (eval echo "\"\$as_me:4788: $NM \\\"conftest.$ac_objext\\\"\"" >&5) ++ (eval echo "\"\$as_me:4789: $NM \\\"conftest.$ac_objext\\\"\"" >&5) + (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) + cat conftest.err >&5 +- (eval echo "\"\$as_me:4791: output\"" >&5) ++ (eval echo "\"\$as_me:4792: output\"" >&5) + cat conftest.out >&5 + if $GREP 'External.*some_variable' conftest.out > /dev/null; then + lt_cv_nm_interface="MS dumpbin" +@@ -5994,7 +5995,7 @@ ia64-*-hpux*) + ;; + *-*-irix6*) + # Find out which ABI we are using. +- echo '#line 5997 "configure"' > conftest.$ac_ext ++ echo '#line 5998 "configure"' > conftest.$ac_ext + if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 + (eval $ac_compile) 2>&5 + ac_status=$? +@@ -7847,11 +7848,11 @@ else + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` +- (eval echo "\"\$as_me:7850: $lt_compile\"" >&5) ++ (eval echo "\"\$as_me:7851: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 +- echo "$as_me:7854: \$? = $ac_status" >&5 ++ echo "$as_me:7855: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. +@@ -8186,11 +8187,11 @@ else + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` +- (eval echo "\"\$as_me:8189: $lt_compile\"" >&5) ++ (eval echo "\"\$as_me:8190: $lt_compile\"" >&5) + (eval "$lt_compile" 2>conftest.err) + ac_status=$? + cat conftest.err >&5 +- echo "$as_me:8193: \$? = $ac_status" >&5 ++ echo "$as_me:8194: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s "$ac_outfile"; then + # The compiler can only warn and ignore the option if not recognized + # So say no if there are warnings other than the usual output. +@@ -8291,11 +8292,11 @@ else + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` +- (eval echo "\"\$as_me:8294: $lt_compile\"" >&5) ++ (eval echo "\"\$as_me:8295: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 +- echo "$as_me:8298: \$? = $ac_status" >&5 ++ echo "$as_me:8299: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized +@@ -8346,11 +8347,11 @@ else + -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ + -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ + -e 's:$: $lt_compiler_flag:'` +- (eval echo "\"\$as_me:8349: $lt_compile\"" >&5) ++ (eval echo "\"\$as_me:8350: $lt_compile\"" >&5) + (eval "$lt_compile" 2>out/conftest.err) + ac_status=$? + cat out/conftest.err >&5 +- echo "$as_me:8353: \$? = $ac_status" >&5 ++ echo "$as_me:8354: \$? = $ac_status" >&5 + if (exit $ac_status) && test -s out/conftest2.$ac_objext + then + # The compiler can only warn and ignore the option if not recognized +@@ -11149,7 +11150,7 @@ else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +-#line 11152 "configure" ++#line 11153 "configure" + #include "confdefs.h" + + #if HAVE_DLFCN_H +@@ -11245,7 +11246,7 @@ else + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 + lt_status=$lt_dlunknown + cat > conftest.$ac_ext <<_LT_EOF +-#line 11248 "configure" ++#line 11249 "configure" + #include "confdefs.h" + + #if HAVE_DLFCN_H +@@ -14647,6 +14648,63 @@ _ACEOF + fi + fi + ++if test x$TARGET = xX86_WIN64; then ++ { $as_echo "$as_me:$LINENO: checking for _ prefix in compiled symbols" >&5 ++$as_echo_n "checking for _ prefix in compiled symbols... " >&6; } ++if test "${lt_cv_sys_symbol_underscore+set}" = set; then ++ $as_echo_n "(cached) " >&6 ++else ++ lt_cv_sys_symbol_underscore=no ++ cat > conftest.$ac_ext <<_LT_EOF ++void nm_test_func(){} ++int main(){nm_test_func;return 0;} ++_LT_EOF ++ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 ++ (eval $ac_compile) 2>&5 ++ ac_status=$? ++ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); }; then ++ # Now try to grab the symbols. ++ ac_nlist=conftest.nm ++ if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist\"") >&5 ++ (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist) 2>&5 ++ ac_status=$? ++ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 ++ (exit $ac_status); } && test -s "$ac_nlist"; then ++ # See whether the symbols have a leading underscore. ++ if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then ++ lt_cv_sys_symbol_underscore=yes ++ else ++ if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then ++ : ++ else ++ echo "configure: cannot find nm_test_func in $ac_nlist" >&5 ++ fi ++ fi ++ else ++ echo "configure: cannot run $lt_cv_sys_global_symbol_pipe" >&5 ++ fi ++ else ++ echo "configure: failed program was:" >&5 ++ cat conftest.c >&5 ++ fi ++ rm -rf conftest* ++ ++fi ++{ $as_echo "$as_me:$LINENO: result: $lt_cv_sys_symbol_underscore" >&5 ++$as_echo "$lt_cv_sys_symbol_underscore" >&6; } ++ sys_symbol_underscore=$lt_cv_sys_symbol_underscore ++ ++ ++ if test "x$sys_symbol_underscore" = xyes; then ++ ++cat >>confdefs.h <<\_ACEOF ++#define SYMBOL_UNDERSCORE 1 ++_ACEOF ++ ++ fi ++fi ++ + case "$target" in + *-apple-darwin10* | *-*-freebsd* | *-*-openbsd* | *-pc-solaris*) + +diff --git a/configure.ac b/configure.ac +index a94bd26..c7cead8 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -314,6 +314,13 @@ if test x$TARGET = xX86 || test x$TARGET = xX86_WIN32 || test x$TARGET = xX86_64 + fi + fi + ++if test x$TARGET = xX86_WIN64; then ++ LT_SYS_SYMBOL_USCORE ++ if test "x$sys_symbol_underscore" = xyes; then ++ AC_DEFINE(SYMBOL_UNDERSCORE, 1, [Define if symbols are underscored.]) ++ fi ++fi ++ + case "$target" in + *-apple-darwin10* | *-*-freebsd* | *-*-openbsd* | *-pc-solaris*) + AC_DEFINE(FFI_MMAP_EXEC_WRIT, 1, +diff --git a/src/x86/win64.S b/src/x86/win64.S +index 6e91818..fcdb270 100644 +--- a/src/x86/win64.S ++++ b/src/x86/win64.S +@@ -232,10 +232,18 @@ ret_void$: + ffi_call_win64 ENDP + _TEXT ENDS + END +-#else ++ ++#else ++ ++#ifdef SYMBOL_UNDERSCORE ++#define SYMBOL_NAME(name) _##name ++#else ++#define SYMBOL_NAME(name) name ++#endif ++ + .text + +-.extern _ffi_closure_win64_inner ++.extern SYMBOL_NAME(ffi_closure_win64_inner) + + # ffi_closure_win64 will be called with these registers set: + # rax points to 'closure' +@@ -246,8 +254,8 @@ END + # call ffi_closure_win64_inner for the actual work, then return the result. + # + .balign 16 +- .globl _ffi_closure_win64 +-_ffi_closure_win64: ++ .globl SYMBOL_NAME(ffi_closure_win64) ++SYMBOL_NAME(ffi_closure_win64): + # copy register arguments onto stack + test $1,%r11 + jne .Lfirst_is_float +@@ -287,7 +295,7 @@ _ffi_closure_win64: + mov %rax, %rcx # context is first parameter + mov %rsp, %rdx # stack is second parameter + add $48, %rdx # point to start of arguments +- mov $_ffi_closure_win64_inner, %rax ++ mov $SYMBOL_NAME(ffi_closure_win64_inner), %rax + callq *%rax # call the real closure function + add $40, %rsp + movq %rax, %xmm0 # If the closure returned a float, +@@ -296,8 +304,8 @@ _ffi_closure_win64: + .ffi_closure_win64_end: + + .balign 16 +- .globl _ffi_call_win64 +-_ffi_call_win64: ++ .globl SYMBOL_NAME(ffi_call_win64) ++SYMBOL_NAME(ffi_call_win64): + # copy registers onto stack + mov %r9,32(%rsp) + mov %r8,24(%rsp) From 3e0d643ccf0b7c7c509815fedb355b530dae8a4b Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Tue, 27 Dec 2011 10:51:53 +0100 Subject: [PATCH 17/28] Bug 712584 - Properly use .def files on mingw builds r=khuey --- config/rules.mk | 7 +++++++ js/src/config/rules.mk | 7 +++++++ memory/mozutils/mozutils.def.in | 2 +- 3 files changed, 15 insertions(+), 1 deletion(-) diff --git a/config/rules.mk b/config/rules.mk index 4b8ae1f9f7c..546475a51e4 100644 --- a/config/rules.mk +++ b/config/rules.mk @@ -373,6 +373,13 @@ ifdef MAPFILE OS_LDFLAGS += -MAP:$(MAPFILE) endif +else #!GNU_CC + +ifdef DEFFILE +OS_LDFLAGS += $(call normalizepath,$(DEFFILE)) +EXTRA_DEPS += $(DEFFILE) +endif + endif # !GNU_CC endif # WINNT diff --git a/js/src/config/rules.mk b/js/src/config/rules.mk index 4b8ae1f9f7c..546475a51e4 100644 --- a/js/src/config/rules.mk +++ b/js/src/config/rules.mk @@ -373,6 +373,13 @@ ifdef MAPFILE OS_LDFLAGS += -MAP:$(MAPFILE) endif +else #!GNU_CC + +ifdef DEFFILE +OS_LDFLAGS += $(call normalizepath,$(DEFFILE)) +EXTRA_DEPS += $(DEFFILE) +endif + endif # !GNU_CC endif # WINNT diff --git a/memory/mozutils/mozutils.def.in b/memory/mozutils/mozutils.def.in index 3bbc3bf09ee..63cd6dc952a 100644 --- a/memory/mozutils/mozutils.def.in +++ b/memory/mozutils/mozutils.def.in @@ -1,4 +1,4 @@ -; ***** BEGIN LICENSE BLOCK ***** +; ***** BEGIN LICENSE BLOCK ***** ; Version: MPL 1.1/GPL 2.0/LGPL 2.1 ; ; The contents of this file are subject to the Mozilla Public License Version From f8a9f1bfce25f9fab41ed3813d1418a5241bb7a8 Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Tue, 27 Dec 2011 10:52:10 +0100 Subject: [PATCH 18/28] Bug 712585 - Export vpx_codec_control_ from gkmedias.dll r=khuey --- layout/media/symbols.def.in | 1 + 1 file changed, 1 insertion(+) diff --git a/layout/media/symbols.def.in b/layout/media/symbols.def.in index 6146dcde79a..b09e08a19e8 100644 --- a/layout/media/symbols.def.in +++ b/layout/media/symbols.def.in @@ -20,6 +20,7 @@ nestegg_track_type nestegg_track_video_params nestegg_tstamp_scale #ifndef MOZ_NATIVE_LIBVPX +vpx_codec_control_ vpx_codec_dec_init_ver vpx_codec_decode vpx_codec_destroy From e663351a815bc5a402a0e56e9848afbb18fa74e2 Mon Sep 17 00:00:00 2001 From: Blake Kaplan Date: Wed, 7 Dec 2011 02:29:34 -0800 Subject: [PATCH 19/28] Bug 712341 - Make dump in workers show up in adb logcat. r=bent --HG-- extra : rebase_source : c17d8195b47dd908fa98e371b12647ccfccfc760 --- dom/workers/WorkerPrivate.cpp | 9 ++++++++- dom/workers/WorkerScope.cpp | 6 ++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/dom/workers/WorkerPrivate.cpp b/dom/workers/WorkerPrivate.cpp index cc28173460c..40a0466e55f 100644 --- a/dom/workers/WorkerPrivate.cpp +++ b/dom/workers/WorkerPrivate.cpp @@ -79,6 +79,9 @@ #include "Worker.h" #include "WorkerFeature.h" #include "WorkerScope.h" +#ifdef ANDROID +#include +#endif #include "WorkerInlines.h" @@ -1149,7 +1152,11 @@ public: } if (!logged) { - fputs(NS_ConvertUTF16toUTF8(aMessage).get(), stderr); + NS_ConvertUTF16toUTF8 msg(aMessage); +#ifdef ANDROID + __android_log_print(ANDROID_LOG_INFO, "Gecko", msg.get()); +#endif + fputs(msg.get(), stderr); fflush(stderr); } diff --git a/dom/workers/WorkerScope.cpp b/dom/workers/WorkerScope.cpp index 694929cdc68..5be1fdf1e84 100644 --- a/dom/workers/WorkerScope.cpp +++ b/dom/workers/WorkerScope.cpp @@ -61,6 +61,9 @@ #include "Worker.h" #include "WorkerPrivate.h" #include "XMLHttpRequest.h" +#ifdef ANDROID +#include +#endif #include "WorkerInlines.h" @@ -517,6 +520,9 @@ private: return false; } +#ifdef ANDROID + __android_log_print(ANDROID_LOG_INFO, "Gecko", buffer.ptr()); +#endif fputs(buffer.ptr(), stderr); fflush(stderr); } From 643c2d2e4c54f2ed3a78cafb7991a2720e6f8b1c Mon Sep 17 00:00:00 2001 From: Jacek Caban Date: Tue, 27 Dec 2011 11:11:00 +0100 Subject: [PATCH 20/28] Backout ff350b65a616 due to Android build failure --- js/src/ctypes/libffi/aclocal.m4 | 805 ------------- js/src/ctypes/libffi/configure | 58 - js/src/ctypes/libffi/configure.ac | 7 - js/src/ctypes/libffi/src/x86/win64.S | 22 +- .../ctypes/patches-libffi/03-bug-712594.patch | 1072 ----------------- 5 files changed, 7 insertions(+), 1957 deletions(-) delete mode 100644 js/src/ctypes/patches-libffi/03-bug-712594.patch diff --git a/js/src/ctypes/libffi/aclocal.m4 b/js/src/ctypes/libffi/aclocal.m4 index 41012e3f319..d5eb6a612fd 100644 --- a/js/src/ctypes/libffi/aclocal.m4 +++ b/js/src/ctypes/libffi/aclocal.m4 @@ -7364,811 +7364,6 @@ _LT_EOF esac ]) -# ltdl.m4 - Configure ltdl for the target system. -*-Autoconf-*- -# -# Copyright (C) 1999-2006, 2007, 2008 Free Software Foundation, Inc. -# Written by Thomas Tanner, 1999 -# -# This file is free software; the Free Software Foundation gives -# unlimited permission to copy and/or distribute it, with or without -# modifications, as long as this notice is preserved. - -# serial 17 LTDL_INIT - -# LT_CONFIG_LTDL_DIR(DIRECTORY, [LTDL-MODE]) -# ------------------------------------------ -# DIRECTORY contains the libltdl sources. It is okay to call this -# function multiple times, as long as the same DIRECTORY is always given. -AC_DEFUN([LT_CONFIG_LTDL_DIR], -[AC_BEFORE([$0], [LTDL_INIT]) -_$0($*) -])# LT_CONFIG_LTDL_DIR - -# We break this out into a separate macro, so that we can call it safely -# internally without being caught accidentally by the sed scan in libtoolize. -m4_defun([_LT_CONFIG_LTDL_DIR], -[dnl remove trailing slashes -m4_pushdef([_ARG_DIR], m4_bpatsubst([$1], [/*$])) -m4_case(_LTDL_DIR, - [], [dnl only set lt_ltdl_dir if _ARG_DIR is not simply `.' - m4_if(_ARG_DIR, [.], - [], - [m4_define([_LTDL_DIR], _ARG_DIR) - _LT_SHELL_INIT([lt_ltdl_dir=']_ARG_DIR['])])], - [m4_if(_ARG_DIR, _LTDL_DIR, - [], - [m4_fatal([multiple libltdl directories: `]_LTDL_DIR[', `]_ARG_DIR['])])]) -m4_popdef([_ARG_DIR]) -])# _LT_CONFIG_LTDL_DIR - -# Initialise: -m4_define([_LTDL_DIR], []) - - -# _LT_BUILD_PREFIX -# ---------------- -# If Autoconf is new enough, expand to `${top_build_prefix}', otherwise -# to `${top_builddir}/'. -m4_define([_LT_BUILD_PREFIX], -[m4_ifdef([AC_AUTOCONF_VERSION], - [m4_if(m4_version_compare(m4_defn([AC_AUTOCONF_VERSION]), [2.62]), - [-1], [m4_ifdef([_AC_HAVE_TOP_BUILD_PREFIX], - [${top_build_prefix}], - [${top_builddir}/])], - [${top_build_prefix}])], - [${top_builddir}/])[]dnl -]) - - -# LTDL_CONVENIENCE -# ---------------- -# sets LIBLTDL to the link flags for the libltdl convenience library and -# LTDLINCL to the include flags for the libltdl header and adds -# --enable-ltdl-convenience to the configure arguments. Note that -# AC_CONFIG_SUBDIRS is not called here. LIBLTDL will be prefixed with -# '${top_build_prefix}' if available, otherwise with '${top_builddir}/', -# and LTDLINCL will be prefixed with '${top_srcdir}/' (note the single -# quotes!). If your package is not flat and you're not using automake, -# define top_build_prefix, top_builddir, and top_srcdir appropriately -# in your Makefiles. -AC_DEFUN([LTDL_CONVENIENCE], -[AC_BEFORE([$0], [LTDL_INIT])dnl -dnl Although the argument is deprecated and no longer documented, -dnl LTDL_CONVENIENCE used to take a DIRECTORY orgument, if we have one -dnl here make sure it is the same as any other declaration of libltdl's -dnl location! This also ensures lt_ltdl_dir is set when configure.ac is -dnl not yet using an explicit LT_CONFIG_LTDL_DIR. -m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl -_$0() -])# LTDL_CONVENIENCE - -# AC_LIBLTDL_CONVENIENCE accepted a directory argument in older libtools, -# now we have LT_CONFIG_LTDL_DIR: -AU_DEFUN([AC_LIBLTDL_CONVENIENCE], -[_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])]) -_LTDL_CONVENIENCE]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBLTDL_CONVENIENCE], []) - - -# _LTDL_CONVENIENCE -# ----------------- -# Code shared by LTDL_CONVENIENCE and LTDL_INIT([convenience]). -m4_defun([_LTDL_CONVENIENCE], -[case $enable_ltdl_convenience in - no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; - "") enable_ltdl_convenience=yes - ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; -esac -LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdlc.la" -LTDLDEPS=$LIBLTDL -LTDLINCL='-I${top_srcdir}'"${lt_ltdl_dir+/$lt_ltdl_dir}" - -AC_SUBST([LIBLTDL]) -AC_SUBST([LTDLDEPS]) -AC_SUBST([LTDLINCL]) - -# For backwards non-gettext consistent compatibility... -INCLTDL="$LTDLINCL" -AC_SUBST([INCLTDL]) -])# _LTDL_CONVENIENCE - - -# LTDL_INSTALLABLE -# ---------------- -# sets LIBLTDL to the link flags for the libltdl installable library -# and LTDLINCL to the include flags for the libltdl header and adds -# --enable-ltdl-install to the configure arguments. Note that -# AC_CONFIG_SUBDIRS is not called from here. If an installed libltdl -# is not found, LIBLTDL will be prefixed with '${top_build_prefix}' if -# available, otherwise with '${top_builddir}/', and LTDLINCL will be -# prefixed with '${top_srcdir}/' (note the single quotes!). If your -# package is not flat and you're not using automake, define top_build_prefix, -# top_builddir, and top_srcdir appropriately in your Makefiles. -# In the future, this macro may have to be called after LT_INIT. -AC_DEFUN([LTDL_INSTALLABLE], -[AC_BEFORE([$0], [LTDL_INIT])dnl -dnl Although the argument is deprecated and no longer documented, -dnl LTDL_INSTALLABLE used to take a DIRECTORY orgument, if we have one -dnl here make sure it is the same as any other declaration of libltdl's -dnl location! This also ensures lt_ltdl_dir is set when configure.ac is -dnl not yet using an explicit LT_CONFIG_LTDL_DIR. -m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl -_$0() -])# LTDL_INSTALLABLE - -# AC_LIBLTDL_INSTALLABLE accepted a directory argument in older libtools, -# now we have LT_CONFIG_LTDL_DIR: -AU_DEFUN([AC_LIBLTDL_INSTALLABLE], -[_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])]) -_LTDL_INSTALLABLE]) - -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIBLTDL_INSTALLABLE], []) - - -# _LTDL_INSTALLABLE -# ----------------- -# Code shared by LTDL_INSTALLABLE and LTDL_INIT([installable]). -m4_defun([_LTDL_INSTALLABLE], -[if test -f $prefix/lib/libltdl.la; then - lt_save_LDFLAGS="$LDFLAGS" - LDFLAGS="-L$prefix/lib $LDFLAGS" - AC_CHECK_LIB([ltdl], [lt_dlinit], [lt_lib_ltdl=yes]) - LDFLAGS="$lt_save_LDFLAGS" - if test x"${lt_lib_ltdl-no}" = xyes; then - if test x"$enable_ltdl_install" != xyes; then - # Don't overwrite $prefix/lib/libltdl.la without --enable-ltdl-install - AC_MSG_WARN([not overwriting libltdl at $prefix, force with `--enable-ltdl-install']) - enable_ltdl_install=no - fi - elif test x"$enable_ltdl_install" = xno; then - AC_MSG_WARN([libltdl not installed, but installation disabled]) - fi -fi - -# If configure.ac declared an installable ltdl, and the user didn't override -# with --disable-ltdl-install, we will install the shipped libltdl. -case $enable_ltdl_install in - no) ac_configure_args="$ac_configure_args --enable-ltdl-install=no" - LIBLTDL="-lltdl" - LTDLDEPS= - LTDLINCL= - ;; - *) enable_ltdl_install=yes - ac_configure_args="$ac_configure_args --enable-ltdl-install" - LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdl.la" - LTDLDEPS=$LIBLTDL - LTDLINCL='-I${top_srcdir}'"${lt_ltdl_dir+/$lt_ltdl_dir}" - ;; -esac - -AC_SUBST([LIBLTDL]) -AC_SUBST([LTDLDEPS]) -AC_SUBST([LTDLINCL]) - -# For backwards non-gettext consistent compatibility... -INCLTDL="$LTDLINCL" -AC_SUBST([INCLTDL]) -])# LTDL_INSTALLABLE - - -# _LTDL_MODE_DISPATCH -# ------------------- -m4_define([_LTDL_MODE_DISPATCH], -[dnl If _LTDL_DIR is `.', then we are configuring libltdl itself: -m4_if(_LTDL_DIR, [], - [], - dnl if _LTDL_MODE was not set already, the default value is `subproject': - [m4_case(m4_default(_LTDL_MODE, [subproject]), - [subproject], [AC_CONFIG_SUBDIRS(_LTDL_DIR) - _LT_SHELL_INIT([lt_dlopen_dir="$lt_ltdl_dir"])], - [nonrecursive], [_LT_SHELL_INIT([lt_dlopen_dir="$lt_ltdl_dir"; lt_libobj_prefix="$lt_ltdl_dir/"])], - [recursive], [], - [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])])dnl -dnl Be careful not to expand twice: -m4_define([$0], []) -])# _LTDL_MODE_DISPATCH - - -# _LT_LIBOBJ(MODULE_NAME) -# ----------------------- -# Like AC_LIBOBJ, except that MODULE_NAME goes into _LT_LIBOBJS instead -# of into LIBOBJS. -AC_DEFUN([_LT_LIBOBJ], [ - m4_pattern_allow([^_LT_LIBOBJS$]) - _LT_LIBOBJS="$_LT_LIBOBJS $1.$ac_objext" -])# _LT_LIBOBJS - - -# LTDL_INIT([OPTIONS]) -# -------------------- -# Clients of libltdl can use this macro to allow the installer to -# choose between a shipped copy of the ltdl sources or a preinstalled -# version of the library. If the shipped ltdl sources are not in a -# subdirectory named libltdl, the directory name must be given by -# LT_CONFIG_LTDL_DIR. -AC_DEFUN([LTDL_INIT], -[dnl Parse OPTIONS -_LT_SET_OPTIONS([$0], [$1]) - -dnl We need to keep our own list of libobjs separate from our parent project, -dnl and the easiest way to do that is redefine the AC_LIBOBJs macro while -dnl we look for our own LIBOBJs. -m4_pushdef([AC_LIBOBJ], m4_defn([_LT_LIBOBJ])) -m4_pushdef([AC_LIBSOURCES]) - -dnl If not otherwise defined, default to the 1.5.x compatible subproject mode: -m4_if(_LTDL_MODE, [], - [m4_define([_LTDL_MODE], m4_default([$2], [subproject])) - m4_if([-1], [m4_bregexp(_LTDL_MODE, [\(subproject\|\(non\)?recursive\)])], - [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])]) - -AC_ARG_WITH([included_ltdl], - [AS_HELP_STRING([--with-included-ltdl], - [use the GNU ltdl sources included here])]) - -if test "x$with_included_ltdl" != xyes; then - # We are not being forced to use the included libltdl sources, so - # decide whether there is a useful installed version we can use. - AC_CHECK_HEADER([ltdl.h], - [AC_CHECK_DECL([lt_dlinterface_register], - [AC_CHECK_LIB([ltdl], [lt_dladvise_preload], - [with_included_ltdl=no], - [with_included_ltdl=yes])], - [with_included_ltdl=yes], - [AC_INCLUDES_DEFAULT - #include ])], - [with_included_ltdl=yes], - [AC_INCLUDES_DEFAULT] - ) -fi - -dnl If neither LT_CONFIG_LTDL_DIR, LTDL_CONVENIENCE nor LTDL_INSTALLABLE -dnl was called yet, then for old times' sake, we assume libltdl is in an -dnl eponymous directory: -AC_PROVIDE_IFELSE([LT_CONFIG_LTDL_DIR], [], [_LT_CONFIG_LTDL_DIR([libltdl])]) - -AC_ARG_WITH([ltdl_include], - [AS_HELP_STRING([--with-ltdl-include=DIR], - [use the ltdl headers installed in DIR])]) - -if test -n "$with_ltdl_include"; then - if test -f "$with_ltdl_include/ltdl.h"; then : - else - AC_MSG_ERROR([invalid ltdl include directory: `$with_ltdl_include']) - fi -else - with_ltdl_include=no -fi - -AC_ARG_WITH([ltdl_lib], - [AS_HELP_STRING([--with-ltdl-lib=DIR], - [use the libltdl.la installed in DIR])]) - -if test -n "$with_ltdl_lib"; then - if test -f "$with_ltdl_lib/libltdl.la"; then : - else - AC_MSG_ERROR([invalid ltdl library directory: `$with_ltdl_lib']) - fi -else - with_ltdl_lib=no -fi - -case ,$with_included_ltdl,$with_ltdl_include,$with_ltdl_lib, in - ,yes,no,no,) - m4_case(m4_default(_LTDL_TYPE, [convenience]), - [convenience], [_LTDL_CONVENIENCE], - [installable], [_LTDL_INSTALLABLE], - [m4_fatal([unknown libltdl build type: ]_LTDL_TYPE)]) - ;; - ,no,no,no,) - # If the included ltdl is not to be used, then use the - # preinstalled libltdl we found. - AC_DEFINE([HAVE_LTDL], [1], - [Define this if a modern libltdl is already installed]) - LIBLTDL=-lltdl - LTDLDEPS= - LTDLINCL= - ;; - ,no*,no,*) - AC_MSG_ERROR([`--with-ltdl-include' and `--with-ltdl-lib' options must be used together]) - ;; - *) with_included_ltdl=no - LIBLTDL="-L$with_ltdl_lib -lltdl" - LTDLDEPS= - LTDLINCL="-I$with_ltdl_include" - ;; -esac -INCLTDL="$LTDLINCL" - -# Report our decision... -AC_MSG_CHECKING([where to find libltdl headers]) -AC_MSG_RESULT([$LTDLINCL]) -AC_MSG_CHECKING([where to find libltdl library]) -AC_MSG_RESULT([$LIBLTDL]) - -_LTDL_SETUP - -dnl restore autoconf definition. -m4_popdef([AC_LIBOBJ]) -m4_popdef([AC_LIBSOURCES]) - -AC_CONFIG_COMMANDS_PRE([ - _ltdl_libobjs= - _ltdl_ltlibobjs= - if test -n "$_LT_LIBOBJS"; then - # Remove the extension. - _lt_sed_drop_objext='s/\.o$//;s/\.obj$//' - for i in `for i in $_LT_LIBOBJS; do echo "$i"; done | sed "$_lt_sed_drop_objext" | sort -u`; do - _ltdl_libobjs="$_ltdl_libobjs $lt_libobj_prefix$i.$ac_objext" - _ltdl_ltlibobjs="$_ltdl_ltlibobjs $lt_libobj_prefix$i.lo" - done - fi - AC_SUBST([ltdl_LIBOBJS], [$_ltdl_libobjs]) - AC_SUBST([ltdl_LTLIBOBJS], [$_ltdl_ltlibobjs]) -]) - -# Only expand once: -m4_define([LTDL_INIT]) -])# LTDL_INIT - -# Old names: -AU_DEFUN([AC_LIB_LTDL], [LTDL_INIT($@)]) -AU_DEFUN([AC_WITH_LTDL], [LTDL_INIT($@)]) -AU_DEFUN([LT_WITH_LTDL], [LTDL_INIT($@)]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LIB_LTDL], []) -dnl AC_DEFUN([AC_WITH_LTDL], []) -dnl AC_DEFUN([LT_WITH_LTDL], []) - - -# _LTDL_SETUP -# ----------- -# Perform all the checks necessary for compilation of the ltdl objects -# -- including compiler checks and header checks. This is a public -# interface mainly for the benefit of libltdl's own configure.ac, most -# other users should call LTDL_INIT instead. -AC_DEFUN([_LTDL_SETUP], -[AC_REQUIRE([AC_PROG_CC])dnl -AC_REQUIRE([LT_SYS_MODULE_EXT])dnl -AC_REQUIRE([LT_SYS_MODULE_PATH])dnl -AC_REQUIRE([LT_SYS_DLSEARCH_PATH])dnl -AC_REQUIRE([LT_LIB_DLLOAD])dnl -AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl -AC_REQUIRE([LT_FUNC_DLSYM_USCORE])dnl -AC_REQUIRE([LT_SYS_DLOPEN_DEPLIBS])dnl -AC_REQUIRE([gl_FUNC_ARGZ])dnl - -m4_require([_LT_CHECK_OBJDIR])dnl -m4_require([_LT_HEADER_DLFCN])dnl -m4_require([_LT_CHECK_DLPREOPEN])dnl -m4_require([_LT_DECL_SED])dnl - -dnl Don't require this, or it will be expanded earlier than the code -dnl that sets the variables it relies on: -_LT_ENABLE_INSTALL - -dnl _LTDL_MODE specific code must be called at least once: -_LTDL_MODE_DISPATCH - -# In order that ltdl.c can compile, find out the first AC_CONFIG_HEADERS -# the user used. This is so that ltdl.h can pick up the parent projects -# config.h file, The first file in AC_CONFIG_HEADERS must contain the -# definitions required by ltdl.c. -# FIXME: Remove use of undocumented AC_LIST_HEADERS (2.59 compatibility). -AC_CONFIG_COMMANDS_PRE([dnl -m4_pattern_allow([^LT_CONFIG_H$])dnl -m4_ifset([AH_HEADER], - [LT_CONFIG_H=AH_HEADER], - [m4_ifset([AC_LIST_HEADERS], - [LT_CONFIG_H=`echo "AC_LIST_HEADERS" | $SED 's,^[[ ]]*,,;s,[[ :]].*$,,'`], - [])])]) -AC_SUBST([LT_CONFIG_H]) - -AC_CHECK_HEADERS([unistd.h dl.h sys/dl.h dld.h mach-o/dyld.h dirent.h], - [], [], [AC_INCLUDES_DEFAULT]) - -AC_CHECK_FUNCS([closedir opendir readdir], [], [AC_LIBOBJ([lt__dirent])]) -AC_CHECK_FUNCS([strlcat strlcpy], [], [AC_LIBOBJ([lt__strl])]) - -AC_DEFINE_UNQUOTED([LT_LIBEXT],["$libext"],[The archive extension]) - -name=ltdl -LTDLOPEN=`eval "\\$ECHO \"$libname_spec\""` -AC_SUBST([LTDLOPEN]) -])# _LTDL_SETUP - - -# _LT_ENABLE_INSTALL -# ------------------ -m4_define([_LT_ENABLE_INSTALL], -[AC_ARG_ENABLE([ltdl-install], - [AS_HELP_STRING([--enable-ltdl-install], [install libltdl])]) - -case ,${enable_ltdl_install},${enable_ltdl_convenience} in - *yes*) ;; - *) enable_ltdl_convenience=yes ;; -esac - -m4_ifdef([AM_CONDITIONAL], -[AM_CONDITIONAL(INSTALL_LTDL, test x"${enable_ltdl_install-no}" != xno) - AM_CONDITIONAL(CONVENIENCE_LTDL, test x"${enable_ltdl_convenience-no}" != xno)]) -])# _LT_ENABLE_INSTALL - - -# LT_SYS_DLOPEN_DEPLIBS -# --------------------- -AC_DEFUN([LT_SYS_DLOPEN_DEPLIBS], -[AC_REQUIRE([AC_CANONICAL_HOST])dnl -AC_CACHE_CHECK([whether deplibs are loaded by dlopen], - [lt_cv_sys_dlopen_deplibs], - [# PORTME does your system automatically load deplibs for dlopen? - # or its logical equivalent (e.g. shl_load for HP-UX < 11) - # For now, we just catch OSes we know something about -- in the - # future, we'll try test this programmatically. - lt_cv_sys_dlopen_deplibs=unknown - case $host_os in - aix3*|aix4.1.*|aix4.2.*) - # Unknown whether this is true for these versions of AIX, but - # we want this `case' here to explicitly catch those versions. - lt_cv_sys_dlopen_deplibs=unknown - ;; - aix[[4-9]]*) - lt_cv_sys_dlopen_deplibs=yes - ;; - amigaos*) - case $host_cpu in - powerpc) - lt_cv_sys_dlopen_deplibs=no - ;; - esac - ;; - darwin*) - # Assuming the user has installed a libdl from somewhere, this is true - # If you are looking for one http://www.opendarwin.org/projects/dlcompat - lt_cv_sys_dlopen_deplibs=yes - ;; - freebsd* | dragonfly*) - lt_cv_sys_dlopen_deplibs=yes - ;; - gnu* | linux* | k*bsd*-gnu) - # GNU and its variants, using gnu ld.so (Glibc) - lt_cv_sys_dlopen_deplibs=yes - ;; - hpux10*|hpux11*) - lt_cv_sys_dlopen_deplibs=yes - ;; - interix*) - lt_cv_sys_dlopen_deplibs=yes - ;; - irix[[12345]]*|irix6.[[01]]*) - # Catch all versions of IRIX before 6.2, and indicate that we don't - # know how it worked for any of those versions. - lt_cv_sys_dlopen_deplibs=unknown - ;; - irix*) - # The case above catches anything before 6.2, and it's known that - # at 6.2 and later dlopen does load deplibs. - lt_cv_sys_dlopen_deplibs=yes - ;; - netbsd*) - lt_cv_sys_dlopen_deplibs=yes - ;; - openbsd*) - lt_cv_sys_dlopen_deplibs=yes - ;; - osf[[1234]]*) - # dlopen did load deplibs (at least at 4.x), but until the 5.x series, - # it did *not* use an RPATH in a shared library to find objects the - # library depends on, so we explicitly say `no'. - lt_cv_sys_dlopen_deplibs=no - ;; - osf5.0|osf5.0a|osf5.1) - # dlopen *does* load deplibs and with the right loader patch applied - # it even uses RPATH in a shared library to search for shared objects - # that the library depends on, but there's no easy way to know if that - # patch is installed. Since this is the case, all we can really - # say is unknown -- it depends on the patch being installed. If - # it is, this changes to `yes'. Without it, it would be `no'. - lt_cv_sys_dlopen_deplibs=unknown - ;; - osf*) - # the two cases above should catch all versions of osf <= 5.1. Read - # the comments above for what we know about them. - # At > 5.1, deplibs are loaded *and* any RPATH in a shared library - # is used to find them so we can finally say `yes'. - lt_cv_sys_dlopen_deplibs=yes - ;; - qnx*) - lt_cv_sys_dlopen_deplibs=yes - ;; - solaris*) - lt_cv_sys_dlopen_deplibs=yes - ;; - sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - libltdl_cv_sys_dlopen_deplibs=yes - ;; - esac - ]) -if test "$lt_cv_sys_dlopen_deplibs" != yes; then - AC_DEFINE([LTDL_DLOPEN_DEPLIBS], [1], - [Define if the OS needs help to load dependent libraries for dlopen().]) -fi -])# LT_SYS_DLOPEN_DEPLIBS - -# Old name: -AU_ALIAS([AC_LTDL_SYS_DLOPEN_DEPLIBS], [LT_SYS_DLOPEN_DEPLIBS]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_SYS_DLOPEN_DEPLIBS], []) - - -# LT_SYS_MODULE_EXT -# ----------------- -AC_DEFUN([LT_SYS_MODULE_EXT], -[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl -AC_CACHE_CHECK([which extension is used for runtime loadable modules], - [libltdl_cv_shlibext], -[ -module=yes -eval libltdl_cv_shlibext=$shrext_cmds - ]) -if test -n "$libltdl_cv_shlibext"; then - m4_pattern_allow([LT_MODULE_EXT])dnl - AC_DEFINE_UNQUOTED([LT_MODULE_EXT], ["$libltdl_cv_shlibext"], - [Define to the extension used for runtime loadable modules, say, ".so".]) -fi -])# LT_SYS_MODULE_EXT - -# Old name: -AU_ALIAS([AC_LTDL_SHLIBEXT], [LT_SYS_MODULE_EXT]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_SHLIBEXT], []) - - -# LT_SYS_MODULE_PATH -# ------------------ -AC_DEFUN([LT_SYS_MODULE_PATH], -[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl -AC_CACHE_CHECK([which variable specifies run-time module search path], - [lt_cv_module_path_var], [lt_cv_module_path_var="$shlibpath_var"]) -if test -n "$lt_cv_module_path_var"; then - m4_pattern_allow([LT_MODULE_PATH_VAR])dnl - AC_DEFINE_UNQUOTED([LT_MODULE_PATH_VAR], ["$lt_cv_module_path_var"], - [Define to the name of the environment variable that determines the run-time module search path.]) -fi -])# LT_SYS_MODULE_PATH - -# Old name: -AU_ALIAS([AC_LTDL_SHLIBPATH], [LT_SYS_MODULE_PATH]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_SHLIBPATH], []) - - -# LT_SYS_DLSEARCH_PATH -# -------------------- -AC_DEFUN([LT_SYS_DLSEARCH_PATH], -[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl -AC_CACHE_CHECK([for the default library search path], - [lt_cv_sys_dlsearch_path], - [lt_cv_sys_dlsearch_path="$sys_lib_dlsearch_path_spec"]) -if test -n "$lt_cv_sys_dlsearch_path"; then - sys_dlsearch_path= - for dir in $lt_cv_sys_dlsearch_path; do - if test -z "$sys_dlsearch_path"; then - sys_dlsearch_path="$dir" - else - sys_dlsearch_path="$sys_dlsearch_path$PATH_SEPARATOR$dir" - fi - done - m4_pattern_allow([LT_DLSEARCH_PATH])dnl - AC_DEFINE_UNQUOTED([LT_DLSEARCH_PATH], ["$sys_dlsearch_path"], - [Define to the system default library search path.]) -fi -])# LT_SYS_DLSEARCH_PATH - -# Old name: -AU_ALIAS([AC_LTDL_SYSSEARCHPATH], [LT_SYS_DLSEARCH_PATH]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_SYSSEARCHPATH], []) - - -# _LT_CHECK_DLPREOPEN -# ------------------- -m4_defun([_LT_CHECK_DLPREOPEN], -[m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -AC_CACHE_CHECK([whether libtool supports -dlopen/-dlpreopen], - [libltdl_cv_preloaded_symbols], - [if test -n "$lt_cv_sys_global_symbol_pipe"; then - libltdl_cv_preloaded_symbols=yes - else - libltdl_cv_preloaded_symbols=no - fi - ]) -if test x"$libltdl_cv_preloaded_symbols" = xyes; then - AC_DEFINE([HAVE_PRELOADED_SYMBOLS], [1], - [Define if libtool can extract symbol lists from object files.]) -fi -])# _LT_CHECK_DLPREOPEN - - -# LT_LIB_DLLOAD -# ------------- -AC_DEFUN([LT_LIB_DLLOAD], -[m4_pattern_allow([^LT_DLLOADERS$]) -LT_DLLOADERS= -AC_SUBST([LT_DLLOADERS]) - -AC_LANG_PUSH([C]) - -LIBADD_DLOPEN= -AC_SEARCH_LIBS([dlopen], [dl], - [AC_DEFINE([HAVE_LIBDL], [1], - [Define if you have the libdl library or equivalent.]) - if test "$ac_cv_search_dlopen" != "none required" ; then - LIBADD_DLOPEN="-ldl" - fi - libltdl_cv_lib_dl_dlopen="yes" - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"], - [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#if HAVE_DLFCN_H -# include -#endif - ]], [[dlopen(0, 0);]])], - [AC_DEFINE([HAVE_LIBDL], [1], - [Define if you have the libdl library or equivalent.]) - libltdl_cv_func_dlopen="yes" - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"], - [AC_CHECK_LIB([svld], [dlopen], - [AC_DEFINE([HAVE_LIBDL], [1], - [Define if you have the libdl library or equivalent.]) - LIBADD_DLOPEN="-lsvld" libltdl_cv_func_dlopen="yes" - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"])])]) -if test x"$libltdl_cv_func_dlopen" = xyes || test x"$libltdl_cv_lib_dl_dlopen" = xyes -then - lt_save_LIBS="$LIBS" - LIBS="$LIBS $LIBADD_DLOPEN" - AC_CHECK_FUNCS([dlerror]) - LIBS="$lt_save_LIBS" -fi -AC_SUBST([LIBADD_DLOPEN]) - -LIBADD_SHL_LOAD= -AC_CHECK_FUNC([shl_load], - [AC_DEFINE([HAVE_SHL_LOAD], [1], - [Define if you have the shl_load function.]) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la"], - [AC_CHECK_LIB([dld], [shl_load], - [AC_DEFINE([HAVE_SHL_LOAD], [1], - [Define if you have the shl_load function.]) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la" - LIBADD_SHL_LOAD="-ldld"])]) -AC_SUBST([LIBADD_SHL_LOAD]) - -case $host_os in -darwin[[1567]].*) -# We only want this for pre-Mac OS X 10.4. - AC_CHECK_FUNC([_dyld_func_lookup], - [AC_DEFINE([HAVE_DYLD], [1], - [Define if you have the _dyld_func_lookup function.]) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dyld.la"]) - ;; -beos*) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}load_add_on.la" - ;; -cygwin* | mingw* | os2* | pw32*) - AC_CHECK_DECLS([cygwin_conv_path], [], [], [[#include ]]) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}loadlibrary.la" - ;; -esac - -AC_CHECK_LIB([dld], [dld_link], - [AC_DEFINE([HAVE_DLD], [1], - [Define if you have the GNU dld library.]) - LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dld_link.la"]) -AC_SUBST([LIBADD_DLD_LINK]) - -m4_pattern_allow([^LT_DLPREOPEN$]) -LT_DLPREOPEN= -if test -n "$LT_DLLOADERS" -then - for lt_loader in $LT_DLLOADERS; do - LT_DLPREOPEN="$LT_DLPREOPEN-dlpreopen $lt_loader " - done - AC_DEFINE([HAVE_LIBDLLOADER], [1], - [Define if libdlloader will be built on this platform]) -fi -AC_SUBST([LT_DLPREOPEN]) - -dnl This isn't used anymore, but set it for backwards compatibility -LIBADD_DL="$LIBADD_DLOPEN $LIBADD_SHL_LOAD" -AC_SUBST([LIBADD_DL]) - -AC_LANG_POP -])# LT_LIB_DLLOAD - -# Old name: -AU_ALIAS([AC_LTDL_DLLIB], [LT_LIB_DLLOAD]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_DLLIB], []) - - -# LT_SYS_SYMBOL_USCORE -# -------------------- -# does the compiler prefix global symbols with an underscore? -AC_DEFUN([LT_SYS_SYMBOL_USCORE], -[m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -AC_CACHE_CHECK([for _ prefix in compiled symbols], - [lt_cv_sys_symbol_underscore], - [lt_cv_sys_symbol_underscore=no - cat > conftest.$ac_ext <<_LT_EOF -void nm_test_func(){} -int main(){nm_test_func;return 0;} -_LT_EOF - if AC_TRY_EVAL(ac_compile); then - # Now try to grab the symbols. - ac_nlist=conftest.nm - if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist) && test -s "$ac_nlist"; then - # See whether the symbols have a leading underscore. - if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then - lt_cv_sys_symbol_underscore=yes - else - if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then - : - else - echo "configure: cannot find nm_test_func in $ac_nlist" >&AS_MESSAGE_LOG_FD - fi - fi - else - echo "configure: cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD - fi - else - echo "configure: failed program was:" >&AS_MESSAGE_LOG_FD - cat conftest.c >&AS_MESSAGE_LOG_FD - fi - rm -rf conftest* - ]) - sys_symbol_underscore=$lt_cv_sys_symbol_underscore - AC_SUBST([sys_symbol_underscore]) -])# LT_SYS_SYMBOL_USCORE - -# Old name: -AU_ALIAS([AC_LTDL_SYMBOL_USCORE], [LT_SYS_SYMBOL_USCORE]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_SYMBOL_USCORE], []) - - -# LT_FUNC_DLSYM_USCORE -# -------------------- -AC_DEFUN([LT_FUNC_DLSYM_USCORE], -[AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl -if test x"$lt_cv_sys_symbol_underscore" = xyes; then - if test x"$libltdl_cv_func_dlopen" = xyes || - test x"$libltdl_cv_lib_dl_dlopen" = xyes ; then - AC_CACHE_CHECK([whether we have to add an underscore for dlsym], - [libltdl_cv_need_uscore], - [libltdl_cv_need_uscore=unknown - save_LIBS="$LIBS" - LIBS="$LIBS $LIBADD_DLOPEN" - _LT_TRY_DLOPEN_SELF( - [libltdl_cv_need_uscore=no], [libltdl_cv_need_uscore=yes], - [], [libltdl_cv_need_uscore=cross]) - LIBS="$save_LIBS" - ]) - fi -fi - -if test x"$libltdl_cv_need_uscore" = xyes; then - AC_DEFINE([NEED_USCORE], [1], - [Define if dlsym() requires a leading underscore in symbol names.]) -fi -])# LT_FUNC_DLSYM_USCORE - -# Old name: -AU_ALIAS([AC_LTDL_DLSYM_USCORE], [LT_FUNC_DLSYM_USCORE]) -dnl aclocal-1.4 backwards compatibility: -dnl AC_DEFUN([AC_LTDL_DLSYM_USCORE], []) - # Helper functions for option handling. -*- Autoconf -*- # # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. diff --git a/js/src/ctypes/libffi/configure b/js/src/ctypes/libffi/configure index be82780669d..37e30551450 100755 --- a/js/src/ctypes/libffi/configure +++ b/js/src/ctypes/libffi/configure @@ -752,7 +752,6 @@ FFI_DEBUG_FALSE FFI_DEBUG_TRUE TARGETDIR TARGET -sys_symbol_underscore HAVE_LONG_DOUBLE ALLOCA PA64_HPUX_FALSE @@ -12362,63 +12361,6 @@ $as_echo "#define HAVE_AS_STRING_PSEUDO_OP 1" >>confdefs.h fi fi -if test x$TARGET = xX86_WIN64; then - { $as_echo "$as_me:$LINENO: checking for _ prefix in compiled symbols" >&5 -$as_echo_n "checking for _ prefix in compiled symbols... " >&6; } -if test "${lt_cv_sys_symbol_underscore+set}" = set; then - $as_echo_n "(cached) " >&6 -else - lt_cv_sys_symbol_underscore=no - cat > conftest.$ac_ext <<_LT_EOF -void nm_test_func(){} -int main(){nm_test_func;return 0;} -_LT_EOF - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); }; then - # Now try to grab the symbols. - ac_nlist=conftest.nm - if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist\"") >&5 - (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist) 2>&5 - ac_status=$? - $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 - (exit $ac_status); } && test -s "$ac_nlist"; then - # See whether the symbols have a leading underscore. - if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then - lt_cv_sys_symbol_underscore=yes - else - if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then - : - else - echo "configure: cannot find nm_test_func in $ac_nlist" >&5 - fi - fi - else - echo "configure: cannot run $lt_cv_sys_global_symbol_pipe" >&5 - fi - else - echo "configure: failed program was:" >&5 - cat conftest.c >&5 - fi - rm -rf conftest* - -fi -{ $as_echo "$as_me:$LINENO: result: $lt_cv_sys_symbol_underscore" >&5 -$as_echo "$lt_cv_sys_symbol_underscore" >&6; } - sys_symbol_underscore=$lt_cv_sys_symbol_underscore - - - if test "x$sys_symbol_underscore" = xyes; then - -cat >>confdefs.h <<\_ACEOF -#define SYMBOL_UNDERSCORE 1 -_ACEOF - - fi -fi - case "$target" in *-apple-darwin1* | *-*-freebsd* | *-*-openbsd* | *-pc-solaris*) diff --git a/js/src/ctypes/libffi/configure.ac b/js/src/ctypes/libffi/configure.ac index d149b2e8efe..1db02ce004d 100644 --- a/js/src/ctypes/libffi/configure.ac +++ b/js/src/ctypes/libffi/configure.ac @@ -315,13 +315,6 @@ if test x$TARGET = xX86 || test x$TARGET = xX86_WIN32 || test x$TARGET = xX86_64 fi fi -if test x$TARGET = xX86_WIN64; then - LT_SYS_SYMBOL_USCORE - if test "x$sys_symbol_underscore" = xyes; then - AC_DEFINE(SYMBOL_UNDERSCORE, 1, [Define if symbols are underscored.]) - fi -fi - case "$target" in # Darwin 10 (OSX 10.6) and beyond allocate non-executable pages *-apple-darwin1* | *-*-freebsd* | *-*-openbsd* | *-pc-solaris*) diff --git a/js/src/ctypes/libffi/src/x86/win64.S b/js/src/ctypes/libffi/src/x86/win64.S index fcdb270faf5..6e9181867de 100644 --- a/js/src/ctypes/libffi/src/x86/win64.S +++ b/js/src/ctypes/libffi/src/x86/win64.S @@ -232,18 +232,10 @@ ret_void$: ffi_call_win64 ENDP _TEXT ENDS END - -#else - -#ifdef SYMBOL_UNDERSCORE -#define SYMBOL_NAME(name) _##name -#else -#define SYMBOL_NAME(name) name -#endif - +#else .text -.extern SYMBOL_NAME(ffi_closure_win64_inner) +.extern _ffi_closure_win64_inner # ffi_closure_win64 will be called with these registers set: # rax points to 'closure' @@ -254,8 +246,8 @@ END # call ffi_closure_win64_inner for the actual work, then return the result. # .balign 16 - .globl SYMBOL_NAME(ffi_closure_win64) -SYMBOL_NAME(ffi_closure_win64): + .globl _ffi_closure_win64 +_ffi_closure_win64: # copy register arguments onto stack test $1,%r11 jne .Lfirst_is_float @@ -295,7 +287,7 @@ SYMBOL_NAME(ffi_closure_win64): mov %rax, %rcx # context is first parameter mov %rsp, %rdx # stack is second parameter add $48, %rdx # point to start of arguments - mov $SYMBOL_NAME(ffi_closure_win64_inner), %rax + mov $_ffi_closure_win64_inner, %rax callq *%rax # call the real closure function add $40, %rsp movq %rax, %xmm0 # If the closure returned a float, @@ -304,8 +296,8 @@ SYMBOL_NAME(ffi_closure_win64): .ffi_closure_win64_end: .balign 16 - .globl SYMBOL_NAME(ffi_call_win64) -SYMBOL_NAME(ffi_call_win64): + .globl _ffi_call_win64 +_ffi_call_win64: # copy registers onto stack mov %r9,32(%rsp) mov %r8,24(%rsp) diff --git a/js/src/ctypes/patches-libffi/03-bug-712594.patch b/js/src/ctypes/patches-libffi/03-bug-712594.patch deleted file mode 100644 index 1d62ad77449..00000000000 --- a/js/src/ctypes/patches-libffi/03-bug-712594.patch +++ /dev/null @@ -1,1072 +0,0 @@ -commit 5b9cd52784339a42e417174a55e310e214d435f9 -Author: Anthony Green -Date: Mon Nov 22 15:19:57 2010 -0500 - - win64-underscore patch - -diff --git a/aclocal.m4 b/aclocal.m4 -index 0ef4b09..4079f82 100644 ---- a/aclocal.m4 -+++ b/aclocal.m4 -@@ -7364,6 +7364,811 @@ _LT_EOF - esac - ]) - -+# ltdl.m4 - Configure ltdl for the target system. -*-Autoconf-*- -+# -+# Copyright (C) 1999-2006, 2007, 2008 Free Software Foundation, Inc. -+# Written by Thomas Tanner, 1999 -+# -+# This file is free software; the Free Software Foundation gives -+# unlimited permission to copy and/or distribute it, with or without -+# modifications, as long as this notice is preserved. -+ -+# serial 17 LTDL_INIT -+ -+# LT_CONFIG_LTDL_DIR(DIRECTORY, [LTDL-MODE]) -+# ------------------------------------------ -+# DIRECTORY contains the libltdl sources. It is okay to call this -+# function multiple times, as long as the same DIRECTORY is always given. -+AC_DEFUN([LT_CONFIG_LTDL_DIR], -+[AC_BEFORE([$0], [LTDL_INIT]) -+_$0($*) -+])# LT_CONFIG_LTDL_DIR -+ -+# We break this out into a separate macro, so that we can call it safely -+# internally without being caught accidentally by the sed scan in libtoolize. -+m4_defun([_LT_CONFIG_LTDL_DIR], -+[dnl remove trailing slashes -+m4_pushdef([_ARG_DIR], m4_bpatsubst([$1], [/*$])) -+m4_case(_LTDL_DIR, -+ [], [dnl only set lt_ltdl_dir if _ARG_DIR is not simply `.' -+ m4_if(_ARG_DIR, [.], -+ [], -+ [m4_define([_LTDL_DIR], _ARG_DIR) -+ _LT_SHELL_INIT([lt_ltdl_dir=']_ARG_DIR['])])], -+ [m4_if(_ARG_DIR, _LTDL_DIR, -+ [], -+ [m4_fatal([multiple libltdl directories: `]_LTDL_DIR[', `]_ARG_DIR['])])]) -+m4_popdef([_ARG_DIR]) -+])# _LT_CONFIG_LTDL_DIR -+ -+# Initialise: -+m4_define([_LTDL_DIR], []) -+ -+ -+# _LT_BUILD_PREFIX -+# ---------------- -+# If Autoconf is new enough, expand to `${top_build_prefix}', otherwise -+# to `${top_builddir}/'. -+m4_define([_LT_BUILD_PREFIX], -+[m4_ifdef([AC_AUTOCONF_VERSION], -+ [m4_if(m4_version_compare(m4_defn([AC_AUTOCONF_VERSION]), [2.62]), -+ [-1], [m4_ifdef([_AC_HAVE_TOP_BUILD_PREFIX], -+ [${top_build_prefix}], -+ [${top_builddir}/])], -+ [${top_build_prefix}])], -+ [${top_builddir}/])[]dnl -+]) -+ -+ -+# LTDL_CONVENIENCE -+# ---------------- -+# sets LIBLTDL to the link flags for the libltdl convenience library and -+# LTDLINCL to the include flags for the libltdl header and adds -+# --enable-ltdl-convenience to the configure arguments. Note that -+# AC_CONFIG_SUBDIRS is not called here. LIBLTDL will be prefixed with -+# '${top_build_prefix}' if available, otherwise with '${top_builddir}/', -+# and LTDLINCL will be prefixed with '${top_srcdir}/' (note the single -+# quotes!). If your package is not flat and you're not using automake, -+# define top_build_prefix, top_builddir, and top_srcdir appropriately -+# in your Makefiles. -+AC_DEFUN([LTDL_CONVENIENCE], -+[AC_BEFORE([$0], [LTDL_INIT])dnl -+dnl Although the argument is deprecated and no longer documented, -+dnl LTDL_CONVENIENCE used to take a DIRECTORY orgument, if we have one -+dnl here make sure it is the same as any other declaration of libltdl's -+dnl location! This also ensures lt_ltdl_dir is set when configure.ac is -+dnl not yet using an explicit LT_CONFIG_LTDL_DIR. -+m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl -+_$0() -+])# LTDL_CONVENIENCE -+ -+# AC_LIBLTDL_CONVENIENCE accepted a directory argument in older libtools, -+# now we have LT_CONFIG_LTDL_DIR: -+AU_DEFUN([AC_LIBLTDL_CONVENIENCE], -+[_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])]) -+_LTDL_CONVENIENCE]) -+ -+dnl aclocal-1.4 backwards compatibility: -+dnl AC_DEFUN([AC_LIBLTDL_CONVENIENCE], []) -+ -+ -+# _LTDL_CONVENIENCE -+# ----------------- -+# Code shared by LTDL_CONVENIENCE and LTDL_INIT([convenience]). -+m4_defun([_LTDL_CONVENIENCE], -+[case $enable_ltdl_convenience in -+ no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; -+ "") enable_ltdl_convenience=yes -+ ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; -+esac -+LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdlc.la" -+LTDLDEPS=$LIBLTDL -+LTDLINCL='-I${top_srcdir}'"${lt_ltdl_dir+/$lt_ltdl_dir}" -+ -+AC_SUBST([LIBLTDL]) -+AC_SUBST([LTDLDEPS]) -+AC_SUBST([LTDLINCL]) -+ -+# For backwards non-gettext consistent compatibility... -+INCLTDL="$LTDLINCL" -+AC_SUBST([INCLTDL]) -+])# _LTDL_CONVENIENCE -+ -+ -+# LTDL_INSTALLABLE -+# ---------------- -+# sets LIBLTDL to the link flags for the libltdl installable library -+# and LTDLINCL to the include flags for the libltdl header and adds -+# --enable-ltdl-install to the configure arguments. Note that -+# AC_CONFIG_SUBDIRS is not called from here. If an installed libltdl -+# is not found, LIBLTDL will be prefixed with '${top_build_prefix}' if -+# available, otherwise with '${top_builddir}/', and LTDLINCL will be -+# prefixed with '${top_srcdir}/' (note the single quotes!). If your -+# package is not flat and you're not using automake, define top_build_prefix, -+# top_builddir, and top_srcdir appropriately in your Makefiles. -+# In the future, this macro may have to be called after LT_INIT. -+AC_DEFUN([LTDL_INSTALLABLE], -+[AC_BEFORE([$0], [LTDL_INIT])dnl -+dnl Although the argument is deprecated and no longer documented, -+dnl LTDL_INSTALLABLE used to take a DIRECTORY orgument, if we have one -+dnl here make sure it is the same as any other declaration of libltdl's -+dnl location! This also ensures lt_ltdl_dir is set when configure.ac is -+dnl not yet using an explicit LT_CONFIG_LTDL_DIR. -+m4_ifval([$1], [_LT_CONFIG_LTDL_DIR([$1])])dnl -+_$0() -+])# LTDL_INSTALLABLE -+ -+# AC_LIBLTDL_INSTALLABLE accepted a directory argument in older libtools, -+# now we have LT_CONFIG_LTDL_DIR: -+AU_DEFUN([AC_LIBLTDL_INSTALLABLE], -+[_LT_CONFIG_LTDL_DIR([m4_default([$1], [libltdl])]) -+_LTDL_INSTALLABLE]) -+ -+dnl aclocal-1.4 backwards compatibility: -+dnl AC_DEFUN([AC_LIBLTDL_INSTALLABLE], []) -+ -+ -+# _LTDL_INSTALLABLE -+# ----------------- -+# Code shared by LTDL_INSTALLABLE and LTDL_INIT([installable]). -+m4_defun([_LTDL_INSTALLABLE], -+[if test -f $prefix/lib/libltdl.la; then -+ lt_save_LDFLAGS="$LDFLAGS" -+ LDFLAGS="-L$prefix/lib $LDFLAGS" -+ AC_CHECK_LIB([ltdl], [lt_dlinit], [lt_lib_ltdl=yes]) -+ LDFLAGS="$lt_save_LDFLAGS" -+ if test x"${lt_lib_ltdl-no}" = xyes; then -+ if test x"$enable_ltdl_install" != xyes; then -+ # Don't overwrite $prefix/lib/libltdl.la without --enable-ltdl-install -+ AC_MSG_WARN([not overwriting libltdl at $prefix, force with `--enable-ltdl-install']) -+ enable_ltdl_install=no -+ fi -+ elif test x"$enable_ltdl_install" = xno; then -+ AC_MSG_WARN([libltdl not installed, but installation disabled]) -+ fi -+fi -+ -+# If configure.ac declared an installable ltdl, and the user didn't override -+# with --disable-ltdl-install, we will install the shipped libltdl. -+case $enable_ltdl_install in -+ no) ac_configure_args="$ac_configure_args --enable-ltdl-install=no" -+ LIBLTDL="-lltdl" -+ LTDLDEPS= -+ LTDLINCL= -+ ;; -+ *) enable_ltdl_install=yes -+ ac_configure_args="$ac_configure_args --enable-ltdl-install" -+ LIBLTDL='_LT_BUILD_PREFIX'"${lt_ltdl_dir+$lt_ltdl_dir/}libltdl.la" -+ LTDLDEPS=$LIBLTDL -+ LTDLINCL='-I${top_srcdir}'"${lt_ltdl_dir+/$lt_ltdl_dir}" -+ ;; -+esac -+ -+AC_SUBST([LIBLTDL]) -+AC_SUBST([LTDLDEPS]) -+AC_SUBST([LTDLINCL]) -+ -+# For backwards non-gettext consistent compatibility... -+INCLTDL="$LTDLINCL" -+AC_SUBST([INCLTDL]) -+])# LTDL_INSTALLABLE -+ -+ -+# _LTDL_MODE_DISPATCH -+# ------------------- -+m4_define([_LTDL_MODE_DISPATCH], -+[dnl If _LTDL_DIR is `.', then we are configuring libltdl itself: -+m4_if(_LTDL_DIR, [], -+ [], -+ dnl if _LTDL_MODE was not set already, the default value is `subproject': -+ [m4_case(m4_default(_LTDL_MODE, [subproject]), -+ [subproject], [AC_CONFIG_SUBDIRS(_LTDL_DIR) -+ _LT_SHELL_INIT([lt_dlopen_dir="$lt_ltdl_dir"])], -+ [nonrecursive], [_LT_SHELL_INIT([lt_dlopen_dir="$lt_ltdl_dir"; lt_libobj_prefix="$lt_ltdl_dir/"])], -+ [recursive], [], -+ [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])])dnl -+dnl Be careful not to expand twice: -+m4_define([$0], []) -+])# _LTDL_MODE_DISPATCH -+ -+ -+# _LT_LIBOBJ(MODULE_NAME) -+# ----------------------- -+# Like AC_LIBOBJ, except that MODULE_NAME goes into _LT_LIBOBJS instead -+# of into LIBOBJS. -+AC_DEFUN([_LT_LIBOBJ], [ -+ m4_pattern_allow([^_LT_LIBOBJS$]) -+ _LT_LIBOBJS="$_LT_LIBOBJS $1.$ac_objext" -+])# _LT_LIBOBJS -+ -+ -+# LTDL_INIT([OPTIONS]) -+# -------------------- -+# Clients of libltdl can use this macro to allow the installer to -+# choose between a shipped copy of the ltdl sources or a preinstalled -+# version of the library. If the shipped ltdl sources are not in a -+# subdirectory named libltdl, the directory name must be given by -+# LT_CONFIG_LTDL_DIR. -+AC_DEFUN([LTDL_INIT], -+[dnl Parse OPTIONS -+_LT_SET_OPTIONS([$0], [$1]) -+ -+dnl We need to keep our own list of libobjs separate from our parent project, -+dnl and the easiest way to do that is redefine the AC_LIBOBJs macro while -+dnl we look for our own LIBOBJs. -+m4_pushdef([AC_LIBOBJ], m4_defn([_LT_LIBOBJ])) -+m4_pushdef([AC_LIBSOURCES]) -+ -+dnl If not otherwise defined, default to the 1.5.x compatible subproject mode: -+m4_if(_LTDL_MODE, [], -+ [m4_define([_LTDL_MODE], m4_default([$2], [subproject])) -+ m4_if([-1], [m4_bregexp(_LTDL_MODE, [\(subproject\|\(non\)?recursive\)])], -+ [m4_fatal([unknown libltdl mode: ]_LTDL_MODE)])]) -+ -+AC_ARG_WITH([included_ltdl], -+ [AS_HELP_STRING([--with-included-ltdl], -+ [use the GNU ltdl sources included here])]) -+ -+if test "x$with_included_ltdl" != xyes; then -+ # We are not being forced to use the included libltdl sources, so -+ # decide whether there is a useful installed version we can use. -+ AC_CHECK_HEADER([ltdl.h], -+ [AC_CHECK_DECL([lt_dlinterface_register], -+ [AC_CHECK_LIB([ltdl], [lt_dladvise_preload], -+ [with_included_ltdl=no], -+ [with_included_ltdl=yes])], -+ [with_included_ltdl=yes], -+ [AC_INCLUDES_DEFAULT -+ #include ])], -+ [with_included_ltdl=yes], -+ [AC_INCLUDES_DEFAULT] -+ ) -+fi -+ -+dnl If neither LT_CONFIG_LTDL_DIR, LTDL_CONVENIENCE nor LTDL_INSTALLABLE -+dnl was called yet, then for old times' sake, we assume libltdl is in an -+dnl eponymous directory: -+AC_PROVIDE_IFELSE([LT_CONFIG_LTDL_DIR], [], [_LT_CONFIG_LTDL_DIR([libltdl])]) -+ -+AC_ARG_WITH([ltdl_include], -+ [AS_HELP_STRING([--with-ltdl-include=DIR], -+ [use the ltdl headers installed in DIR])]) -+ -+if test -n "$with_ltdl_include"; then -+ if test -f "$with_ltdl_include/ltdl.h"; then : -+ else -+ AC_MSG_ERROR([invalid ltdl include directory: `$with_ltdl_include']) -+ fi -+else -+ with_ltdl_include=no -+fi -+ -+AC_ARG_WITH([ltdl_lib], -+ [AS_HELP_STRING([--with-ltdl-lib=DIR], -+ [use the libltdl.la installed in DIR])]) -+ -+if test -n "$with_ltdl_lib"; then -+ if test -f "$with_ltdl_lib/libltdl.la"; then : -+ else -+ AC_MSG_ERROR([invalid ltdl library directory: `$with_ltdl_lib']) -+ fi -+else -+ with_ltdl_lib=no -+fi -+ -+case ,$with_included_ltdl,$with_ltdl_include,$with_ltdl_lib, in -+ ,yes,no,no,) -+ m4_case(m4_default(_LTDL_TYPE, [convenience]), -+ [convenience], [_LTDL_CONVENIENCE], -+ [installable], [_LTDL_INSTALLABLE], -+ [m4_fatal([unknown libltdl build type: ]_LTDL_TYPE)]) -+ ;; -+ ,no,no,no,) -+ # If the included ltdl is not to be used, then use the -+ # preinstalled libltdl we found. -+ AC_DEFINE([HAVE_LTDL], [1], -+ [Define this if a modern libltdl is already installed]) -+ LIBLTDL=-lltdl -+ LTDLDEPS= -+ LTDLINCL= -+ ;; -+ ,no*,no,*) -+ AC_MSG_ERROR([`--with-ltdl-include' and `--with-ltdl-lib' options must be used together]) -+ ;; -+ *) with_included_ltdl=no -+ LIBLTDL="-L$with_ltdl_lib -lltdl" -+ LTDLDEPS= -+ LTDLINCL="-I$with_ltdl_include" -+ ;; -+esac -+INCLTDL="$LTDLINCL" -+ -+# Report our decision... -+AC_MSG_CHECKING([where to find libltdl headers]) -+AC_MSG_RESULT([$LTDLINCL]) -+AC_MSG_CHECKING([where to find libltdl library]) -+AC_MSG_RESULT([$LIBLTDL]) -+ -+_LTDL_SETUP -+ -+dnl restore autoconf definition. -+m4_popdef([AC_LIBOBJ]) -+m4_popdef([AC_LIBSOURCES]) -+ -+AC_CONFIG_COMMANDS_PRE([ -+ _ltdl_libobjs= -+ _ltdl_ltlibobjs= -+ if test -n "$_LT_LIBOBJS"; then -+ # Remove the extension. -+ _lt_sed_drop_objext='s/\.o$//;s/\.obj$//' -+ for i in `for i in $_LT_LIBOBJS; do echo "$i"; done | sed "$_lt_sed_drop_objext" | sort -u`; do -+ _ltdl_libobjs="$_ltdl_libobjs $lt_libobj_prefix$i.$ac_objext" -+ _ltdl_ltlibobjs="$_ltdl_ltlibobjs $lt_libobj_prefix$i.lo" -+ done -+ fi -+ AC_SUBST([ltdl_LIBOBJS], [$_ltdl_libobjs]) -+ AC_SUBST([ltdl_LTLIBOBJS], [$_ltdl_ltlibobjs]) -+]) -+ -+# Only expand once: -+m4_define([LTDL_INIT]) -+])# LTDL_INIT -+ -+# Old names: -+AU_DEFUN([AC_LIB_LTDL], [LTDL_INIT($@)]) -+AU_DEFUN([AC_WITH_LTDL], [LTDL_INIT($@)]) -+AU_DEFUN([LT_WITH_LTDL], [LTDL_INIT($@)]) -+dnl aclocal-1.4 backwards compatibility: -+dnl AC_DEFUN([AC_LIB_LTDL], []) -+dnl AC_DEFUN([AC_WITH_LTDL], []) -+dnl AC_DEFUN([LT_WITH_LTDL], []) -+ -+ -+# _LTDL_SETUP -+# ----------- -+# Perform all the checks necessary for compilation of the ltdl objects -+# -- including compiler checks and header checks. This is a public -+# interface mainly for the benefit of libltdl's own configure.ac, most -+# other users should call LTDL_INIT instead. -+AC_DEFUN([_LTDL_SETUP], -+[AC_REQUIRE([AC_PROG_CC])dnl -+AC_REQUIRE([LT_SYS_MODULE_EXT])dnl -+AC_REQUIRE([LT_SYS_MODULE_PATH])dnl -+AC_REQUIRE([LT_SYS_DLSEARCH_PATH])dnl -+AC_REQUIRE([LT_LIB_DLLOAD])dnl -+AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl -+AC_REQUIRE([LT_FUNC_DLSYM_USCORE])dnl -+AC_REQUIRE([LT_SYS_DLOPEN_DEPLIBS])dnl -+AC_REQUIRE([gl_FUNC_ARGZ])dnl -+ -+m4_require([_LT_CHECK_OBJDIR])dnl -+m4_require([_LT_HEADER_DLFCN])dnl -+m4_require([_LT_CHECK_DLPREOPEN])dnl -+m4_require([_LT_DECL_SED])dnl -+ -+dnl Don't require this, or it will be expanded earlier than the code -+dnl that sets the variables it relies on: -+_LT_ENABLE_INSTALL -+ -+dnl _LTDL_MODE specific code must be called at least once: -+_LTDL_MODE_DISPATCH -+ -+# In order that ltdl.c can compile, find out the first AC_CONFIG_HEADERS -+# the user used. This is so that ltdl.h can pick up the parent projects -+# config.h file, The first file in AC_CONFIG_HEADERS must contain the -+# definitions required by ltdl.c. -+# FIXME: Remove use of undocumented AC_LIST_HEADERS (2.59 compatibility). -+AC_CONFIG_COMMANDS_PRE([dnl -+m4_pattern_allow([^LT_CONFIG_H$])dnl -+m4_ifset([AH_HEADER], -+ [LT_CONFIG_H=AH_HEADER], -+ [m4_ifset([AC_LIST_HEADERS], -+ [LT_CONFIG_H=`echo "AC_LIST_HEADERS" | $SED 's,^[[ ]]*,,;s,[[ :]].*$,,'`], -+ [])])]) -+AC_SUBST([LT_CONFIG_H]) -+ -+AC_CHECK_HEADERS([unistd.h dl.h sys/dl.h dld.h mach-o/dyld.h dirent.h], -+ [], [], [AC_INCLUDES_DEFAULT]) -+ -+AC_CHECK_FUNCS([closedir opendir readdir], [], [AC_LIBOBJ([lt__dirent])]) -+AC_CHECK_FUNCS([strlcat strlcpy], [], [AC_LIBOBJ([lt__strl])]) -+ -+AC_DEFINE_UNQUOTED([LT_LIBEXT],["$libext"],[The archive extension]) -+ -+name=ltdl -+LTDLOPEN=`eval "\\$ECHO \"$libname_spec\""` -+AC_SUBST([LTDLOPEN]) -+])# _LTDL_SETUP -+ -+ -+# _LT_ENABLE_INSTALL -+# ------------------ -+m4_define([_LT_ENABLE_INSTALL], -+[AC_ARG_ENABLE([ltdl-install], -+ [AS_HELP_STRING([--enable-ltdl-install], [install libltdl])]) -+ -+case ,${enable_ltdl_install},${enable_ltdl_convenience} in -+ *yes*) ;; -+ *) enable_ltdl_convenience=yes ;; -+esac -+ -+m4_ifdef([AM_CONDITIONAL], -+[AM_CONDITIONAL(INSTALL_LTDL, test x"${enable_ltdl_install-no}" != xno) -+ AM_CONDITIONAL(CONVENIENCE_LTDL, test x"${enable_ltdl_convenience-no}" != xno)]) -+])# _LT_ENABLE_INSTALL -+ -+ -+# LT_SYS_DLOPEN_DEPLIBS -+# --------------------- -+AC_DEFUN([LT_SYS_DLOPEN_DEPLIBS], -+[AC_REQUIRE([AC_CANONICAL_HOST])dnl -+AC_CACHE_CHECK([whether deplibs are loaded by dlopen], -+ [lt_cv_sys_dlopen_deplibs], -+ [# PORTME does your system automatically load deplibs for dlopen? -+ # or its logical equivalent (e.g. shl_load for HP-UX < 11) -+ # For now, we just catch OSes we know something about -- in the -+ # future, we'll try test this programmatically. -+ lt_cv_sys_dlopen_deplibs=unknown -+ case $host_os in -+ aix3*|aix4.1.*|aix4.2.*) -+ # Unknown whether this is true for these versions of AIX, but -+ # we want this `case' here to explicitly catch those versions. -+ lt_cv_sys_dlopen_deplibs=unknown -+ ;; -+ aix[[4-9]]*) -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ amigaos*) -+ case $host_cpu in -+ powerpc) -+ lt_cv_sys_dlopen_deplibs=no -+ ;; -+ esac -+ ;; -+ darwin*) -+ # Assuming the user has installed a libdl from somewhere, this is true -+ # If you are looking for one http://www.opendarwin.org/projects/dlcompat -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ freebsd* | dragonfly*) -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ gnu* | linux* | k*bsd*-gnu) -+ # GNU and its variants, using gnu ld.so (Glibc) -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ hpux10*|hpux11*) -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ interix*) -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ irix[[12345]]*|irix6.[[01]]*) -+ # Catch all versions of IRIX before 6.2, and indicate that we don't -+ # know how it worked for any of those versions. -+ lt_cv_sys_dlopen_deplibs=unknown -+ ;; -+ irix*) -+ # The case above catches anything before 6.2, and it's known that -+ # at 6.2 and later dlopen does load deplibs. -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ netbsd*) -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ openbsd*) -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ osf[[1234]]*) -+ # dlopen did load deplibs (at least at 4.x), but until the 5.x series, -+ # it did *not* use an RPATH in a shared library to find objects the -+ # library depends on, so we explicitly say `no'. -+ lt_cv_sys_dlopen_deplibs=no -+ ;; -+ osf5.0|osf5.0a|osf5.1) -+ # dlopen *does* load deplibs and with the right loader patch applied -+ # it even uses RPATH in a shared library to search for shared objects -+ # that the library depends on, but there's no easy way to know if that -+ # patch is installed. Since this is the case, all we can really -+ # say is unknown -- it depends on the patch being installed. If -+ # it is, this changes to `yes'. Without it, it would be `no'. -+ lt_cv_sys_dlopen_deplibs=unknown -+ ;; -+ osf*) -+ # the two cases above should catch all versions of osf <= 5.1. Read -+ # the comments above for what we know about them. -+ # At > 5.1, deplibs are loaded *and* any RPATH in a shared library -+ # is used to find them so we can finally say `yes'. -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ qnx*) -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ solaris*) -+ lt_cv_sys_dlopen_deplibs=yes -+ ;; -+ sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) -+ libltdl_cv_sys_dlopen_deplibs=yes -+ ;; -+ esac -+ ]) -+if test "$lt_cv_sys_dlopen_deplibs" != yes; then -+ AC_DEFINE([LTDL_DLOPEN_DEPLIBS], [1], -+ [Define if the OS needs help to load dependent libraries for dlopen().]) -+fi -+])# LT_SYS_DLOPEN_DEPLIBS -+ -+# Old name: -+AU_ALIAS([AC_LTDL_SYS_DLOPEN_DEPLIBS], [LT_SYS_DLOPEN_DEPLIBS]) -+dnl aclocal-1.4 backwards compatibility: -+dnl AC_DEFUN([AC_LTDL_SYS_DLOPEN_DEPLIBS], []) -+ -+ -+# LT_SYS_MODULE_EXT -+# ----------------- -+AC_DEFUN([LT_SYS_MODULE_EXT], -+[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl -+AC_CACHE_CHECK([which extension is used for runtime loadable modules], -+ [libltdl_cv_shlibext], -+[ -+module=yes -+eval libltdl_cv_shlibext=$shrext_cmds -+ ]) -+if test -n "$libltdl_cv_shlibext"; then -+ m4_pattern_allow([LT_MODULE_EXT])dnl -+ AC_DEFINE_UNQUOTED([LT_MODULE_EXT], ["$libltdl_cv_shlibext"], -+ [Define to the extension used for runtime loadable modules, say, ".so".]) -+fi -+])# LT_SYS_MODULE_EXT -+ -+# Old name: -+AU_ALIAS([AC_LTDL_SHLIBEXT], [LT_SYS_MODULE_EXT]) -+dnl aclocal-1.4 backwards compatibility: -+dnl AC_DEFUN([AC_LTDL_SHLIBEXT], []) -+ -+ -+# LT_SYS_MODULE_PATH -+# ------------------ -+AC_DEFUN([LT_SYS_MODULE_PATH], -+[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl -+AC_CACHE_CHECK([which variable specifies run-time module search path], -+ [lt_cv_module_path_var], [lt_cv_module_path_var="$shlibpath_var"]) -+if test -n "$lt_cv_module_path_var"; then -+ m4_pattern_allow([LT_MODULE_PATH_VAR])dnl -+ AC_DEFINE_UNQUOTED([LT_MODULE_PATH_VAR], ["$lt_cv_module_path_var"], -+ [Define to the name of the environment variable that determines the run-time module search path.]) -+fi -+])# LT_SYS_MODULE_PATH -+ -+# Old name: -+AU_ALIAS([AC_LTDL_SHLIBPATH], [LT_SYS_MODULE_PATH]) -+dnl aclocal-1.4 backwards compatibility: -+dnl AC_DEFUN([AC_LTDL_SHLIBPATH], []) -+ -+ -+# LT_SYS_DLSEARCH_PATH -+# -------------------- -+AC_DEFUN([LT_SYS_DLSEARCH_PATH], -+[m4_require([_LT_SYS_DYNAMIC_LINKER])dnl -+AC_CACHE_CHECK([for the default library search path], -+ [lt_cv_sys_dlsearch_path], -+ [lt_cv_sys_dlsearch_path="$sys_lib_dlsearch_path_spec"]) -+if test -n "$lt_cv_sys_dlsearch_path"; then -+ sys_dlsearch_path= -+ for dir in $lt_cv_sys_dlsearch_path; do -+ if test -z "$sys_dlsearch_path"; then -+ sys_dlsearch_path="$dir" -+ else -+ sys_dlsearch_path="$sys_dlsearch_path$PATH_SEPARATOR$dir" -+ fi -+ done -+ m4_pattern_allow([LT_DLSEARCH_PATH])dnl -+ AC_DEFINE_UNQUOTED([LT_DLSEARCH_PATH], ["$sys_dlsearch_path"], -+ [Define to the system default library search path.]) -+fi -+])# LT_SYS_DLSEARCH_PATH -+ -+# Old name: -+AU_ALIAS([AC_LTDL_SYSSEARCHPATH], [LT_SYS_DLSEARCH_PATH]) -+dnl aclocal-1.4 backwards compatibility: -+dnl AC_DEFUN([AC_LTDL_SYSSEARCHPATH], []) -+ -+ -+# _LT_CHECK_DLPREOPEN -+# ------------------- -+m4_defun([_LT_CHECK_DLPREOPEN], -+[m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -+AC_CACHE_CHECK([whether libtool supports -dlopen/-dlpreopen], -+ [libltdl_cv_preloaded_symbols], -+ [if test -n "$lt_cv_sys_global_symbol_pipe"; then -+ libltdl_cv_preloaded_symbols=yes -+ else -+ libltdl_cv_preloaded_symbols=no -+ fi -+ ]) -+if test x"$libltdl_cv_preloaded_symbols" = xyes; then -+ AC_DEFINE([HAVE_PRELOADED_SYMBOLS], [1], -+ [Define if libtool can extract symbol lists from object files.]) -+fi -+])# _LT_CHECK_DLPREOPEN -+ -+ -+# LT_LIB_DLLOAD -+# ------------- -+AC_DEFUN([LT_LIB_DLLOAD], -+[m4_pattern_allow([^LT_DLLOADERS$]) -+LT_DLLOADERS= -+AC_SUBST([LT_DLLOADERS]) -+ -+AC_LANG_PUSH([C]) -+ -+LIBADD_DLOPEN= -+AC_SEARCH_LIBS([dlopen], [dl], -+ [AC_DEFINE([HAVE_LIBDL], [1], -+ [Define if you have the libdl library or equivalent.]) -+ if test "$ac_cv_search_dlopen" != "none required" ; then -+ LIBADD_DLOPEN="-ldl" -+ fi -+ libltdl_cv_lib_dl_dlopen="yes" -+ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"], -+ [AC_LINK_IFELSE([AC_LANG_PROGRAM([[#if HAVE_DLFCN_H -+# include -+#endif -+ ]], [[dlopen(0, 0);]])], -+ [AC_DEFINE([HAVE_LIBDL], [1], -+ [Define if you have the libdl library or equivalent.]) -+ libltdl_cv_func_dlopen="yes" -+ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"], -+ [AC_CHECK_LIB([svld], [dlopen], -+ [AC_DEFINE([HAVE_LIBDL], [1], -+ [Define if you have the libdl library or equivalent.]) -+ LIBADD_DLOPEN="-lsvld" libltdl_cv_func_dlopen="yes" -+ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dlopen.la"])])]) -+if test x"$libltdl_cv_func_dlopen" = xyes || test x"$libltdl_cv_lib_dl_dlopen" = xyes -+then -+ lt_save_LIBS="$LIBS" -+ LIBS="$LIBS $LIBADD_DLOPEN" -+ AC_CHECK_FUNCS([dlerror]) -+ LIBS="$lt_save_LIBS" -+fi -+AC_SUBST([LIBADD_DLOPEN]) -+ -+LIBADD_SHL_LOAD= -+AC_CHECK_FUNC([shl_load], -+ [AC_DEFINE([HAVE_SHL_LOAD], [1], -+ [Define if you have the shl_load function.]) -+ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la"], -+ [AC_CHECK_LIB([dld], [shl_load], -+ [AC_DEFINE([HAVE_SHL_LOAD], [1], -+ [Define if you have the shl_load function.]) -+ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}shl_load.la" -+ LIBADD_SHL_LOAD="-ldld"])]) -+AC_SUBST([LIBADD_SHL_LOAD]) -+ -+case $host_os in -+darwin[[1567]].*) -+# We only want this for pre-Mac OS X 10.4. -+ AC_CHECK_FUNC([_dyld_func_lookup], -+ [AC_DEFINE([HAVE_DYLD], [1], -+ [Define if you have the _dyld_func_lookup function.]) -+ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dyld.la"]) -+ ;; -+beos*) -+ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}load_add_on.la" -+ ;; -+cygwin* | mingw* | os2* | pw32*) -+ AC_CHECK_DECLS([cygwin_conv_path], [], [], [[#include ]]) -+ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}loadlibrary.la" -+ ;; -+esac -+ -+AC_CHECK_LIB([dld], [dld_link], -+ [AC_DEFINE([HAVE_DLD], [1], -+ [Define if you have the GNU dld library.]) -+ LT_DLLOADERS="$LT_DLLOADERS ${lt_dlopen_dir+$lt_dlopen_dir/}dld_link.la"]) -+AC_SUBST([LIBADD_DLD_LINK]) -+ -+m4_pattern_allow([^LT_DLPREOPEN$]) -+LT_DLPREOPEN= -+if test -n "$LT_DLLOADERS" -+then -+ for lt_loader in $LT_DLLOADERS; do -+ LT_DLPREOPEN="$LT_DLPREOPEN-dlpreopen $lt_loader " -+ done -+ AC_DEFINE([HAVE_LIBDLLOADER], [1], -+ [Define if libdlloader will be built on this platform]) -+fi -+AC_SUBST([LT_DLPREOPEN]) -+ -+dnl This isn't used anymore, but set it for backwards compatibility -+LIBADD_DL="$LIBADD_DLOPEN $LIBADD_SHL_LOAD" -+AC_SUBST([LIBADD_DL]) -+ -+AC_LANG_POP -+])# LT_LIB_DLLOAD -+ -+# Old name: -+AU_ALIAS([AC_LTDL_DLLIB], [LT_LIB_DLLOAD]) -+dnl aclocal-1.4 backwards compatibility: -+dnl AC_DEFUN([AC_LTDL_DLLIB], []) -+ -+ -+# LT_SYS_SYMBOL_USCORE -+# -------------------- -+# does the compiler prefix global symbols with an underscore? -+AC_DEFUN([LT_SYS_SYMBOL_USCORE], -+[m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl -+AC_CACHE_CHECK([for _ prefix in compiled symbols], -+ [lt_cv_sys_symbol_underscore], -+ [lt_cv_sys_symbol_underscore=no -+ cat > conftest.$ac_ext <<_LT_EOF -+void nm_test_func(){} -+int main(){nm_test_func;return 0;} -+_LT_EOF -+ if AC_TRY_EVAL(ac_compile); then -+ # Now try to grab the symbols. -+ ac_nlist=conftest.nm -+ if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist) && test -s "$ac_nlist"; then -+ # See whether the symbols have a leading underscore. -+ if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then -+ lt_cv_sys_symbol_underscore=yes -+ else -+ if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then -+ : -+ else -+ echo "configure: cannot find nm_test_func in $ac_nlist" >&AS_MESSAGE_LOG_FD -+ fi -+ fi -+ else -+ echo "configure: cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD -+ fi -+ else -+ echo "configure: failed program was:" >&AS_MESSAGE_LOG_FD -+ cat conftest.c >&AS_MESSAGE_LOG_FD -+ fi -+ rm -rf conftest* -+ ]) -+ sys_symbol_underscore=$lt_cv_sys_symbol_underscore -+ AC_SUBST([sys_symbol_underscore]) -+])# LT_SYS_SYMBOL_USCORE -+ -+# Old name: -+AU_ALIAS([AC_LTDL_SYMBOL_USCORE], [LT_SYS_SYMBOL_USCORE]) -+dnl aclocal-1.4 backwards compatibility: -+dnl AC_DEFUN([AC_LTDL_SYMBOL_USCORE], []) -+ -+ -+# LT_FUNC_DLSYM_USCORE -+# -------------------- -+AC_DEFUN([LT_FUNC_DLSYM_USCORE], -+[AC_REQUIRE([LT_SYS_SYMBOL_USCORE])dnl -+if test x"$lt_cv_sys_symbol_underscore" = xyes; then -+ if test x"$libltdl_cv_func_dlopen" = xyes || -+ test x"$libltdl_cv_lib_dl_dlopen" = xyes ; then -+ AC_CACHE_CHECK([whether we have to add an underscore for dlsym], -+ [libltdl_cv_need_uscore], -+ [libltdl_cv_need_uscore=unknown -+ save_LIBS="$LIBS" -+ LIBS="$LIBS $LIBADD_DLOPEN" -+ _LT_TRY_DLOPEN_SELF( -+ [libltdl_cv_need_uscore=no], [libltdl_cv_need_uscore=yes], -+ [], [libltdl_cv_need_uscore=cross]) -+ LIBS="$save_LIBS" -+ ]) -+ fi -+fi -+ -+if test x"$libltdl_cv_need_uscore" = xyes; then -+ AC_DEFINE([NEED_USCORE], [1], -+ [Define if dlsym() requires a leading underscore in symbol names.]) -+fi -+])# LT_FUNC_DLSYM_USCORE -+ -+# Old name: -+AU_ALIAS([AC_LTDL_DLSYM_USCORE], [LT_FUNC_DLSYM_USCORE]) -+dnl aclocal-1.4 backwards compatibility: -+dnl AC_DEFUN([AC_LTDL_DLSYM_USCORE], []) -+ - # Helper functions for option handling. -*- Autoconf -*- - # - # Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. -diff --git a/configure b/configure -index da1cb4d..e086c65 100755 ---- a/configure -+++ b/configure -@@ -795,6 +795,7 @@ FFI_DEBUG_FALSE - FFI_DEBUG_TRUE - TARGETDIR - TARGET -+sys_symbol_underscore - HAVE_LONG_DOUBLE - ALLOCA - PA64_HPUX_FALSE -@@ -4782,13 +4783,13 @@ if test "${lt_cv_nm_interface+set}" = set; then - else - lt_cv_nm_interface="BSD nm" - echo "int some_variable = 0;" > conftest.$ac_ext -- (eval echo "\"\$as_me:4785: $ac_compile\"" >&5) -+ (eval echo "\"\$as_me:4786: $ac_compile\"" >&5) - (eval "$ac_compile" 2>conftest.err) - cat conftest.err >&5 -- (eval echo "\"\$as_me:4788: $NM \\\"conftest.$ac_objext\\\"\"" >&5) -+ (eval echo "\"\$as_me:4789: $NM \\\"conftest.$ac_objext\\\"\"" >&5) - (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) - cat conftest.err >&5 -- (eval echo "\"\$as_me:4791: output\"" >&5) -+ (eval echo "\"\$as_me:4792: output\"" >&5) - cat conftest.out >&5 - if $GREP 'External.*some_variable' conftest.out > /dev/null; then - lt_cv_nm_interface="MS dumpbin" -@@ -5994,7 +5995,7 @@ ia64-*-hpux*) - ;; - *-*-irix6*) - # Find out which ABI we are using. -- echo '#line 5997 "configure"' > conftest.$ac_ext -+ echo '#line 5998 "configure"' > conftest.$ac_ext - if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 - (eval $ac_compile) 2>&5 - ac_status=$? -@@ -7847,11 +7848,11 @@ else - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` -- (eval echo "\"\$as_me:7850: $lt_compile\"" >&5) -+ (eval echo "\"\$as_me:7851: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 -- echo "$as_me:7854: \$? = $ac_status" >&5 -+ echo "$as_me:7855: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. -@@ -8186,11 +8187,11 @@ else - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` -- (eval echo "\"\$as_me:8189: $lt_compile\"" >&5) -+ (eval echo "\"\$as_me:8190: $lt_compile\"" >&5) - (eval "$lt_compile" 2>conftest.err) - ac_status=$? - cat conftest.err >&5 -- echo "$as_me:8193: \$? = $ac_status" >&5 -+ echo "$as_me:8194: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s "$ac_outfile"; then - # The compiler can only warn and ignore the option if not recognized - # So say no if there are warnings other than the usual output. -@@ -8291,11 +8292,11 @@ else - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` -- (eval echo "\"\$as_me:8294: $lt_compile\"" >&5) -+ (eval echo "\"\$as_me:8295: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 -- echo "$as_me:8298: \$? = $ac_status" >&5 -+ echo "$as_me:8299: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized -@@ -8346,11 +8347,11 @@ else - -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ - -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ - -e 's:$: $lt_compiler_flag:'` -- (eval echo "\"\$as_me:8349: $lt_compile\"" >&5) -+ (eval echo "\"\$as_me:8350: $lt_compile\"" >&5) - (eval "$lt_compile" 2>out/conftest.err) - ac_status=$? - cat out/conftest.err >&5 -- echo "$as_me:8353: \$? = $ac_status" >&5 -+ echo "$as_me:8354: \$? = $ac_status" >&5 - if (exit $ac_status) && test -s out/conftest2.$ac_objext - then - # The compiler can only warn and ignore the option if not recognized -@@ -11149,7 +11150,7 @@ else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF --#line 11152 "configure" -+#line 11153 "configure" - #include "confdefs.h" - - #if HAVE_DLFCN_H -@@ -11245,7 +11246,7 @@ else - lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 - lt_status=$lt_dlunknown - cat > conftest.$ac_ext <<_LT_EOF --#line 11248 "configure" -+#line 11249 "configure" - #include "confdefs.h" - - #if HAVE_DLFCN_H -@@ -14647,6 +14648,63 @@ _ACEOF - fi - fi - -+if test x$TARGET = xX86_WIN64; then -+ { $as_echo "$as_me:$LINENO: checking for _ prefix in compiled symbols" >&5 -+$as_echo_n "checking for _ prefix in compiled symbols... " >&6; } -+if test "${lt_cv_sys_symbol_underscore+set}" = set; then -+ $as_echo_n "(cached) " >&6 -+else -+ lt_cv_sys_symbol_underscore=no -+ cat > conftest.$ac_ext <<_LT_EOF -+void nm_test_func(){} -+int main(){nm_test_func;return 0;} -+_LT_EOF -+ if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 -+ (eval $ac_compile) 2>&5 -+ ac_status=$? -+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 -+ (exit $ac_status); }; then -+ # Now try to grab the symbols. -+ ac_nlist=conftest.nm -+ if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist\"") >&5 -+ (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $ac_nlist) 2>&5 -+ ac_status=$? -+ $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5 -+ (exit $ac_status); } && test -s "$ac_nlist"; then -+ # See whether the symbols have a leading underscore. -+ if grep '^. _nm_test_func' "$ac_nlist" >/dev/null; then -+ lt_cv_sys_symbol_underscore=yes -+ else -+ if grep '^. nm_test_func ' "$ac_nlist" >/dev/null; then -+ : -+ else -+ echo "configure: cannot find nm_test_func in $ac_nlist" >&5 -+ fi -+ fi -+ else -+ echo "configure: cannot run $lt_cv_sys_global_symbol_pipe" >&5 -+ fi -+ else -+ echo "configure: failed program was:" >&5 -+ cat conftest.c >&5 -+ fi -+ rm -rf conftest* -+ -+fi -+{ $as_echo "$as_me:$LINENO: result: $lt_cv_sys_symbol_underscore" >&5 -+$as_echo "$lt_cv_sys_symbol_underscore" >&6; } -+ sys_symbol_underscore=$lt_cv_sys_symbol_underscore -+ -+ -+ if test "x$sys_symbol_underscore" = xyes; then -+ -+cat >>confdefs.h <<\_ACEOF -+#define SYMBOL_UNDERSCORE 1 -+_ACEOF -+ -+ fi -+fi -+ - case "$target" in - *-apple-darwin10* | *-*-freebsd* | *-*-openbsd* | *-pc-solaris*) - -diff --git a/configure.ac b/configure.ac -index a94bd26..c7cead8 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -314,6 +314,13 @@ if test x$TARGET = xX86 || test x$TARGET = xX86_WIN32 || test x$TARGET = xX86_64 - fi - fi - -+if test x$TARGET = xX86_WIN64; then -+ LT_SYS_SYMBOL_USCORE -+ if test "x$sys_symbol_underscore" = xyes; then -+ AC_DEFINE(SYMBOL_UNDERSCORE, 1, [Define if symbols are underscored.]) -+ fi -+fi -+ - case "$target" in - *-apple-darwin10* | *-*-freebsd* | *-*-openbsd* | *-pc-solaris*) - AC_DEFINE(FFI_MMAP_EXEC_WRIT, 1, -diff --git a/src/x86/win64.S b/src/x86/win64.S -index 6e91818..fcdb270 100644 ---- a/src/x86/win64.S -+++ b/src/x86/win64.S -@@ -232,10 +232,18 @@ ret_void$: - ffi_call_win64 ENDP - _TEXT ENDS - END --#else -+ -+#else -+ -+#ifdef SYMBOL_UNDERSCORE -+#define SYMBOL_NAME(name) _##name -+#else -+#define SYMBOL_NAME(name) name -+#endif -+ - .text - --.extern _ffi_closure_win64_inner -+.extern SYMBOL_NAME(ffi_closure_win64_inner) - - # ffi_closure_win64 will be called with these registers set: - # rax points to 'closure' -@@ -246,8 +254,8 @@ END - # call ffi_closure_win64_inner for the actual work, then return the result. - # - .balign 16 -- .globl _ffi_closure_win64 --_ffi_closure_win64: -+ .globl SYMBOL_NAME(ffi_closure_win64) -+SYMBOL_NAME(ffi_closure_win64): - # copy register arguments onto stack - test $1,%r11 - jne .Lfirst_is_float -@@ -287,7 +295,7 @@ _ffi_closure_win64: - mov %rax, %rcx # context is first parameter - mov %rsp, %rdx # stack is second parameter - add $48, %rdx # point to start of arguments -- mov $_ffi_closure_win64_inner, %rax -+ mov $SYMBOL_NAME(ffi_closure_win64_inner), %rax - callq *%rax # call the real closure function - add $40, %rsp - movq %rax, %xmm0 # If the closure returned a float, -@@ -296,8 +304,8 @@ _ffi_closure_win64: - .ffi_closure_win64_end: - - .balign 16 -- .globl _ffi_call_win64 --_ffi_call_win64: -+ .globl SYMBOL_NAME(ffi_call_win64) -+SYMBOL_NAME(ffi_call_win64): - # copy registers onto stack - mov %r9,32(%rsp) - mov %r8,24(%rsp) From f26d1635db3c600aa4d338e2d589a983954e63b6 Mon Sep 17 00:00:00 2001 From: Jonathan Watt Date: Tue, 27 Dec 2011 10:27:42 +0000 Subject: [PATCH 21/28] Bug 668163 - Map 'width' and 'height' on into style to stop 's computed width/height falling back to 150px x 300px when they're set to explicit percentage values that can be resolved (regression from bug 611099). r=dbaron. --- content/svg/content/src/nsSVGElement.cpp | 32 ++++++++++++ content/svg/content/src/nsSVGElement.h | 1 + content/svg/content/src/nsSVGLength2.h | 3 ++ content/svg/content/src/nsSVGSVGElement.cpp | 14 +++++ .../dynamic--inline-resize-cb-height.xhtml | 52 ------------------- .../dynamic--inline-resize-cb-width.xhtml | 52 ------------------- layout/reftests/svg/sizing/reftest.list | 4 -- layout/svg/crashtests/crashtests.list | 2 +- 8 files changed, 51 insertions(+), 109 deletions(-) delete mode 100644 layout/reftests/svg/sizing/dynamic--inline-resize-cb-height.xhtml delete mode 100644 layout/reftests/svg/sizing/dynamic--inline-resize-cb-width.xhtml diff --git a/content/svg/content/src/nsSVGElement.cpp b/content/svg/content/src/nsSVGElement.cpp index 0cd36c78fa5..4c63589d538 100644 --- a/content/svg/content/src/nsSVGElement.cpp +++ b/content/svg/content/src/nsSVGElement.cpp @@ -1112,6 +1112,24 @@ nsSVGElement::UpdateContentStyleRule() if (!attrName->IsAtom() || !IsAttributeMapped(attrName->Atom())) continue; + if (Tag() == nsGkAtoms::svg) { + // Special case: we don't want 'width'/'height' mapped into style + // if the attribute value isn't a valid according to SVG (which + // only supports a subset of the CSS values). We don't enforce + // this by checking the attribute value in nsSVGSVGElement:: + // IsAttributeMapped since we don't want that method to depend on the + // value of the attribute that is being checked. Rather we just prevent + // the actual mapping here, as necessary. + if (attrName->Atom() == nsGkAtoms::width && + !GetAnimatedLength(nsGkAtoms::width)->HasBaseVal()) { + continue; + } + if (attrName->Atom() == nsGkAtoms::height && + !GetAnimatedLength(nsGkAtoms::height)->HasBaseVal()) { + continue; + } + } + nsAutoString value; mAttrsAndChildren.AttrAt(i)->ToString(value); mappedAttrParser.ParseMappedAttrValue(attrName->Atom(), value); @@ -1314,6 +1332,20 @@ nsSVGElement::DidAnimateLength(PRUint8 aAttrEnum) } } +nsSVGLength2* +nsSVGElement::GetAnimatedLength(const nsIAtom *aAttrName) +{ + LengthAttributesInfo lengthInfo = GetLengthInfo(); + + for (PRUint32 i = 0; i < lengthInfo.mLengthCount; i++) { + if (aAttrName == *lengthInfo.mLengthInfo[i].mName) { + return &lengthInfo.mLengths[i]; + } + } + NS_ABORT_IF_FALSE(false, "no matching length found"); + return nsnull; +} + void nsSVGElement::GetAnimatedLengthValues(float *aFirst, ...) { diff --git a/content/svg/content/src/nsSVGElement.h b/content/svg/content/src/nsSVGElement.h index 1965e4348dd..37c62f4b548 100644 --- a/content/svg/content/src/nsSVGElement.h +++ b/content/svg/content/src/nsSVGElement.h @@ -195,6 +195,7 @@ public: virtual void DidAnimateTransformList(); virtual void DidAnimateString(PRUint8 aAttrEnum); + nsSVGLength2* GetAnimatedLength(const nsIAtom *aAttrName); void GetAnimatedLengthValues(float *aFirst, ...); void GetAnimatedNumberValues(float *aFirst, ...); void GetAnimatedIntegerValues(PRInt32 *aFirst, ...); diff --git a/content/svg/content/src/nsSVGLength2.h b/content/svg/content/src/nsSVGLength2.h index a2e557463e6..3852e4b97c6 100644 --- a/content/svg/content/src/nsSVGLength2.h +++ b/content/svg/content/src/nsSVGLength2.h @@ -100,6 +100,9 @@ public: float GetAnimValue(nsSVGSVGElement* aCtx) const { return mAnimVal / GetUnitScaleFactor(aCtx, mSpecifiedUnitType); } + bool HasBaseVal() const { + return mIsBaseSet; + } // Returns true if the animated value of this length has been explicitly // set (either by animation, or by taking on the base value which has been // explicitly set by markup or a DOM call), false otherwise. diff --git a/content/svg/content/src/nsSVGSVGElement.cpp b/content/svg/content/src/nsSVGSVGElement.cpp index 52ebd6b1d7f..5206ac476ee 100644 --- a/content/svg/content/src/nsSVGSVGElement.cpp +++ b/content/svg/content/src/nsSVGSVGElement.cpp @@ -883,6 +883,20 @@ nsSVGSVGElement::GetTimedDocumentRoot() NS_IMETHODIMP_(bool) nsSVGSVGElement::IsAttributeMapped(const nsIAtom* name) const { + // We want to map the 'width' and 'height' attributes into style for + // outer-, except when the attributes aren't set (since their default + // values of '100%' can cause unexpected and undesirable behaviour for SVG + // inline in HTML). We rely on nsSVGElement::UpdateContentStyleRule() to + // prevent mapping of the default values into style (it only maps attributes + // that are set). We also rely on a check in nsSVGElement:: + // UpdateContentStyleRule() to prevent us mapping the attributes when they're + // given a value that is not currently recognized by the SVG + // specification. + + if (!IsInner() && (name == nsGkAtoms::width || name == nsGkAtoms::height)) { + return true; + } + static const MappedAttributeEntry* const map[] = { sColorMap, sFEFloodMap, diff --git a/layout/reftests/svg/sizing/dynamic--inline-resize-cb-height.xhtml b/layout/reftests/svg/sizing/dynamic--inline-resize-cb-height.xhtml deleted file mode 100644 index bea695f6afa..00000000000 --- a/layout/reftests/svg/sizing/dynamic--inline-resize-cb-height.xhtml +++ /dev/null @@ -1,52 +0,0 @@ - - - - - - - Test: resize of container block height - - - - - - - - -
- - - -
- - - diff --git a/layout/reftests/svg/sizing/dynamic--inline-resize-cb-width.xhtml b/layout/reftests/svg/sizing/dynamic--inline-resize-cb-width.xhtml deleted file mode 100644 index 1d0ff495b85..00000000000 --- a/layout/reftests/svg/sizing/dynamic--inline-resize-cb-width.xhtml +++ /dev/null @@ -1,52 +0,0 @@ - - - - - - - Test: resize of container block width - - - - - - - - -
- - - -
- - - diff --git a/layout/reftests/svg/sizing/reftest.list b/layout/reftests/svg/sizing/reftest.list index 40016067607..0ebf116bc6d 100644 --- a/layout/reftests/svg/sizing/reftest.list +++ b/layout/reftests/svg/sizing/reftest.list @@ -303,10 +303,6 @@ random-if(Android) == object--auto-auto--px-px.html object--auto-auto--px == dynamic--inline-css-height.xhtml pass.svg == dynamic--inline-css-width.xhtml pass.svg -# These two don't have a whole lot of point anymore now that the meaning -# of percentages has changed. -== dynamic--inline-resize-cb-height.xhtml standalone-sanity-height-150px.svg -== dynamic--inline-resize-cb-width.xhtml standalone-sanity-width-300px.svg skip == dynamic--inline-resize-window-height.xhtml pass.svg # XXX breaks the reftest run as the window height somehow is not restored skip == dynamic--inline-resize-window-width.xhtml pass.svg # Fails way too much fails random-if(Android) == dynamic--object-svg-unloaded.xhtml pass.svg diff --git a/layout/svg/crashtests/crashtests.list b/layout/svg/crashtests/crashtests.list index 34a81991a03..7b7c6f76dc7 100644 --- a/layout/svg/crashtests/crashtests.list +++ b/layout/svg/crashtests/crashtests.list @@ -59,7 +59,7 @@ load 385552-2.svg load 385840-1.svg load 385852-1.svg load 386475-1.xhtml -load 386566-1.svg +asserts(1) load 386566-1.svg # Bug 713626 load 386690-1.svg load 387290-1.svg load 402408-1.svg From 2547cf23951c41cd2315c59de8b4a391ffb0696b Mon Sep 17 00:00:00 2001 From: Geoff Lankow Date: Wed, 2 Nov 2011 14:05:50 +1300 Subject: [PATCH 22/28] Bug 246620 - Add line numbers to View Source for Firefox; r=ehsan --- layout/style/viewsource.css | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/layout/style/viewsource.css b/layout/style/viewsource.css index 72ee55861b9..0483c766f8d 100644 --- a/layout/style/viewsource.css +++ b/layout/style/viewsource.css @@ -21,6 +21,7 @@ * * Contributor(s): * Blake Ross + * Geoff Lankow * * Alternatively, the contents of this file may be used under the terms of * either of the GNU General Public License Version 2 or later (the "GPL"), @@ -47,6 +48,7 @@ font-family: -moz-fixed; font-weight: normal; white-space: pre; + counter-reset: line; } #viewsource.wrap { white-space: pre-wrap; @@ -56,7 +58,20 @@ pre { font: inherit; color: inherit; white-space: inherit; - margin: 0; + margin: 0 0 0 5ch; +} +pre[id]:before, +span[id]:before { + content: counter(line) " "; + counter-increment: line; + -moz-user-select: none; + display: inline-block; + width: 5ch; + margin: 0 0 0 -5ch; + text-align: right; + color: #ccc; + font-weight: normal; + font-style: normal; } .start-tag { color: purple; From 61b3e201c6ff17ac57934a3bb9f248a53168f7c8 Mon Sep 17 00:00:00 2001 From: Geoff Lankow Date: Wed, 28 Dec 2011 00:21:53 +1300 Subject: [PATCH 23/28] Bug 246620 - Add line numbers to View Source for Firefox - fix for reftests; r=smaug --- .../tests/reftest/bug482921-1-ref.html | 51 +++++++++--------- .../tests/reftest/bug482921-2-ref.html | 53 ++++++++++--------- .../tests/reftest/bug535530-2-ref.html | 30 ++++++----- .../tests/reftest/bug704667-1-ref.html | 5 +- 4 files changed, 76 insertions(+), 63 deletions(-) diff --git a/parser/htmlparser/tests/reftest/bug482921-1-ref.html b/parser/htmlparser/tests/reftest/bug482921-1-ref.html index 60d310a8a75..72c546e7b9d 100644 --- a/parser/htmlparser/tests/reftest/bug482921-1-ref.html +++ b/parser/htmlparser/tests/reftest/bug482921-1-ref.html @@ -1,24 +1,27 @@ -<!DOCTYPE html> -<html> -<head> -<title>Title</title> -<script> -var lt = "<"; -<!-- -var s = "<script>foo</script>"; ---> -</script><!-- Not quite optimal highlight there. --> -<style> -/* </foo> */ -</style> -</head> -<body> -<p>Entity: &amp; </p> -<iframe><img></iframe> -<noscript><p>Not para</p></noscript> -<svg> -<title><![CDATA[bar]]></title> -<script><!-- this is a comment --></script> -</svg> -</body> -</html> +
<!DOCTYPE html>
+<html>
+<head>
+<title>Title</title>
+<script>
+var lt = "<";
+<!--
+var s = "<script>foo</script>";
+-->
+</script><!-- Not quite optimal highlight there. -->
+<style>
+/* </foo> */
+</style>
+</head>
+<body>
+<p>Entity: &amp; </p>
+<iframe><img></iframe>
+<noscript><p>Not para</p></noscript>
+<svg>
+<title><![CDATA[bar]]></title>
+<script><!-- this is a comment --></script>
+</svg>
+</body>
+</html>
+
+
+ diff --git a/parser/htmlparser/tests/reftest/bug482921-2-ref.html b/parser/htmlparser/tests/reftest/bug482921-2-ref.html index 1734e15d02a..e2e92164582 100644 --- a/parser/htmlparser/tests/reftest/bug482921-2-ref.html +++ b/parser/htmlparser/tests/reftest/bug482921-2-ref.html @@ -1,25 +1,28 @@ -<?xml version="1.0" encoding="utf-8"?> -<?foo bar?> -<html> -<head> -<title>Title</title> -<script> -var s = "<script>foo</script>"; -<!-- -var s = "<script>foo</script>"; ---> -</script> -<style> -/* <foo/> */ -</style> -</head> -<body> -<p>Entity: &amp; </p> -<iframe><img></iframe> -<noscript><p>Not para</p></noscript> -<svg> -<title><![CDATA[bar]]></title> -<script><!-- this is a comment --></script> -</svg> -</body> -</html> +
<?xml version="1.0" encoding="utf-8"?>
+<?foo bar?>
+<html>
+<head>
+<title>Title</title>
+<script>
+var s = "<script>foo</script>";
+<!--
+var s = "<script>foo</script>";
+-->
+</script>
+<style>
+/* <foo/> */
+</style>
+</head>
+<body>
+<p>Entity: &amp; </p>
+<iframe><img></iframe>
+<noscript><p>Not para</p></noscript>
+<svg>
+<title><![CDATA[bar]]></title>
+<script><!-- this is a comment --></script>
+</svg>
+</body>
+</html>
+
+
+ diff --git a/parser/htmlparser/tests/reftest/bug535530-2-ref.html b/parser/htmlparser/tests/reftest/bug535530-2-ref.html index 33f40a8624f..636b598979a 100644 --- a/parser/htmlparser/tests/reftest/bug535530-2-ref.html +++ b/parser/htmlparser/tests/reftest/bug535530-2-ref.html @@ -1,13 +1,17 @@ -<!DOCTYPE html> -XX&XX -XX&nXX -XX&noXX -XX&notXX -XX&notiXX -XX&notinXX -XX&;XX -XX&n;XX -XX&no;XX -XX&not;XX -XX&noti;XX -XX&notin;XX +
<!DOCTYPE html>
+XX&XX
+XX&nXX
+XX&noXX
+XX&notXX
+XX&notiXX
+XX&notinXX
+XX&;XX
+XX&n;XX
+XX&no;XX
+XX&not;XX
+XX&noti;XX
+XX&notin;XX
+
+
+
+ diff --git a/parser/htmlparser/tests/reftest/bug704667-1-ref.html b/parser/htmlparser/tests/reftest/bug704667-1-ref.html index a1bc098fd60..8f57e120959 100644 --- a/parser/htmlparser/tests/reftest/bug704667-1-ref.html +++ b/parser/htmlparser/tests/reftest/bug704667-1-ref.html @@ -1 +1,4 @@ -<!--> <!X> +
<!--> <!X>
+
+
+ From 0ae3bace2d7c65b9cd629b776da30f8337df3bf0 Mon Sep 17 00:00:00 2001 From: Geoff Lankow Date: Wed, 28 Dec 2011 01:00:02 +1300 Subject: [PATCH 24/28] Backed out 3 changesets (bug 710297, bug 712386, bug 712761) for perma-orange on Android native m1 and m2 Backed out changeset 3b1e6033d3ff (bug 712761) Backed out changeset bb41941cdf9d (bug 710297) Backed out changeset d4f9960e286a (bug 712386) --- mobile/android/base/ui/PanZoomController.java | 8 ------- mobile/android/chrome/content/browser.js | 22 +++++++------------ 2 files changed, 8 insertions(+), 22 deletions(-) diff --git a/mobile/android/base/ui/PanZoomController.java b/mobile/android/base/ui/PanZoomController.java index 6800252b66b..195816e703b 100644 --- a/mobile/android/base/ui/PanZoomController.java +++ b/mobile/android/base/ui/PanZoomController.java @@ -937,14 +937,6 @@ public class PanZoomController synchronized (mController) { float newZoomFactor = mController.getZoomFactor() * spanRatio; - if (newZoomFactor >= MAX_ZOOM) { - // apply resistance when zooming past MAX_ZOOM, - // such that it asymptotically reaches MAX_ZOOM + 1.0 - // but never exceeds that - float excessZoom = newZoomFactor - MAX_ZOOM; - excessZoom = 1.0f - (float)Math.exp(-excessZoom); - newZoomFactor = MAX_ZOOM + excessZoom; - } mController.scrollBy(new PointF(mLastZoomFocus.x - detector.getFocusX(), mLastZoomFocus.y - detector.getFocusY())); diff --git a/mobile/android/chrome/content/browser.js b/mobile/android/chrome/content/browser.js index 1536127a11f..0a99e94d94b 100644 --- a/mobile/android/chrome/content/browser.js +++ b/mobile/android/chrome/content/browser.js @@ -1085,7 +1085,7 @@ nsBrowserAccess.prototype = { openURI: function browser_openURI(aURI, aOpener, aWhere, aContext) { let browser = this._getBrowser(aURI, aOpener, aWhere, aContext); - return browser ? browser.contentWindow : null; + return browser ? browser.QueryInterface(Ci.nsIFrameLoaderOwner) : null; }, openURIInFrame: function browser_openURIInFrame(aURI, aOpener, aWhere, aContext) { @@ -1338,8 +1338,12 @@ Tab.prototype = { this._viewport.x = Math.round(this._viewport.x * this._viewport.zoom); this._viewport.y = Math.round(this._viewport.y * this._viewport.zoom); + /* + * Don't alter the page size until we hit DOMContentLoaded, because this causes the page size + * to jump around wildly during page load. + */ let doc = this.browser.contentDocument; - if (doc != null) { + if (doc != null && doc.readyState === 'complete') { let pageWidth = this._viewport.width, pageHeight = this._viewport.height; let body = doc.body || { scrollWidth: pageWidth, scrollHeight: pageHeight }; let html = doc.documentElement || { scrollWidth: pageWidth, scrollHeight: pageHeight }; @@ -1347,18 +1351,8 @@ Tab.prototype = { pageHeight = Math.max(body.scrollHeight, html.scrollHeight); /* Transform the page width and height based on the zoom factor. */ - pageWidth = Math.round(pageWidth * this._viewport.zoom); - pageHeight = Math.round(pageHeight * this._viewport.zoom); - - /* - * Avoid sending page sizes of less than screen size before we hit DOMContentLoaded, because - * this causes the page size to jump around wildly during page load. After the page is loaded, - * send updates regardless of page size; we'll zoom to fit the content as needed. - */ - if (doc.readyState === 'complete' || (pageWidth >= gScreenWidth && pageHeight >= gScreenHeight)) { - this._viewport.pageWidth = pageWidth; - this._viewport.pageHeight = pageHeight; - } + this._viewport.pageWidth = Math.round(pageWidth * this._viewport.zoom); + this._viewport.pageHeight = Math.round(pageHeight * this._viewport.zoom); } return this._viewport; From d9ced99e335e80c849a597cb953b02a8d8034254 Mon Sep 17 00:00:00 2001 From: Geoff Lankow Date: Fri, 23 Dec 2011 11:10:52 +1300 Subject: [PATCH 25/28] Bug 712518 - Improve MockFilePicker.jsm; r=jmaher --- .../base/content/test/browser_save_video.js | 4 +- content/html/content/test/test_bug500885.html | 7 ++- content/html/content/test/test_bug592802.html | 3 +- layout/forms/test/test_bug36619.html | 4 +- layout/forms/test/test_bug377624.html | 4 +- layout/forms/test/test_bug536567.html | 4 +- testing/mochitest/MockFilePicker.jsm | 49 +++++++++++++++---- .../browser/browser_save_resend_postdata.js | 4 +- .../test_privatebrowsing_downloadLastDir.js | 4 +- .../test/browser/browser_bug567127.js | 4 +- .../test/browser/browser_inlinesettings.js | 4 +- 11 files changed, 63 insertions(+), 28 deletions(-) diff --git a/browser/base/content/test/browser_save_video.js b/browser/base/content/test/browser_save_video.js index 4e892fbe1c1..14b7f84f618 100644 --- a/browser/base/content/test/browser_save_video.js +++ b/browser/base/content/test/browser_save_video.js @@ -2,7 +2,7 @@ http://creativecommons.org/publicdomain/zero/1.0/ */ var MockFilePicker = SpecialPowers.MockFilePicker; -MockFilePicker.reset(); +MockFilePicker.init(); /** * TestCase for bug 564387 @@ -54,7 +54,7 @@ function test() { registerCleanupFunction(function () { mockTransferRegisterer.unregister(); - MockFilePicker.reset(); + MockFilePicker.cleanup(); destDir.remove(true); }); diff --git a/content/html/content/test/test_bug500885.html b/content/html/content/test/test_bug500885.html index 5361c24da5d..0d9f36aa982 100644 --- a/content/html/content/test/test_bug500885.html +++ b/content/html/content/test/test_bug500885.html @@ -18,7 +18,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=500885