Bug 1036864 - Remove EXPORT_LIBRARY. r=mshal
authorMike Hommey <mh+mozilla@glandium.org>
Fri, 11 Jul 2014 19:06:55 +0900
changeset 193497 d59df02050b3d9e147cb0f82fb9d0bd443c805a6
parent 193496 54cdce960e73eb9f0402fe1126102bc4e474472a
child 193498 c43489001722a791d24c2774475bdcb9582f8d2f
push id46122
push usermh@glandium.org
push dateFri, 11 Jul 2014 10:07:29 +0000
treeherdermozilla-inbound@d59df02050b3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmshal
bugs1036864
milestone33.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1036864 - Remove EXPORT_LIBRARY. r=mshal
config/config.mk
config/makefiles/target_binaries.mk
config/rules.mk
content/media/gtest/moz.build
gfx/tests/gtest/moz.build
ipc/nfc/moz.build
layout/media/Makefile.in
python/mozbuild/mozbuild/frontend/emitter.py
python/mozbuild/mozbuild/frontend/sandbox_symbols.py
python/mozbuild/mozbuild/test/frontend/data/variable-passthru/moz.build
python/mozbuild/mozbuild/test/frontend/test_emitter.py
security/manager/ssl/tests/gtest/Makefile.in
security/sandbox/moz.build
security/sandbox/win/src/sandboxbroker/moz.build
testing/gtest/moz.build
toolkit/components/workerlz4/moz.build
toolkit/library/libxul.mk
tools/jprof/stub/moz.build
tools/profiler/tests/gtest/moz.build
xpcom/glue/tests/gtest/moz.build
--- a/config/config.mk
+++ b/config/config.mk
@@ -69,16 +69,17 @@ endif
   TIERS \
   TOOL_DIRS \
   XPCSHELL_TESTS \
   XPIDL_MODULE \
   $(NULL)
 
 _DEPRECATED_VARIABLES := \
   ANDROID_RESFILES \
+  EXPORT_LIBRARY \
   LIBXUL_LIBRARY \
   MOCHITEST_A11Y_FILES \
   MOCHITEST_BROWSER_FILES \
   MOCHITEST_BROWSER_FILES_PARTS \
   MOCHITEST_CHROME_FILES \
   MOCHITEST_FILES \
   MOCHITEST_FILES_PARTS \
   MOCHITEST_METRO_FILES \
@@ -340,17 +341,16 @@ endif
 endif
 
 # If we are building this component into an extension/xulapp, it cannot be
 # statically linked. In the future we may want to add a xulapp meta-component
 # build option.
 
 ifdef XPI_NAME
 ifdef IS_COMPONENT
-EXPORT_LIBRARY=
 FORCE_STATIC_LIB=
 FORCE_SHARED_LIB=1
 endif
 endif
 
 ifndef SHARED_LIBRARY_NAME
 ifdef LIBRARY_NAME
 SHARED_LIBRARY_NAME=$(LIBRARY_NAME)
--- a/config/makefiles/target_binaries.mk
+++ b/config/makefiles/target_binaries.mk
@@ -1,28 +1,15 @@
 # -*- makefile -*-
 # vim:set ts=8 sw=8 sts=8 noet:
 #
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
-ifdef EXPORT_LIBRARY
-ifeq ($(EXPORT_LIBRARY),1)
-ifdef IS_COMPONENT
-EXPORT_LIBRARY = $(DEPTH)/staticlib/components
-else
-EXPORT_LIBRARY = $(DEPTH)/staticlib
-endif
-else
-# If EXPORT_LIBRARY has a value, we'll be installing there. We also need to cleanup there
-GARBAGE += $(foreach lib,$(LIBRARY),$(EXPORT_LIBRARY)/$(lib))
-endif
-endif # EXPORT_LIBRARY
-
 binaries libs:: $(SUBMAKEFILES) $(TARGETS)
 ifndef NO_DIST_INSTALL
 ifdef SHARED_LIBRARY
 ifdef IS_COMPONENT
 	$(INSTALL) $(IFLAGS2) $(SHARED_LIBRARY) $(FINAL_TARGET)/components
 ifndef NO_COMPONENTS_MANIFEST
 	$(call py_action,buildlist,$(FINAL_TARGET)/chrome.manifest 'manifest components/components.manifest')
 	$(call py_action,buildlist,$(FINAL_TARGET)/components/components.manifest 'binary-component $(SHARED_LIBRARY)')
@@ -36,22 +23,16 @@ ifndef NO_DIST_INSTALL
 ifneq (,$(strip $(PROGRAM)$(SIMPLE_PROGRAMS)))
 PROGRAMS_EXECUTABLES = $(SIMPLE_PROGRAMS) $(PROGRAM)
 PROGRAMS_DEST ?= $(FINAL_TARGET)
 PROGRAMS_TARGET := binaries libs
 INSTALL_TARGETS += PROGRAMS
 endif
 
 ifdef LIBRARY
