New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 604538 link

Starred by 2 users

Issue metadata

Status: WontFix
Owner: ----
Closed: Apr 2016
Cc:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: ----
Type: ----



Sign in to add a comment

Incorrect mac linking command line?

Project Member Reported by aizatsky@chromium.org, Apr 18 2016

Issue description

* On Mac *

$ gn gen out/libfuzzer '--args=use_libfuzzer=true is_asan=true enable_nacl=false mac_deployment_target="10.7"' --check && ninja -C out/libfuzzer -v url_parse_fuzzer

Results in the following error:

[805/807] rm -f obj/testing/libfuzzer/libfuzzer_main.a && ./gyp-mac-tool filter-libtool libtool -static -o obj/testing/libfuzzer/libfuzzer_main.a 
FAILED: rm -f obj/testing/libfuzzer/libfuzzer_main.a && ./gyp-mac-tool filter-libtool libtool -static -o obj/testing/libfuzzer/libfuzzer_main.a 
error: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool: no files specified
Usage: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool -static [-] file [...] [-filelist listfile[,dirname]] [-arch_only arch] [-sacLT] [-no_warning_for_no_symbols]
Usage: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/libtool -dynamic [-] file [...] [-filelist listfile[,dirname]] [-arch_only arch] [-o output] [-install_name name] [-compatibility_version #] [-current_version #] [-seg1addr 0x#] [-segs_read_only_addr 0x#] [-segs_read_write_addr 0x#] [-seg_addr_table <filename>] [-seg_addr_table_filename <file_system_path>] [-all_load] [-noall_load]


Build rule:
   https://code.google.com/p/chromium/codesearch#chromium/src/testing/libfuzzer/BUILD.gn&l=17



PS Have to be synced beyond https://chromium.googlesource.com/chromium/src/+/d476d8d12ec348f2f8ceb7012f6cb56369c7fb16
 
Owner: brettw@chromium.org
Brett, could you suggest on owner for this bug? Seems to be a problem with mac toolchain definition.
Cc: thakis@chromium.org

Comment 3 by thakis@chromium.org, Apr 19 2016

You have a static library with no sources. That doesn't with on Mac (loudly) and windows (silently, but the build never becomes clean). Whoever added the libfuzzer_main target should own this bug.

Comment 4 by thakis@chromium.org, Apr 19 2016

Labels: -Restrict-View-Google -Infra Build
Also, not an infra bug and no need to make this internal
Owner: mbarbe...@chromium.org
Status: Assigned (was: Untriaged)
Cc: och...@chromium.org mmoroz@chromium.org infe...@chromium.org kcc@chromium.org aizatsky@chromium.org
Owner: ----
Status: Available (was: Assigned)
I haven't been working on the libfuzzer build stuff, but adding some people who might be able to help.
@thakis do you think we should add a dummy .c file just for Mac compatibility? I'm not sure which other options are there. I would definitely appreciate mac toolchain definition to solve this problem for me. As far as the GN reference says, this does look like canonical usage of source_set.

Comment 8 by thakis@chromium.org, Apr 20 2016

Make this not a static_library but a source_set if possible. (also, not just mac: it's broken on windows too, and weird on linux as well.) If there are no sources in the target, why do you need the target at all? can the target exist only when it actually contains files?

Somewhat hard to answer without knowing anything about what you're trying to do :-) What are you trying to do?
Status: WontFix (was: Available)
I guess I was stuck trying to make it work. Thank you for unsticking me. :) Replaced static_library by source_set.

Sign in to add a comment