Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bazel][1.x][Part 2]: BazelDeps refactor #14959

Merged

Conversation

franramirez688
Copy link
Contributor

@franramirez688 franramirez688 commented Oct 18, 2023

Changelog: Feature: BazelDeps global refactor. Adding each component as an isolated target, better requirements management (including requirements coming from build-context), adding C/C++ flags, etc.
Changelog: Feature: BazelDeps works fine in editable mode.
Changelog: Feature: Added bazel_target_name and bazel_repository_name properties.
Changelog: Feature: Added mechanism to consume shared/static libraries for bazel_lib template in all the platforms.
Docs: conan-io/docs#3457
Closes: #13197 #13234 #12786

Depends on #14958

Summary:

  • Improvements on bazel_layout to be able to work in editable mode.
  • Added copts option
  • Added components as isolated parts of the BUILD.bazel file
  • Added a similar mechanism as CMakeDeps, PkgConfigDeps, etc. to manage transitive requirements
  • Added filegroups for binary folders
  • Prettified BUILD.bazel files (based on @Neeeflix PR)
  • bazel_lib generates projects that are able to compile as shared/static libraries.

@franramirez688 franramirez688 force-pushed the frm/bazeldeps_refactor_1x branch from 6933810 to c20b270 Compare October 19, 2023 16:51
@franramirez688 franramirez688 force-pushed the frm/bazeldeps_refactor_1x branch from c20b270 to 27ae3b9 Compare October 24, 2023 12:40
@franramirez688 franramirez688 force-pushed the frm/bazeldeps_refactor_1x branch from 15ebb15 to fd13c23 Compare October 30, 2023 14:59


@pytest.fixture(scope="module")
def client_lib(bazelrc):
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed because it's enough tested by the next test test_transitive_libs_consuming.

Co-authored-by: Carlos Zoido <mrgalleta@gmail.com>
std::cout << "openssl() First define " << MY_DEFINE << " and other define " << MY_OTHER_DEFINE << "\\n";
zlib();
// This comes from the systemlibs declared in the zlib
sqrt(25);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not okay to ignore return value (compiler may optimize out if there are no side-effects)

Copy link
Member

@memsharded memsharded left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good

Copy link
Contributor

@czoido czoido left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job! 👏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants