-
Notifications
You must be signed in to change notification settings - Fork 485
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
[BUG] flex package installs include files to /usr/include, not /mingw64/include #1911
Comments
@xobs flex package is MSYS package and it install everything to /usr. MINGW packages installs everything to /mingw*. So there are no bug |
Should /usr/include be part of the default include path? I filed a bug against mingw, and they said this is an msys problem. The issue is that I've installed flex inside msys (or is it inside mingw64? I'm so confused now.) I have a project that includes FlexLexer.h, however it says it cannot find that file unless I add |
@xobs you can’t add /use/include to include path for MINGW GCC as it would break build because this path contains headers for MSYS GCC |
I think I understand. I'm still very confused as to what I'm using, whether it's msys2, msys, or mingw64. I'm running Furthermore, Inside that terminal, somehow Did the mingw64 project create /mingw64/bin/gcc.exe, or did the msys2 project create that and the directory is improperly named? And is the flex package maintained by the msys project, or msys2? |
@xobs this is MSYS2 project so there are nothing about MSYS and MINGW from mingw.org. |
@Alexpux If there is no bug here, then how does one successfully use |
Let me ask you this, how did you install flex? What was the command you used? Edit: Never mind there is only one flex package and it's compiled using msys2 gcc not mingw gcc and thus wouldn't be usable in mingw gcc at all, it would need to be natively compiled to windows using mingw gcc/clang for what you want to use it for. |
Just for completeness, the command that installed I later tried building
|
That's because it's trying to use POSIX functions that are not available for Windows and you'd have to supplement the code to make it work within windows unfortunately. |
So is the conclusion that |
flex has been ported to MSYS2. It has not been ported to mingw-w64. |
that is build using the cygwin based msys toolchain and not mingw-w64 (meaning it has access to all the posix features cygwin provides) |
several mingw-w64 packages successfully makedepend on flex, so there must be some way to use it without library/headers. |
Having spent some time working with It turns out that As for So what does that mean for this bug? I think there is a bug here, namely that |
Copying a file to be searchable by a mingw compiler is not really an option, ideally the best option would be to make the package native that way it can be made available to applicable toolchains in the repositories |
It was already answer in previous comments.
|
This doesn't tell me how to compile my project. |
Please create a new issue or discussion with your problem and steps to reproduce it. |
I know this is an old issue, but if you run into this and need a workaround that wasn't directly stated in the previous comments:
If you're trying to
|
Most include files appear to go into
/mingw64/include
or/mingw32/include
, however the flex package installs its include files to/usr/include/
. This path is not part of the gcc default include path, as evidenced byecho | gcc -E -Wp,-v -
flex should install its include files to
/mingw64/include
to avoid having to add-I/usr/include
to the build.The text was updated successfully, but these errors were encountered: