dom/base/moz.build
author Gurzau Raul <rgurzau@mozilla.com>
Wed, 13 Dec 2017 23:41:49 +0200
changeset 396289 ccd7b237c4337a00e45bf18ac2d0218c61e1134d
parent 396266 b628d9298be89033495ad48372743a0902afab39
child 396834 13faabcf8e965cca857e3cc8fdbea289a09c7ea0
permissions -rw-r--r--
Backed out 22 changesets (bug 1419771) for build bustage build/src/dom/base/FuzzingFunctions.cpp on a CLOSED TREE Backed out changeset b2b7b46c8ad0 (bug 1419771) Backed out changeset 0206657d2ea2 (bug 1419771) Backed out changeset f0f4b98a07b6 (bug 1419771) Backed out changeset 4b52904694f4 (bug 1419771) Backed out changeset 9f40cc12d6c6 (bug 1419771) Backed out changeset f500a61f564c (bug 1419771) Backed out changeset 0bd9d964df8a (bug 1419771) Backed out changeset 1397a6bbb446 (bug 1419771) Backed out changeset 7e77a00fa8b5 (bug 1419771) Backed out changeset 5f6df771459a (bug 1419771) Backed out changeset 7624e70b2965 (bug 1419771) Backed out changeset b9d674bdc723 (bug 1419771) Backed out changeset 5e44aeda4196 (bug 1419771) Backed out changeset 601b49f51b41 (bug 1419771) Backed out changeset d12dc5557982 (bug 1419771) Backed out changeset 6c863ab2e986 (bug 1419771) Backed out changeset 0866d79873ab (bug 1419771) Backed out changeset 8ecc91474621 (bug 1419771) Backed out changeset 19b14deed8fe (bug 1419771) Backed out changeset 000c8d5fbc03 (bug 1419771) Backed out changeset 2e263a2519c5 (bug 1419771) Backed out changeset b628d9298be8 (bug 1419771)

# -*- Mode: python; 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/.

with Files('*Selection*'):
    BUG_COMPONENT = ('Core', 'Selection')

with Files("**"):
    BUG_COMPONENT = ("Core", "DOM")

TEST_DIRS += ['test']

XPIDL_SOURCES += [
    'mozIDOMWindow.idl',
    'nsIContentPolicy.idl',
    'nsIDocumentEncoder.idl',
    'nsIDOMDataChannel.idl',
    'nsIDOMDOMCursor.idl',
    'nsIDOMDOMRequest.idl',
    'nsIDOMFormData.idl',
    'nsIDOMParser.idl',
    'nsIDOMSerializer.idl',
    'nsIDroppedLinkHandler.idl',
    'nsIFrameLoader.idl',
    'nsIImageLoadingContent.idl',
    'nsIMessageManager.idl',
    'nsIObjectLoadingContent.idl',
    'nsIRemoteWindowContext.idl',
    'nsIScriptChannel.idl',
    'nsISelection.idl',
    'nsISelectionController.idl',
    'nsISelectionDisplay.idl',
    'nsISelectionListener.idl',
    'nsISelectionPrivate.idl',
    'nsISlowScriptDebug.idl',
]

XPIDL_MODULE = 'dom'

