Status

defect
6 years ago
a year ago

People

(Reporter: joey, Unassigned)

Tracking

(Blocks 1 bug)

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [leave open])

Attachments

(3 attachments, 4 obsolete attachments)

Comment hidden (empty)
(Reporter)

Updated

6 years ago
No longer depends on: 882904
Summary: move OS_LIB to moz.build → move OS_LIBS to moz.build
(Reporter)

Updated

6 years ago
No longer blocks: 870366
(Reporter)

Updated

6 years ago
No longer depends on: 882907
(Reporter)

Updated

6 years ago
No longer depends on: 882906
(Reporter)

Comment 1

6 years ago
(Reporter)

Updated

6 years ago
Assignee: nobody → joey
(Reporter)

Comment 2

6 years ago
Comment on attachment 776572 [details] [diff] [review]
move OS_LIBS to mozbuild (logic).

Added a passthrough conversion for OS_LIBS.  May not be able to cover $(call expansions but we can start converting the simple assignments.
Attachment #776572 - Flags: review?(gps)
Comment on attachment 776572 [details] [diff] [review]
move OS_LIBS to mozbuild (logic).

Review of attachment 776572 [details] [diff] [review]:
-----------------------------------------------------------------

::: python/mozbuild/mozbuild/test/backend/test_recursivemake.py
@@ +187,5 @@
>                  'HOST_LIBRARY_NAME := host_bar',
>              ],
>              'LIBRARY_NAME': [
>                  'LIBRARY_NAME := lib_name',
> +            ], 

Trailing whitespace.
Attachment #776572 - Flags: review?(gps) → review+
(Reporter)

Comment 4

6 years ago
(Reporter)

Updated

6 years ago
Attachment #776572 - Attachment is obsolete: true
(Reporter)

Comment 5

6 years ago
Comment on attachment 777963 [details] [diff] [review]
move OS_LIBS to mozbuild (logic).

nit cleanup: fixed whitespace  r=gps carried forward
(Reporter)

Comment 6

6 years ago
lingering references.


