Skip to content

quic: attempting to fix non-linux QUIC builds#18027

Merged
mattklein123 merged 7 commits intoenvoyproxy:mainfrom
alyssawilk:quic_build
Sep 10, 2021
Merged

quic: attempting to fix non-linux QUIC builds#18027
mattklein123 merged 7 commits intoenvoyproxy:mainfrom
alyssawilk:quic_build

Conversation

@alyssawilk
Copy link
Copy Markdown
Contributor

Upstream HTTP/3 android build is breaking becasue the udp gso libraries are bazel-selected out but the includes aren't:
https://github.com/envoyproxy/envoy-mobile/pull/1717/checks?check_run_id=3487450075

I think this will fix (or at least get us to the next compile error)

Risk Level: low
Testing: n/a
Docs Changes: n/a
Release Notes: n/a
Platform Specific Features: hopefully fixing android build

Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
@alyssawilk
Copy link
Copy Markdown
Contributor Author

api_compat failure is a known failure (which I can merge past)

Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
#pragma GCC diagnostic ignored "-Wsuggest-override"
#endif

#if defined(__linux__)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Does this fix the build? There are other places in this file refers to quic classes.
Why not excluding this header file completely in the BUILD if the platform is not Linux?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

right, sorry, I had commented out most of the file in a prior build which got lost.

So I can add that back, moving the endif to the bottom of the file, or we could have one file for setting UDP_GSO_BATCH_WRITER_COMPILETIME_SUPPORT and a second file for use of it.

which would you prefer?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I'm okay either way, maybe the latter is easier to understand?

Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
#include "source/common/quic/gso_defines.h"
#endif // ENVOY_ENABLE_QUIC

#ifdef UDP_GSO_BATCH_WRITER_COMPILETIME_SUPPORT
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

If you #ifdef UDP_GSO_BATCH_WRITER_COMPILETIME_SUPPORT in udp_gso_batch_writer.h, this ifdef is not needed.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

well right now the file is compile-selected out in the build.
we could leave it in the build and #ifdef out the whole contents, but this seems cleaner to me?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

also I'm super baffled by windows breakage

source/server/listener_impl.cc(39): fatal error C1083: Cannot open include file: 'source/common/quic/udp_gso_batch_writer.h': No such file or directory

but it should only see that if UDP_GSO_BATCH_WRITER_COMPILETIME_SUPPORT is 1 which should only happen on linux? What am missing? :-/

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

oops nm, PEBKAC, fixed.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Agreed this is cleaner. I'm fine either way.
BTW, udp_gso_batch_writer.h is already ifdef'ing out the whole contents, isn't it?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

uggggh, you're totally right, which means I've been attacking the wrong problem from the start.
Thanks for saving me the commit + mobile update + realizing this didn't solve my problem
trying a new workaround per your offline suggestions!

Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
#include "source/common/quic/udp_gso_batch_writer.h"
#endif


Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

extra line?

danzh2010
danzh2010 previously approved these changes Sep 9, 2021
Signed-off-by: Alyssa Wilk <alyssar@chromium.org>
@mattklein123 mattklein123 merged commit 2f22d78 into envoyproxy:main Sep 10, 2021
@alyssawilk alyssawilk deleted the quic_build branch February 28, 2022 21:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants