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

MSYS2 (MINGWS64) build issues #16

Open
nistunedev opened this issue Nov 5, 2022 · 5 comments
Open

MSYS2 (MINGWS64) build issues #16

nistunedev opened this issue Nov 5, 2022 · 5 comments

Comments

@nistunedev
Copy link

Build issues from g++.exe (Rev4, Built by MSYS2 project) 12.2.0 when using Nislib as part of a C++ project

cli_utils/md5/md5.c
-#include <md5.h>
+#include "md5.h"

nislib.c (Line 207)
error: expected primary-expression before 'xor' token

@fenugrec
Copy link
Owner

fenugrec commented Nov 5, 2022

yeah, you can't always just compile C code as C++.

If you want to use nissutils from a c++ app you may need to add some extern C { ... directives

@nistunedev
Copy link
Author

First error also happens if building using the standard makefile using just gcc (same version 12.2.0) inside MSYS/MINGW. I ended up taking the bits I needed from nislib and compiling into a static library and linking that in for now

@fenugrec
Copy link
Owner

fenugrec commented Nov 5, 2022

any reason you're not adapting the cmake files ? cmake should add the correct -I... gcc flags automatically , regardless of platform + compiler combo

@fenugrec
Copy link
Owner

fenugrec commented Nov 6, 2022

BTW, I'm glad you find nisprog + npkern + nissutils useful in your software, but remember it's GPL-licensed which has certain restrictions and requirements regarding using modified source code.

@nistunedev
Copy link
Author

Thanks. Will look into cmake. Using this the functions to decode later CAN DAT files in a standalone utility. Aware of GPL restrictions and no parts used in commercial software.

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