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

Remove sleuthkit prebuilt library, link with copy built in osquery core #70

Open
chouchouzzj opened this issue Jan 5, 2021 · 1 comment
Labels
bug build Related to the build steps for our extensions

Comments

@chouchouzzj
Copy link

Well , base on #68

I add this code in file: cmake/flags.cmake
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>")

And then
cmake --config Release --build .
It works well.
and this following part works well too.
cmake --config RelWithDebInfo --build .

but, when I want to debug the code, errors come.
cmake --config Debug --build .

And here are the errors message( Same as #68) :
Libtsk.lib (db_sqlite. Obj) : Error LNK2038: "RuntimeLibrary" mismatch detected:Value "MT_StaticRelease" mismatch value "MTd_StaticDebug" (in osquery_extension_group_main.obj) [D:\build\External\extension_trailofbits\ trailofbits_osquery_extensions.vcxProj]
Libcpmt.lib (xstol. Obj) : Error LNK2038: "RuntimeLibrary" mismatch detected:Value "MT_StaticRelease" mismatch value "MTd_StaticDebug" (in osquery_extension_group_main.obj) [D:\build\External\extension_trailofbits\ trailofbits_osquery_extensions.vcxProj]

@mike-myers-tob mike-myers-tob added bug build Related to the build steps for our extensions labels Jan 5, 2021
@mike-myers-tob
Copy link
Contributor

Hi again @chouchouzzj – we think what is happening here is that we provided a precompiled SleuthKit library in our extension, and it was not a debug build binary, so you have linker errors with debug builds.

Since osquery now also builds the SleuthKit library, the fix here is for someone to link our extension(s) to that library rather than the one provided in the trailofbits-extensions repo, and we ought to remove our prebuilt one.

I can't provide a timeframe for when we will get that done, but it seems pretty straightforward.

@mike-myers-tob mike-myers-tob reopened this Jan 6, 2021
@mike-myers-tob mike-myers-tob changed the title Unable to build with "--config Debug" Remove sleuthkit prebuilt library, link with copy built in osquery core Jan 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug build Related to the build steps for our extensions
Projects
None yet
Development

No branches or pull requests

2 participants