EXPORTS += [
    'AutocompleteFieldList.h',
    'Crypto.h',
    'HTMLSplitOnSpacesTokenizer.h',
    'IframeSandboxKeywordList.h',
    'mozAutoDocUpdate.h',
    'nsAtomListUtils.h',
    'nsAttrAndChildArray.h',
    'nsAttrName.h',
    'nsAttrValue.h',
    'nsAttrValueInlines.h',
    'nsCaseTreatment.h',
    'nsChildContentList.h',
    'nsContentCID.h',
    'nsContentCreatorFunctions.h',
    'nsContentList.h',
    'nsContentListDeclarations.h',
    'nsContentPermissionHelper.h',
    'nsContentPolicyUtils.h',
    'nsContentSink.h',
    'nsContentTypeParser.h',
    'nsContentUtils.h',
    'nsCopySupport.h',
    'nsDeprecatedOperationList.h',
    'nsDocElementCreatedNotificationRunner.h',
    'nsDocumentWarningList.h',
    'nsDOMAttributeMap.h',
    'nsDOMCID.h',
    'nsDOMClassInfoID.h',
    'nsDOMJSUtils.h',
    'nsDOMNavigationTiming.h',
    'nsDOMString.h',
    'nsDOMTokenList.h',
    'nsFocusManager.h',
    'nsFrameMessageManager.h',
    'nsGenericDOMDataNode.h',
    'nsGkAtomList.h',
    'nsGkAtoms.h',
    'nsIAnimationObserver.h',
    'nsIAttribute.h',
    'nsIContent.h',
    'nsIContentInlines.h',
    'nsIContentIterator.h',
    'nsIContentSerializer.h',
    'nsIdentifierMapEntry.h',
    'nsIDocument.h',
    'nsIDocumentInlines.h',
    'nsIDocumentObserver.h',
    'nsIDOMClassInfo.h',
    'nsIGlobalObject.h',
    'nsImageLoadingContent.h',
    'nsIMutationObserver.h',
    'nsINode.h',
    'nsINodeList.h',
    'nsIScriptContext.h',
    'nsIScriptGlobalObject.h',
    'nsIScriptNameSpaceManager.h',
    'nsIScriptObjectPrincipal.h',
    'nsIScriptTimeoutHandler.h',
    'nsIStyleSheetLinkingElement.h',
    'nsITimeoutHandler.h',
    'nsJSEnvironment.h',
    'nsJSUtils.h',
    'nsLineBreaker.h',
    'nsMappedAttributeElement.h',
    'nsNameSpaceManager.h',
    'nsNodeInfoManager.h',
    'nsNodeUtils.h',
    'nsPIDOMWindow.h',
    'nsPIDOMWindowInlines.h',
    'nsPIWindowRoot.h',
    'nsPropertyTable.h',
    'nsRange.h',
    'nsSandboxFlags.h',
    'nsStructuredCloneContainer.h',
    'nsStubAnimationObserver.h',
    'nsStubDocumentObserver.h',
    'nsStubMutationObserver.h',
    'nsStyledElement.h',
    'nsStyleLinkElement.h',
    'nsTextFragment.h',
    'nsTraversal.h',
    'nsTreeSanitizer.h',
    'nsViewportInfo.h',
    'nsWindowMemoryReporter.h',
    'nsWindowSizes.h',
    'nsWrapperCache.h',
    'nsWrapperCacheInlines.h',
    'nsXMLNameSpaceMap.h',
    'XPathGenerator.h',
]

if CONFIG['MOZ_WEBRTC']:
    EXPORTS += [
        'nsDOMDataChannel.h',
        'nsDOMDataChannelDeclarations.h',
    ]

EXPORTS.mozilla += [
    'CORSMode.h',
    'FeedWriterEnabled.h',
    'FlushType.h',
    'RangeBoundary.h',
    'TextInputProcessor.h',
    'UseCounter.h',
]

EXPORTS.mozilla.dom += [
    '!UseCounterList.h',
    'AnonymousContent.h',
    'Attr.h',
    'BarProps.h',
    'BodyUtil.h',
    'BorrowedAttrInfo.h',
    'ChildIterator.h',
    'ChromeNodeList.h',
    'ChromeUtils.h',
    'Comment.h',
    'CustomElementRegistry.h',
    'DirectionalityUtils.h',
    'DispatcherTrait.h',
    'DocGroup.h',
    'DocumentFragment.h',
    'DocumentType.h',
    'DOMCursor.h',
    'DOMError.h',
    'DOMException.h',
    'DOMImplementation.h',
    'DOMIntersectionObserver.h',
    'DOMMatrix.h',
    'DOMParser.h',
    'DOMPoint.h',
    'DOMQuad.h',
    'DOMRect.h',
    'DOMRequest.h',
    'DOMStringList.h',
    'DOMTokenListSupportedTokens.h',
    'Element.h',
    'ElementInlines.h',
    'EventSource.h',
    'FormData.h',
    'FragmentOrElement.h',
    'FromParser.h',
    'GroupedSHistory.h',
    'IdleDeadline.h',
    'IdleRequest.h',
    'IDTracker.h',
    'ImageEncoder.h',
    'ImageTracker.h',
    'IntlUtils.h',
    'Link.h',
    'Location.h',
    'NameSpaceConstants.h',
    'Navigator.h',
    'NodeInfo.h',
    'NodeInfoInlines.h',
    'NodeIterator.h',
    'PartialSHistory.h',
    'Pose.h',
    'ProcessGlobal.h',
    'ResponsiveImageSelector.h',
    'SameProcessMessageQueue.h',
    'ScreenOrientation.h',
    'Selection.h',
    'ShadowRoot.h',
    'StructuredCloneBlob.h',
    'StructuredCloneHolder.h',
    'StructuredCloneTags.h',
    'StyleSheetList.h',
    'SubtleCrypto.h',
    'TabGroup.h',
    'Text.h',
    'Timeout.h',
    'TimeoutHandler.h',
    'TimeoutManager.h',
    'TreeWalker.h',
    'WebKitCSSMatrix.h',
    'WindowOrientationObserver.h',
]

if CONFIG['FUZZING']:
    EXPORTS.mozilla.dom += [
        'FuzzingFunctions.h',
    ]

UNIFIED_SOURCES += [
    'AnonymousContent.cpp',
    'Attr.cpp',
    'BarProps.cpp',
    'BodyUtil.cpp',
    'BorrowedAttrInfo.cpp',
    'ChildIterator.cpp',
    'ChromeNodeList.cpp',
    'ChromeUtils.cpp',
    'Comment.cpp',
    'Crypto.cpp',
    'CustomElementRegistry.cpp',
    'DirectionalityUtils.cpp',
    'DispatcherTrait.cpp',
    'DocGroup.cpp',
    'DocumentFragment.cpp',
    'DocumentType.cpp',
    'DOMCursor.cpp',
    'DOMError.cpp',
    'DOMException.cpp',
    'DOMImplementation.cpp',
    'DOMMatrix.cpp',
    'DOMParser.cpp',
    'DOMPoint.cpp',
    'DOMQuad.cpp',
    'DOMRect.cpp',
    'DOMRequest.cpp',
    'DOMStringList.cpp',
    'Element.cpp',
    'EventSource.cpp',
    'FormData.cpp',
    'FragmentOrElement.cpp',
    'GroupedSHistory.cpp',
    'IdleDeadline.cpp',
    'IdleRequest.cpp',
    'IDTracker.cpp',
    'ImageEncoder.cpp',
    'ImageTracker.cpp',
    'IntlUtils.cpp',
    'Link.cpp',
    'Location.cpp',
    'Navigator.cpp',
    'NodeInfo.cpp',
    'NodeIterator.cpp',
    'nsAtomListUtils.cpp',
    'nsAttrAndChildArray.cpp',
    'nsAttrValue.cpp',
    'nsAttrValueOrString.cpp',
    'nsCCUncollectableMarker.cpp',
    'nsContentAreaDragDrop.cpp',
    'nsContentIterator.cpp',
    'nsContentList.cpp',
    'nsContentPermissionHelper.cpp',
    'nsContentPolicy.cpp',
    'nsContentSink.cpp',
    'nsCopySupport.cpp',
    'nsDataDocumentContentPolicy.cpp',
    'nsDocument.cpp',
    'nsDocumentEncoder.cpp',
    'nsDOMAttributeMap.cpp',
    'nsDOMCaretPosition.cpp',
    'nsDOMClassInfo.cpp',
    'nsDOMMutationObserver.cpp',
    'nsDOMNavigationTiming.cpp',
    'nsDOMSerializer.cpp',
    'nsDOMTokenList.cpp',
    'nsDOMWindowList.cpp',
    'nsFocusManager.cpp',
    'nsFrameLoader.cpp',
    'nsGenConImageContent.cpp',
    'nsGenericDOMDataNode.cpp',
    'nsGkAtoms.cpp',
    'nsGlobalWindowCommands.cpp',
    'nsHistory.cpp',
    'nsHTMLContentSerializer.cpp',
    'nsIGlobalObject.cpp',
    'nsINode.cpp',
    'nsInProcessTabChildGlobal.cpp',
    'nsJSEnvironment.cpp',
    'nsJSTimeoutHandler.cpp',
    'nsJSUtils.cpp',
    'nsLineBreaker.cpp',
    'nsMappedAttributeElement.cpp',
    'nsMappedAttributes.cpp',
    'nsMimeTypeArray.cpp',
    'nsNameSpaceManager.cpp',
    'nsNoDataProtocolContentPolicy.cpp',
    'nsNodeInfoManager.cpp',
    'nsNodeUtils.cpp',
    'nsOpenURIInFrameParams.cpp',
    'nsPlainTextSerializer.cpp',
    'nsPropertyTable.cpp',
    'nsQueryContentEventResult.cpp',
    'nsRange.cpp',
    'nsScreen.cpp',
    'nsScriptNameSpaceManager.cpp',
    'nsStructuredCloneContainer.cpp',
    'nsStubAnimationObserver.cpp',
    'nsStubDocumentObserver.cpp',
    'nsStubMutationObserver.cpp',
    'nsStyledElement.cpp',
    'nsStyleLinkElement.cpp',
    'nsSyncLoadService.cpp',
    'nsTextFragment.cpp',
    'nsTextNode.cpp',
    'nsTraversal.cpp',
    'nsTreeSanitizer.cpp',
    'nsViewportInfo.cpp',
    'nsWindowMemoryReporter.cpp',
    'nsWindowRoot.cpp',
    'nsWrapperCache.cpp',
    'nsXHTMLContentSerializer.cpp',
    'nsXMLContentSerializer.cpp',
    'nsXMLNameSpaceMap.cpp',
    'PartialSHistory.cpp',
    'Pose.cpp',
    'PostMessageEvent.cpp',
    'ProcessGlobal.cpp',
    'ResponsiveImageSelector.cpp',
    'SameProcessMessageQueue.cpp',
    'ScreenOrientation.cpp',
    'Selection.cpp',
    'SelectionChangeListener.cpp',
    'ShadowRoot.cpp',
    'StructuredCloneBlob.cpp',
    'StructuredCloneHolder.cpp',
    'StyleSheetList.cpp',
    'SubtleCrypto.cpp',
    'TabGroup.cpp',
    'Text.cpp',
    'TextInputProcessor.cpp',
    'ThirdPartyUtil.cpp',
    'Timeout.cpp',
    'TimeoutBudgetManager.cpp',
    'TimeoutExecutor.cpp',
    'TimeoutHandler.cpp',
    'TimeoutManager.cpp',
    'TreeWalker.cpp',
    'WebKitCSSMatrix.cpp',
    'WindowDestroyedEvent.cpp',
    'WindowNamedPropertiesHandler.cpp',
    'WindowOrientationObserver.cpp',
    'XPathGenerator.cpp',
]