-ifdef EXPORT_LIBRARY
-LIBRARY_FILES = $(LIBRARY)
-LIBRARY_DEST ?= $(EXPORT_LIBRARY)
-LIBRARY_TARGET = binaries libs
-INSTALL_TARGETS += LIBRARY
-endif
 ifdef DIST_INSTALL
 ifdef IS_COMPONENT
 $(error Shipping static component libs makes no sense.)
 else
 DIST_LIBRARY_FILES = $(LIBRARY)
 DIST_LIBRARY_DEST ?= $(DIST)/lib
 DIST_LIBRARY_TARGET = binaries libs
 INSTALL_TARGETS += DIST_LIBRARY
--- a/config/rules.mk
+++ b/config/rules.mk
@@ -828,17 +828,17 @@ endif
 $(filter %.$(LIB_SUFFIX),$(LIBRARY)): $(OBJS) $(EXTRA_DEPS) $(GLOBAL_DEPS)
 	$(REPORT_BUILD)
 	$(RM) $(LIBRARY)
 	$(EXPAND_AR) $(AR_FLAGS) $(OBJS) $(SHARED_LIBRARY_LIBS)
 
 $(filter-out %.$(LIB_SUFFIX),$(LIBRARY)): $(filter %.$(LIB_SUFFIX),$(LIBRARY)) $(OBJS) $(EXTRA_DEPS) $(GLOBAL_DEPS)
 # When we only build a library descriptor, blow out any existing library
 	$(REPORT_BUILD)
-	$(if $(filter %.$(LIB_SUFFIX),$(LIBRARY)),,$(RM) $(REAL_LIBRARY) $(EXPORT_LIBRARY:%=%/$(REAL_LIBRARY)))
+	$(if $(filter %.$(LIB_SUFFIX),$(LIBRARY)),,$(RM) $(REAL_LIBRARY))
 	$(EXPAND_LIBS_GEN) -o $@ $(OBJS) $(SHARED_LIBRARY_LIBS)
 
 ifeq ($(OS_ARCH),WINNT)
 # Import libraries are created by the rules creating shared libraries.
 # The rules to copy them to $(DIST)/lib depend on $(IMPORT_LIBRARY),
 # but make will happily consider the import library before it is refreshed
 # when rebuilding the corresponding shared library. Defining an empty recipe
 # for import libraries forces make to wait for the shared library recipe to
--- a/content/media/gtest/moz.build
+++ b/content/media/gtest/moz.build
@@ -13,18 +13,16 @@ UNIFIED_SOURCES += [
 ]
 
 if CONFIG['MOZ_WEBM_ENCODER']:
     UNIFIED_SOURCES += ['TestVideoTrackEncoder.cpp',
                         'TestVorbisTrackEncoder.cpp',
                         'TestWebMWriter.cpp',
 ]
 
-EXPORT_LIBRARY = True
-
 include('/ipc/chromium/chromium-config.mozbuild')
 
 LOCAL_INCLUDES += [
     '/content/media/encoder',
 ]
 
 FINAL_LIBRARY = 'xul-gtest'
 
--- a/gfx/tests/gtest/moz.build
+++ b/gfx/tests/gtest/moz.build
@@ -34,18 +34,16 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] != 'wind
         'TestPoint.cpp',
         'TestScaling.cpp',
     ]]
     UNIFIED_SOURCES += [
         'TestMoz2D.cpp',
         'TestRect.cpp',
     ]
 
-EXPORT_LIBRARY = True
-
 include('/ipc/chromium/chromium-config.mozbuild')
 
 LOCAL_INCLUDES += [
     '/gfx/2d',
     '/gfx/2d/unittest',
     '/gfx/layers',
 ]
 
--- a/ipc/nfc/moz.build
+++ b/ipc/nfc/moz.build
@@ -6,15 +6,13 @@
 if CONFIG['MOZ_NFC']:
     EXPORTS.mozilla.ipc += [
         'Nfc.h',
     ]
     SOURCES += [
         'Nfc.cpp',
     ]
 
-EXPORT_LIBRARY = True
-
 include('/ipc/chromium/chromium-config.mozbuild')
 
 FINAL_LIBRARY = 'xul'
 
 FAIL_ON_WARNINGS = True
--- a/layout/media/Makefile.in
+++ b/layout/media/Makefile.in
@@ -1,15 +1,13 @@
 #
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
-EXPORT_LIBRARY	= $(DIST)/lib
-
 ifeq (WINNT,$(OS_TARGET))
 EXTRA_DSO_LDOPTS = $(MOZALLOC_LIB) $(NSPR_LIBS)
 OS_LIBS += $(call EXPAND_LIBNAME,usp10 ole32)
 endif
 
 include $(topsrcdir)/config/rules.mk
 
 ifeq (WINNT,$(OS_TARGET))
--- a/python/mozbuild/mozbuild/frontend/emitter.py
+++ b/python/mozbuild/mozbuild/frontend/emitter.py
@@ -217,17 +217,16 @@ class TreeMetadataEmitter(LoggingMixin):
         # them. We should aim to keep this set small because it violates the
         # desired abstraction of the build definition away from makefiles.
         passthru = VariablePassthru(sandbox)
         varlist = [
             'ANDROID_GENERATED_RESFILES',
             'ANDROID_RES_DIRS',
             'CPP_UNIT_TESTS',
             'DISABLE_STL_WRAPPING',
-            'EXPORT_LIBRARY',
             'EXTRA_ASSEMBLER_FLAGS',
             'EXTRA_COMPILE_FLAGS',
             'EXTRA_COMPONENTS',
             'EXTRA_DSO_LDOPTS',
             'EXTRA_JS_MODULES',
             'EXTRA_PP_COMPONENTS',
             'EXTRA_PP_JS_MODULES',
             'FAIL_ON_WARNINGS',
--- a/python/mozbuild/mozbuild/frontend/sandbox_symbols.py
+++ b/python/mozbuild/mozbuild/frontend/sandbox_symbols.py
@@ -178,20 +178,16 @@ VARIABLES = {
         delimiters.
         """, None),
 
     'DISABLE_STL_WRAPPING': (bool, bool,
         """Disable the wrappers for STL which allow it to work with C++ exceptions
         disabled.
         """, 'binaries'),
 
-    'EXPORT_LIBRARY': (bool, bool,
-        """Install the library to the static libraries folder.
-        """, None),
-
     'EXTRA_COMPONENTS': (StrictOrderingOnAppendList, list,
         """Additional component files to distribute.
 
        This variable contains a list of files to copy into
        ``$(FINAL_TARGET)/components/``.
         """, 'libs'),
 
     'EXTRA_JS_MODULES': (StrictOrderingOnAppendList, list,
--- a/python/mozbuild/mozbuild/test/frontend/data/variable-passthru/moz.build
+++ b/python/mozbuild/mozbuild/test/frontend/data/variable-passthru/moz.build
@@ -30,17 +30,16 @@ SOURCES += ['fans.mm', 'tans.mm']
 SOURCES += ['bans.S', 'fans.S']
 
 FAIL_ON_WARNINGS = True
 MSVC_ENABLE_PGO = True
 
 NO_DIST_INSTALL = True
 
 FORCE_SHARED_LIB = True
-EXPORT_LIBRARY = True
 IS_COMPONENT = True
 NO_VISIBILITY_FLAGS = True
 
 DELAYLOAD_DLLS = ['foo.dll', 'bar.dll']
 
 RCFILE = 'foo.rc'
 RESFILE = 'bar.res'
 RCINCLUDE = 'bar.rc'
--- a/python/mozbuild/mozbuild/test/frontend/test_emitter.py
+++ b/python/mozbuild/mozbuild/test/frontend/test_emitter.py
@@ -155,17 +155,16 @@ class TestEmitterBasic(unittest.TestCase
         self.assertIsInstance(objs[0], VariablePassthru)
 
         wanted = dict(
             ASFILES=['fans.asm', 'tans.s'],
             CMMSRCS=['fans.mm', 'tans.mm'],
             CSRCS=['fans.c', 'tans.c'],
             CPP_UNIT_TESTS=['foo.cpp'],
             DISABLE_STL_WRAPPING=True,
-            EXPORT_LIBRARY=True,
             EXTRA_COMPONENTS=['fans.js', 'tans.js'],
             EXTRA_PP_COMPONENTS=['fans.pp.js', 'tans.pp.js'],
             EXTRA_JS_MODULES=['bar.jsm', 'foo.jsm'],
             EXTRA_PP_JS_MODULES=['bar.pp.jsm', 'foo.pp.jsm'],
             FAIL_ON_WARNINGS=True,
             FORCE_SHARED_LIB=True,
             HOST_CPPSRCS=['fans.cpp', 'tans.cpp'],
             HOST_CSRCS=['fans.c', 'tans.c'],
deleted file mode 100644
--- a/security/manager/ssl/tests/gtest/Makefile.in
+++ /dev/null
@@ -1,11 +0,0 @@
-#! gmake
-# 
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-
-include $(DEPTH)/config/autoconf.mk
-
-EXPORT_LIBRARY = 1
-
-include $(topsrcdir)/config/rules.mk
--- a/security/sandbox/moz.build
+++ b/security/sandbox/moz.build
@@ -5,17 +5,16 @@
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 if CONFIG['OS_ARCH'] == 'Linux':
 
     DIRS += ['linux']
 
 elif CONFIG['OS_ARCH'] == 'WINNT':
     LIBRARY_NAME = 'sandbox_s'
-    EXPORT_LIBRARY = True
     FORCE_STATIC_LIB = True
 
     DIRS += [
         'win/src/sandboxbroker',
         'win/src/sandboxtarget',
     ]
 
     SOURCES += [
--- a/security/sandbox/win/src/sandboxbroker/moz.build
+++ b/security/sandbox/win/src/sandboxbroker/moz.build
@@ -1,16 +1,15 @@
 # -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*-
 # vim: set filetype=python:
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 LIBRARY_NAME = 'sandboxbroker'
-EXPORT_LIBRARY = True
 
 SOURCES += [
     'sandboxBroker.cpp',
 ]
 
 EXPORTS += [
     'sandboxBroker.h',
 ]
--- a/testing/gtest/moz.build
+++ b/testing/gtest/moz.build
@@ -63,18 +63,16 @@ if CONFIG['ENABLE_TESTS']:
     ]
 
     LIBRARY_NAME = 'gtest'
 
     SOURCES += [
         'mozilla/SanityTest.cpp',
     ]
 
-    EXPORT_LIBRARY = True
-
     LOCAL_INCLUDES += [
         'gmock',
         'gmock/include',
         'gtest',
         'gtest/include',
     ]
 
     FINAL_LIBRARY = 'xul-gtest'
--- a/toolkit/components/workerlz4/moz.build
+++ b/toolkit/components/workerlz4/moz.build
@@ -12,10 +12,9 @@ EXTRA_JS_MODULES += [
     'lz4.js',
     'lz4_internal.js',
 ]
 
 SOURCES += [
     'lz4.cpp',
 ]
 
-EXPORT_LIBRARY = True
 FINAL_LIBRARY = 'xul'
--- a/toolkit/library/libxul.mk
+++ b/toolkit/library/libxul.mk
@@ -88,17 +88,17 @@ endif
 ifndef MOZ_TREE_PIXMAN
 EXTRA_DSO_LDOPTS += $(MOZ_PIXMAN_LIBS)
 endif
 
 ifdef MOZ_DMD
 EXTRA_DSO_LDOPTS += $(call EXPAND_LIBNAME_PATH,dmd,$(DIST)/lib)
 endif
 
-EXTRA_DSO_LDOPTS += $(call EXPAND_LIBNAME_PATH,gkmedias,$(DIST)/lib)
+EXTRA_DSO_LDOPTS += $(call EXPAND_LIBNAME_PATH,gkmedias,$(DEPTH)/layout/media)
 
 ifdef MOZ_WEBRTC
 ifeq (WINNT,$(OS_TARGET))
 ifndef MOZ_HAS_WINSDK_WITH_D3D
 EXTRA_DSO_LDOPTS += \
   -LIBPATH:'$(MOZ_DIRECTX_SDK_PATH)/lib/$(MOZ_D3D_CPU_SUFFIX)' \
   $(NULL)
 endif
--- a/tools/jprof/stub/moz.build
+++ b/tools/jprof/stub/moz.build
@@ -9,13 +9,11 @@ EXPORTS += [
 ]
 
 SOURCES += [
     'libmalloc.cpp',
 ]
 
 LIBRARY_NAME = 'jprof'
 
-EXPORT_LIBRARY = True
-
 FORCE_SHARED_LIB = True
 
 DEFINES['_IMPL_JPROF_API'] = True
--- a/tools/profiler/tests/gtest/moz.build
+++ b/tools/profiler/tests/gtest/moz.build
@@ -6,18 +6,16 @@
 
 LIBRARY_NAME = 'sps_test'
 
 if CONFIG['OS_TARGET'] in ('Android', 'Linux'):
     UNIFIED_SOURCES += [
         'LulTest.cpp',
     ]
 
-EXPORT_LIBRARY = True
-
 LOCAL_INCLUDES += [
     '/tools/profiler',
 ]
 
 UNIFIED_SOURCES += [
     'JSStreamWriterTest.cpp',
     'ThreadProfileTest.cpp',
 ]
--- a/xpcom/glue/tests/gtest/moz.build
+++ b/xpcom/glue/tests/gtest/moz.build
@@ -12,11 +12,9 @@ UNIFIED_SOURCES += [
 LOCAL_INCLUDES = [
     '../..',
 ]
 
 FAIL_ON_WARNINGS = True
 
 LIBRARY_NAME = 'xpcom_glue_gtest'
 
-EXPORT_LIBRARY = True
-
 FINAL_LIBRARY = 'xul-gtest'