./gfx/angle/src/libGLESv2/Makefile.in:OS_LIBS += -ld3d9 -ldxguid
./gfx/angle/src/libEGL/Makefile.in:#OS_LIBS += $(call EXPAND_LIBNAME,dwmapi)
./gfx/angle/src/libEGL/Makefile.in:OS_LIBS += -ld3d9 -llibGLESv2
./js/src/Makefile.in:# - OS_LIBS includes libraries selected by the configure script.
./js/src/Makefile.in:JS_CONFIG_LIBS=$(EXTRA_DSO_LDOPTS) $(OS_LIBS) $(EXTRA_LIBS)
./layout/media/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,usp10 ole32)
./layout/media/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,secur32 crypt32 iphlpapi strmiids dmoguids wmcodecdspuuid amstrmid msdmo wininet)
./layout/media/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,delayimp)
./layout/media/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME, msimg32)
./layout/media/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME, winmm)
./accessible/public/msaa/Makefile.in:OS_LIBS = $(call EXPAND_LIBNAME,kernel32 rpcns4 rpcrt4 oleaut32)
./accessible/public/ia2/Makefile.in:OS_LIBS = $(call EXPAND_LIBNAME,uuid kernel32 rpcns4 rpcrt4 ole32 oleaut32)
./xpcom/tests/windows/Makefile.in:OS_LIBS       += $(call EXPAND_LIBNAME,rpcrt4 uuid)
./testing/tools/screenshot/Makefile.in:OS_LIBS = $(TK_LIBS) $(XSS_LIBS)
./testing/tools/screenshot/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,gdiplus)
./xulrunner/stub/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,shell32)
./xulrunner/app/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,comctl32 comdlg32 uuid shell32 ole32 oleaut32 version winspool)
./memory/replace/dmd/Makefile.in:OS_LIBS         += $(call EXPAND_LIBNAME,dbghelp)
./toolkit/mozapps/update/updater/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,delayimp comctl32 ws2_32 shell32 shlwapi)
./toolkit/mozapps/update/updater/Makefile.in:OS_LIBS += $(TK_LIBS)
./toolkit/mozapps/update/updater/Makefile.in:OS_LIBS += -framework Cocoa
./toolkit/mozapps/update/updater/Makefile.in:OS_LIBS += -lcutils -lsysutils
./toolkit/library/Makefile.in:OS_LIBS += -ldbus
./toolkit/library/Makefile.in:OS_LIBS += -lstagefright -lstagefright_omx
./toolkit/library/Makefile.in:OS_LIBS += -lrt
./toolkit/library/Makefile.in:OS_LIBS += -framework OpenGL -lcups
./toolkit/library/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,secur32 crypt32 iphlpapi strmiids dmoguids wmcodecdspuuid amstrmid msdmo wininet)
./toolkit/library/Makefile.in:OS_LIBS += -lGLESv2
./toolkit/library/Makefile.in:OS_LIBS += \
./toolkit/library/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,mfuuid wmcodecdspuuid strmiids)
./toolkit/library/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,dmoguids wmcodecdspuuid strmiids msdmo)
./toolkit/library/Makefile.in:OS_LIBS += \
./toolkit/library/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,kvm)
./toolkit/library/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,shell32 ole32 version winspool comdlg32 imm32 msimg32 shlwapi psapi ws2_32 dbghelp rasapi32 rasdlg iphlpapi uxtheme setupapi secur32 sensorsapi portabledeviceguids windowscodecs wininet)
./toolkit/library/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,oleacc)
./toolkit/library/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,uiautomationcore runtimeobject)
./toolkit/library/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,delayimp)
./toolkit/library/Makefile.in:OS_LIBS += \
./toolkit/library/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,dxguid dinput8)
./toolkit/library/Makefile.in:OS_LIBS += $(LIBICONV)
./toolkit/library/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,usp10 oleaut32)
./toolkit/crashreporter/client/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,comctl32 shell32 wininet shlwapi)
./toolkit/crashreporter/client/Makefile.in:OS_LIBS += -framework Cocoa
./toolkit/crashreporter/client/Makefile.in:OS_LIBS += $(TK_LIBS) $(MOZ_GTHREAD_LIBS)
./toolkit/crashreporter/client/Makefile.in:OS_LIBS += $(MOZ_GTK2_LIBS) $(MOZ_GTHREAD_LIBS)
./toolkit/components/maintenanceservice/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,comctl32 ws2_32 shell32)
./toolkit/xre/test/win/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,comctl32 ws2_32 shell32)
./webapprt/win/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,shell32)
./b2g/app/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,version)
./intl/uconv/tools/Makefile.in:OS_LIBS          += /usr/lib/libdl.so
./embedding/tests/winEmbed/Makefile.in:OS_LIBS          += $(call EXPAND_LIBNAME,ole32 comdlg32 shell32 version)
./tools/jprof/Makefile.in:OS_LIBS = \
./dom/plugins/ipc/hangui/Makefile.in:OS_LIBS = $(call EXPAND_LIBNAME,comctl32)
./browser/metro/shell/testing/Makefile.in:OS_LIBS = \
./browser/metro/shell/commandexecutehandler/Makefile.in:OS_LIBS = \
./browser/metro/shell/linktool/Makefile.in:OS_LIBS = \
./browser/components/build/Makefile.in:OS_LIBS  += $(call EXPAND_LIBNAME,ole32 shell32 shlwapi)
./browser/components/build/Makefile.in:OS_LIBS += $(call EXPAND_LIBNAME,version)
(Reporter)

Updated

6 years ago
Attachment #777963 - Attachment is obsolete: true
(Reporter)

Comment 8

6 years ago
Comment on attachment 803228 [details] [diff] [review]
move OS_LIBS to mozbuild (logic).

refresh the patch for inbound checkin.  r=gps carried forward.
(Reporter)

Updated

6 years ago
Whiteboard: [leave open]
(Reporter)

Comment 9

6 years ago
Inbound push: https://hg.mozilla.org/integration/mozilla-inbound/rev/e9ee43da0c16
committed changeset 146625:e9ee43da0c16
(Reporter)

