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 fails on Windows 8.1....missing yara.h file. #21

Open
GShepherdTC opened this issue Mar 17, 2017 · 2 comments
Open

Build fails on Windows 8.1....missing yara.h file. #21

GShepherdTC opened this issue Mar 17, 2017 · 2 comments

Comments

@GShepherdTC
Copy link

Trying to build yara-java on Windows 8.1/64 bit. Per the readme.md file, I installed the Windows 7 SDK (which went fine) and then when building, I get the following. I must be missing something as I don't see a yara.h file anywhere. You can I use Netbeans. I also just tried it directly in a command window running:

vcbuild /platform:x64 vs2008.vcproj release

And got the same set of errors:

Compiling...
yara-wrapper_structs.c
c:\users\gshepherd\documents\netbeansprojects\yara-java\target\native-build\src\yara-wrapper.h(4) : fatal error C1083: Cannot open include file: 'yara.h': No such file or directory
yara-wrapper.c
c:\users\gshepherd\documents\netbeansprojects\yara-java\target\native-build\src\yara-wrapper.h(4) : fatal error C1083: Cannot open include file: 'yara.h': No such file or directory
Build log was saved at "file://c:\Users\gshepherd\Documents\NetBeansProjects\yara-java\target\native-build\target\x64-release\obj\BuildLog.htm"
yara-wrapper - 2 error(s), 0 warning(s)

What am I missing?

@GShepherdTC
Copy link
Author

So...I see my issue is the same as the other issue open for this project. What I did to get pass it though do an initial "mvn clean install", let it fail. Then copy the files in:
\yara\libyara\include
to the directory:
yara-java\api\target\native-build\src\windows
As I see defined in the vc2008.vsproj file for the AdditionalIncludeDirectories:
(ProjectDir)\src\windows
and then run "mvn install" it gets farther. I get an actual C code issue:
\yara-java\target\native-build\src\windows\stdint.h(89) : error C2371: 'int64_t' : redefinition; different basic types
C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\include\wchar.h(479) : see declaration of 'int64_t'
Which is complaining about the typedef for int64_t. Not sure I want to go down that road to figure that out. Any help would be appreciated.

@GShepherdTC
Copy link
Author

More info, I did try https://github.com/siddharthTyagi/yara-java forked version. Used Master and had to apply the same fix (i.e. copy of those files) and then ran into the same typedef issue.

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

1 participant