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

Fix Windows build process #11

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open

Conversation

vnescape
Copy link
Contributor

@vnescape vnescape commented Jan 5, 2025

When building NtRays for Windows, it tries to link against "idasdk90\lib\x64_win_vc_64\ida.lib.lib" which does not exist. Removing the .lib suffix in CMakeLists fixes the problem.

I have also updated the build instructions to make it easier to build the plugin.

@mrexodia
Copy link
Collaborator

mrexodia commented Jan 5, 2025

This happens because you need to pass an absolute path, now you broke that.

@vnescape
Copy link
Contributor Author

vnescape commented Jan 6, 2025

Can you specify to which paths, relative or absolute, -DIDA_SDK_DIR as well as -DHEXRAYS_SDK_DIR should be set then?

@mrexodia
Copy link
Collaborator

mrexodia commented Jan 6, 2025

I think I saw it wrong when looking at the changes to README initially. I would suggest to make sure both variables are expanded to relative paths before passing them to target_link_libraries

@vnescape
Copy link
Contributor Author

vnescape commented Jan 8, 2025

You probably mean extended to absolute paths, don't you? Perhaps you could describe how you would build the project on windows, giving idasdk90 which contains: bin, dbg, idalib etc.

@mrexodia
Copy link
Collaborator

mrexodia commented Jan 11, 2025

Took me a while, but finally had some time to try building master:

git submodule update --init
cmake -B build -DIDA_SDK_DIR:FILEPATH=c:\IDA90SP1\idasdk90 -DHEXRAYS_SDK_DIR:FILEPATH=c:\IDA90SP1\idasdk90
cmake --build build

I think things could be improved in a few ways:

  • Infer HEXRAYS_SDK_DIR if IDA_SDK_DIR/include/hexrays.hpp exists (since 9.0 these were merged)
  • Normalize IDA_SDK_DIR (and HEXRAYS_SDK_DIR) to always be an absolute path

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.

2 participants