question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

platform_linker_flags not working correctly?

See original GitHub issue

I’m trying to customize my build using platform specific libraries. Unfortunately i can’t get it working on debian nor osx. For some reason platform_linker_flags are only matching on default.

#BUCK 
cxx_binary(
  name = 'foo',
  header_namespace = 'foo',
  srcs = glob([
    'src/**/*.cpp',
  ]),
  headers = subdir_glob([
    ('include', '**/*.hpp'),
  ]),
  platform_linker_flags = [
    ('^linux.*', ['-lbar'])
  ],
)

buck version: adc0f78a68db45334098ac083171c7c2ebc32a8c (v2017.03.29) uname -s returns Linux in java: System.getProperty("os.name") returns ‘Linux’ as well.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:16 (11 by maintainers)

github_iconTop GitHub Comments

1reaction
ttsugriycommented, Aug 22, 2017

The reason for current behavior is that platform is matched against a flavor and by default that flavor is default. I don’t know a context behind this, so I can’t say if it’s intentional or not. If nobody picks this task up, I’ll try take a look hopefully later this week.

1reaction
nikhedoniacommented, Aug 22, 2017

Any updates? - as more people and buckaroo packages depend on flavors, this is becoming a bigger annoyance day by day…

Read more comments on GitHub >

github_iconTop Results From Across the Web

"Code model can't parse an included file" + no autocomplete + ...
The files in src/ have some highlighting, so I'm wondering why It's having “code parsing” errors autocomplete isn't working though, so it leads ......
Read more >
Qt 5.1.1 compiler setup on Ubuntu - c++ - Stack Overflow
I added a gcc compiler, but what do I need to put for the compiler path, platform codegen flags, platform linker flags and...
Read more >
2 issues with the clangrefactoring plugin - Qt Bug Tracker
I've run into 2 issues with the clang refactoring plugin in the latest 4.9.82 version that still builds against Qt 5.9 and clang...
Read more >
Ant Fails to Compile Source files · Issue #1344 · facebook/buck
platformLinkerFlags is hiding a field from type ... Running the ant with ant -v shows ant is pointing to correct java version.
Read more >
How do I include -lpthread (or other g++ args) in a CMake ...
I quickly found out that this isn't where it goes, and after some ... Tools -> Options -> Build & Run -> Compilers...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found