if CONFIG['MOZ_WEBRTC']:
    UNIFIED_SOURCES += [
        'nsDOMDataChannel.cpp',
    ]

if CONFIG['FUZZING']:
    UNIFIED_SOURCES += [
        'FuzzingFunctions.cpp',
    ]

# these files couldn't be in UNIFIED_SOURCES for now for reasons given below:
SOURCES += [
    # Several conflicts with other bindings.
    'DOMIntersectionObserver.cpp',
    # Because of OS X headers.
    'nsContentUtils.cpp',
    # this file doesn't like windows.h
    'nsDOMWindowUtils.cpp',
    # Conflicts with windows.h's definition of SendMessage.
    'nsFrameMessageManager.cpp',
    # These files have a #error "Never include windows.h in this file!"
    'nsGlobalWindowInner.cpp',
    'nsGlobalWindowOuter.cpp',
    # Conflicts with windows.h's definition of LoadImage.
    'nsImageLoadingContent.cpp',
    # Because of OS X headers.
    'nsObjectLoadingContent.cpp',
    # nsPluginArray.cpp includes npapi.h indirectly, and that includes a lot of system headers
    'nsPluginArray.cpp',
]

# Are we targeting x86-32 or x86-64?  If so, we want to include SSE2 code for
# nsTextFragment.cpp
if CONFIG['INTEL_ARCHITECTURE']:
    SOURCES += ['nsTextFragmentSSE2.cpp']
    SOURCES['nsTextFragmentSSE2.cpp'].flags += CONFIG['SSE2_FLAGS']

EXTRA_COMPONENTS += [
    'contentAreaDropListener.js',
    'contentAreaDropListener.manifest',
    'ProcessSelector.js',
    'ProcessSelector.manifest',
    'SlowScriptDebug.js',
    'SlowScriptDebug.manifest',
]

EXTRA_JS_MODULES += [
    'DOMRequestHelper.jsm',
    'IndexedDBHelper.jsm',
]

LOCAL_INCLUDES += [
    '../battery',
    '../events',
    '../media',
    '../network',
    '../time',
    '/caps',
    '/docshell/base',
    '/dom/base',
    '/dom/file',
    '/dom/geolocation',
    '/dom/html',
    '/dom/ipc',
    '/dom/storage',
    '/dom/svg',
    '/dom/u2f',
    '/dom/workers',
    '/dom/xbl',
    '/dom/xml',
    '/dom/xslt/xpath',
    '/dom/xul',
    '/gfx/2d',
    '/image',
    '/js/xpconnect/src',
    '/js/xpconnect/wrappers',
    '/layout/base',
    '/layout/forms',
    '/layout/generic',
    '/layout/style',
    '/layout/svg',
    '/layout/xul',
    '/netwerk/base',
    '/security/manager/ssl',
    '/widget',
    '/xpcom/ds',
]

if CONFIG['MOZ_WEBRTC']:
    LOCAL_INCLUDES += [
        '/netwerk/sctp/datachannel',
    ]

include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['MOZ_BUILD_APP'] in ['browser', 'mobile/android', 'xulrunner']:
    DEFINES['HAVE_SIDEBAR'] = True

if CONFIG['MOZ_X11']:
    CXXFLAGS += CONFIG['TK_CFLAGS']

GENERATED_FILES += [
    'PropertyUseCounterMap.inc',
    'UseCounterList.h',
]

countermap = GENERATED_FILES['PropertyUseCounterMap.inc']
countermap.script = 'gen-usecounters.py:property_map'
countermap.inputs = ['UseCounters.conf']

counterlist = GENERATED_FILES['UseCounterList.h']
counterlist.script = 'gen-usecounters.py:use_counter_list'
counterlist.inputs = ['UseCounters.conf']

if CONFIG['CC_TYPE'] in ('clang', 'gcc'):
    CXXFLAGS += ['-Wno-error=shadow']