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

Build failure if snappy is installed. #297

Open
MaddTheSane opened this issue Oct 6, 2023 · 3 comments
Open

Build failure if snappy is installed. #297

MaddTheSane opened this issue Oct 6, 2023 · 3 comments

Comments

@MaddTheSane
Copy link

If snappy is install via e.g. MacPorts, the build fails. This could be because the project either includes Snappy or headers named Snappy's public headers.

@nillerusr
Copy link
Owner

What compiler version are you using? That shouldn't be a problem.

source-engine git:(master) ✗ grep -rn "#include.*snappy" *
engine/common.cpp:46:#include "tier1/snappy.h"
public/tier1/snappy.h:52:#include "snappy-stubs-public.h"
tier1/snappy-internal.h:34:#include "snappy-stubs-internal.h"
tier1/snappy-sinksource.cpp:31:#include "snappy-sinksource.h"
tier1/snappy-stubs-internal.cpp:35:#include "snappy-stubs-internal.h"
tier1/snappy-stubs-internal.h:50:#include "snappy-stubs-public.h"
tier1/snappy.cpp:29:#include "snappy.h"
tier1/snappy.cpp:30:#include "snappy-internal.h"
tier1/snappy.cpp:31:#include "snappy-sinksource.h"

When file included like that( #include <> )compiler should search first in system headers.
When file included like that( #include "" ) compiler should search in user-defined include search path.

Can you provide build log?

@MaddTheSane
Copy link
Author

Build log: snappybuildfailure.log

@MaddTheSane
Copy link
Author

The reason for the failure is because I include -I/opt/local/include to work around another issue if I'm building with MacPorts: it tries to use MacPorts' libiconv library, but not MacPorts' libiconv header.

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

No branches or pull requests

2 participants