Comment 11

6 years ago
https://tbpl.mozilla.org/?tree=Try&rev=7cb715a597ba

if sys.platform == 'win32'
  from win32file import RemoveDirectory, DeleteFile,

ImportError: No module named win32file

slave: tst-w64-ec2-001
See Also: → 910255
(Reporter)

Updated

6 years ago
Attachment #807907 - Attachment is obsolete: true
(Reporter)

Comment 15

6 years ago
Comment on attachment 807925 [details] [diff] [review]
move OS_LIBS to mozbuild (ffile batch #1)

Review of attachment 807925 [details] [diff] [review]:
-----------------------------------------------------------------

move os_libs to mozbuild, batch #1
Attachment #807925 - Flags: review?(mshal)
(Reporter)

Comment 16

6 years ago
(Reporter)

Updated

6 years ago
Attachment #807967 - Attachment is obsolete: true
Comment on attachment 807925 [details] [diff] [review]
move OS_LIBS to mozbuild (ffile batch #1)

># HG changeset patch
># User Joey Armstrong <joey@mozilla.com>
># Date 1379010577 14400
># Node ID 9a232471077716841bbcda2f983579b9e87d5722
># Parent  8ef53ff515b87d3293c8582f9ffdc35adc24fcde
>bug 882908: move OS_LIBS to mozbuild (ffile batch #1)
>
>diff --git a/browser/metro/shell/commandexecutehandler/moz.build b/browser/metro/shell/commandexecutehandler/moz.build
>--- a/browser/metro/shell/commandexecutehandler/moz.build
>+++ b/browser/metro/shell/commandexecutehandler/moz.build
>@@ -5,8 +5,18 @@
> # file, You can obtain one at http://mozilla.org/MPL/2.0/.
> 
> PROGRAM = 'CommandExecuteHandler'
> 
> CPP_SOURCES += [
>     'CEHHelper.cpp',
>     'CommandExecuteHandler.cpp',
> ]
>+
>+OS_LIBS += [
>+    'advapi32.lib',
>+    'kernel32.lib',
>+    'ole32.lib',
>+    'propsys.lib',
>+    'shlwapi.lib',
>+    'user32.lib',
>+    'wininet.lib',
>+]

Looks like you forgot to remove these from browser/metro/shell/commandexecutehandler/Makefile.in?

>diff --git a/gfx/angle/src/libEGL/Makefile.in b/gfx/angle/src/libEGL/Makefile.in
>--- a/gfx/angle/src/libEGL/Makefile.in
>+++ b/gfx/angle/src/libEGL/Makefile.in
>@@ -43,22 +43,19 @@ LOCAL_INCLUDES = \
> VPATH += $(srcdir)/../common
> # src/libEGL:
> VPATH += $(srcdir)/../libEGL
> DEFFILE = $(srcdir)/libEGL.def
> RCFILE  = $(srcdir)/libEGL.rc
> 
> include $(topsrcdir)/config/rules.mk
> 
>-#OS_LIBS += $(call EXPAND_LIBNAME,dwmapi)
>-
> ifdef GNU_CC
> 
> OS_CXXFLAGS := $(filter-out -fno-exceptions,$(OS_CXXFLAGS)) -fexceptions
>-OS_LIBS += -ld3d9 -llibGLESv2
> 
> else
> 
> EXTRA_DSO_LDOPTS = "$(MOZ_DIRECTX_SDK_PATH)/lib/$(MOZ_DIRECTX_SDK_CPU_SUFFIX)/d3d9.lib" \
>                    "$(DIST)/lib/libGLESv2.lib" \
>                    delayimp.lib
> 
> endif
>diff --git a/gfx/angle/src/libEGL/moz.build b/gfx/angle/src/libEGL/moz.build
>--- a/gfx/angle/src/libEGL/moz.build
>+++ b/gfx/angle/src/libEGL/moz.build
>@@ -19,8 +19,14 @@ CPP_SOURCES += [
>     'Config.cpp',
>     'Display.cpp',
>     'libEGL.cpp',
>     'main.cpp',
>     'Surface.cpp',
> ]
> 
> LIBRARY_NAME = 'libEGL'
>+
>+if CONFIG['OS_LIBS']:
>+    OS_LIBS += [
>+        '-ld3d9',
>+        '-llibGLESv2',
>+    ]

The Makefile.in has 'ifdef GNU_CC', but you have CONFIG['OS_LIBS'] here. Should be CONFIG['GNU_CC'], I think?

>diff --git a/intl/uconv/tools/moz.build b/intl/uconv/tools/moz.build
>--- a/intl/uconv/tools/moz.build
>+++ b/intl/uconv/tools/moz.build
>@@ -12,8 +12,12 @@ CSRCS += [
>     '%s.c' % s for s in sources
> ]
> 
> bin_suffix = CONFIG['BIN_SUFFIX']
> SIMPLE_PROGRAMS += [
>     '%s%s' % (s, bin_suffix) for s in sources
> ]
> 
>+if CONFIG['OS_ARCH'] is 'Linux' && CONFIG['OS_RELEASE'] == '1.2':

Why do you use 'is' for the first comparison and '==' for the second comparison? They should both be '==', based on my reading (or I'm misunderstanding what you're trying to do here :).
Attachment #807925 - Flags: review?(mshal) → review-
(Reporter)

Comment 19

6 years ago
(In reply to Michael Shal [:mshal] from comment #18)
> Comment on attachment 807925 [details] [diff] [review]
> move OS_LIBS to mozbuild (ffile batch #1)

> Looks like you forgot to remove these from
> browser/metro/shell/commandexecutehandler/Makefile.in?

Heh time to sign off, this is an excellent flag to hint that you may have been starting at mozbuild patches for far too long over the course of one day.
(Reporter)

Updated

6 years ago
Assignee: joey → nobody
Note: We'll want to figure out a way to avoid using $(call EXPAND_LIBNAME) when setting OS_LIBS in moz.build. Since it is currently passthrough, some moz.build files currently set OS_LIBS using the make syntax (eg: chromium-config.mozbuild when bug 928709 lands)
(In reply to Michael Shal [:mshal] from comment #20)
> Note: We'll want to figure out a way to avoid using $(call EXPAND_LIBNAME)
> when setting OS_LIBS in moz.build. Since it is currently passthrough, some

I'd propose that OS_LIBS be made a list where we call expand_libname on each element.

> moz.build files currently set OS_LIBS using the make syntax (eg:
> chromium-config.mozbuild when bug 928709 lands)

O.O why is it doing that? I'm pretty sure almost all if not all the places that include chromium-config.mk don't actually need OS_LIBS for anything (it would be nice if we added more validation of "you set this in a moz.build file but that's useless".

Updated

5 years ago
Blocks: nomakefiles
See https://hg.mozilla.org/integration/mozilla-inbound/rev/a0988e587a90 for the semantics.
Depends on: 1036894
Summary: move OS_LIBS to moz.build → move OS_LIBS, EXTRA_LIS and OS_LDFLAGS to moz.build
OS_LIBS and EXTRA_LIBS seem to be gone from Makefile.in:
https://dxr.mozilla.org/mozilla-central/search?tree=mozilla-central&q=OS_LIBS%20path%3AMakefile.in&redirect=true
https://dxr.mozilla.org/mozilla-central/search?q=EXTRA_LIBS+path%3AMakefile.in&redirect=false&case=false (just NSPR there)

OS_LDFLAGS has just a handful of uses:
https://dxr.mozilla.org/mozilla-central/search?q=OS_LDFLAGS+path%3AMakefile.in&redirect=true&case=false

Of the remaining three uses, two are to add `-Wl,-version-script`, so we could probably add something to moz.build to handle that. The clang-plugin thing probably wants a special case in moz.build to do what it's doing.
Summary: move OS_LIBS, EXTRA_LIS and OS_LDFLAGS to moz.build → Move OS_LDFLAGS to moz.build

Updated

a year ago
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.