Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • B buck
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 201
    • Issues 201
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 22
    • Merge requests 22
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Meta
  • buck
  • Merge requests
  • !1208

Fix race condition on Swift build

  • Review changes

  • Download
  • Email patches
  • Plain diff
Closed Administrator requested to merge github/fork/zayhero-zz/zayhero_testing into master Mar 01, 2017
  • Overview 8
  • Commits 1
  • Pipelines 0
  • Changes 2

Created by: zayhero-zz

In PR https://github.com/facebook/buck/pull/1164, we introduce the logic to allow SwiftCompile use the header maps to built bridging headers. However, we encounter race condition issue when we building with this logic.

The headers maps, is generated by CxxLibraryDescription, and SwiftCompile step is generated by SwiftLibraryDescription. These two build rules are running in parallel, so its not guarantee that header maps are ready when we running SwiftCpmile.

To fix this issue, I am making changes to:

  1. call CxxDescriptionEnhancer.requireHeaderSymlinkTree to create the header symlink tree BuildRule
  2. let SwiftLibraryDescription depends on the symlink tree BuildRule, also make changes to not filter out BuildRules if its building for headers

@ryu2 could you help to take a look on this? Thanks!

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: github/fork/zayhero-zz/zayhero_testing