Bug 1656141 - Remove RESFILE. r=firefox-build-system-reviewers,rstewart

The resource file is always generated so being able to configure its name
is not useful. On the other hand, the way things are currently implemented,
the lack of RESFILE also makes RCFILE ignored, which we fix at the same
time.

And remove a spurious RESFILE in widget/windows/moz.build, where no binary
is produced, which means RESFILE had no meaning.

Differential Revision: https://phabricator.services.mozilla.com/D86154
This commit is contained in:
Mike Hommey 2020-08-06 22:51:59 +00:00
Родитель 22179736a6
Коммит 5a5a1edd0e
12 изменённых файлов: 7 добавлений и 21 удалений

Просмотреть файл

@ -13,7 +13,6 @@ INCLUDED_VERSION_MK=1
# BINARY : Binary name. Not used currently.
ifeq ($(MOZ_WIDGET_TOOLKIT),windows)
ifndef RESFILE
RCFILE=./module.rc
RESFILE=./module.res
ifdef PROGRAM
_RC_BINARY = $(notdir $(PROGRAM))
@ -27,14 +26,20 @@ endif
endif
endif
GARBAGE += $(RESFILE) $(RCFILE)
GARBAGE += $(RESFILE)
#dummy target so $(RCFILE) doesn't become the default =P
all::
ifndef RCFILE
RCFILE=./module.rc
$(RCFILE): $(RCINCLUDE) $(MOZILLA_DIR)/config/create_rc.py
$(PYTHON3) $(MOZILLA_DIR)/config/create_rc.py '$(_RC_BINARY)' '$(RCINCLUDE)'
GARBAGE += $(RCFILE)
endif # RCFILE
endif # RESFILE
endif # Windows

Просмотреть файл

@ -41,7 +41,6 @@ NO_PGO = True
if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
RCFILE = 'nptest.rc'
RESFILE = 'nptest.res'
DEFFILE = 'nptest.def'
if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa' and CONFIG['TARGET_CPU'] == 'x86_64':

Просмотреть файл

@ -12,7 +12,6 @@ UNIFIED_SOURCES = [
]
RCFILE = 'TestDllBlocklist_AllowByVersion.rc'
RESFILE = 'TestDllBlocklist_AllowByVersion.res'
if CONFIG['COMPILE_ENVIRONMENT']:
TEST_HARNESS_FILES.gtest += ['!TestDllBlocklist_AllowByVersion.dll']

Просмотреть файл

@ -12,7 +12,6 @@ UNIFIED_SOURCES = [
]
RCFILE = 'TestDllBlocklist_MatchByVersion.rc'
RESFILE = 'TestDllBlocklist_MatchByVersion.res'
if CONFIG['COMPILE_ENVIRONMENT']:
TEST_HARNESS_FILES.gtest += ['!TestDllBlocklist_MatchByVersion.dll']

Просмотреть файл

@ -12,7 +12,6 @@ UNIFIED_SOURCES = [
]
RCFILE = 'TestDllBlocklist_NoOpEntryPoint.rc'
RESFILE = 'TestDllBlocklist_NoOpEntryPoint.res'
if CONFIG['COMPILE_ENVIRONMENT']:
TEST_HARNESS_FILES.gtest += ['!TestDllBlocklist_NoOpEntryPoint.dll']

Просмотреть файл

@ -1706,12 +1706,6 @@ VARIABLES = {
This variable can only be used on Windows.
"""),
'RESFILE': (six.text_type, six.text_type,
"""The program .res file.
This variable can only be used on Windows.
"""),
'RCINCLUDE': (Path, six.text_type,
"""The resource script file to be included in the default .res file.

Просмотреть файл

@ -1089,7 +1089,6 @@ class TreeMetadataEmitter(LoggingMixin):
varlist = [
'EXTRA_DSO_LDOPTS',
'RCFILE',
'RESFILE',
'RCINCLUDE',
'WIN32_EXE_LDFLAGS',
'USE_EXTENSION_MANIFEST',

Просмотреть файл

@ -5,7 +5,6 @@
DELAYLOAD_DLLS = ['foo.dll', 'bar.dll']
RCFILE = 'foo.rc'
RESFILE = 'bar.res'
RCINCLUDE = 'bar.rc'
DEFFILE = 'baz.def'

Просмотреть файл

@ -322,9 +322,6 @@ class TestRecursiveMakeBackend(BackendTester):
'RCFILE': [
'RCFILE := $(srcdir)/foo.rc',
],
'RESFILE': [
'RESFILE := bar.res',
],
'RCINCLUDE': [
'RCINCLUDE := $(srcdir)/bar.rc',
],

Просмотреть файл

@ -7,7 +7,6 @@ DIST_INSTALL = False
DELAYLOAD_DLLS = ['foo.dll', 'bar.dll']
RCFILE = 'foo.rc'
RESFILE = 'bar.res'
RCINCLUDE = 'bar.rc'
DEFFILE = 'baz.def'

Просмотреть файл

@ -188,7 +188,6 @@ class TestEmitterBasic(unittest.TestCase):
wanted = {
'NO_DIST_INSTALL': True,
'RCFILE': 'foo.rc',
'RESFILE': 'bar.res',
'RCINCLUDE': 'bar.rc',
'WIN32_EXE_LDFLAGS': ['-subsystem:console'],
}

Просмотреть файл

@ -167,8 +167,6 @@ for var in ('MOZ_ENABLE_D3D10_LAYER'):
if CONFIG[var]:
DEFINES[var] = True
RESFILE = 'widget.res'
CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS']
OS_LIBS += [