thalium / icebox

Virtual Machine Introspection, Tracing & Debugging
MIT License
564 stars 86 forks source link

Complicated build #23

Closed eix128 closed 4 years ago

eix128 commented 4 years ago

Hi , i have tried to compile source as what you said from steps below: https://github.com/thalium/icebox/blob/master/doc/BUILD.gen.md#job-vbox_vmm-msvc

But these steps not really working. It would be good to make "Docker" for build automation.

I fixed it by these steps:

set QT_DIR=D:\Tools\Qt\5.12.3 set OPENSSL_DIR=D:\Tools\OpenSSL-Win64 set OPENSSL32_DIR=D:\Tools\OpenSSL-Win32 set CURL_DIR=D:\Tools\curl-7.69.1 set PYTHON_DIR=D:\Tools\Anaconda3 set SDL_LIB=D:\Tools\SDL-1.2.15

set LIB=D:\Tools\MSSDK\Windows\v7.1\Lib\x64;C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\lib\amd64 set INCLUDE=C:\Program Files (x86)\Microsoft Visual Studio

cscript configure.vbs --with-MinGW-w64="D:/Tools/VBox/mingw64" --with-MinGW32="D:/msys64/mingw32/i686-w64-mingw32" --with-libSDL="D:/Tools/SDL-1.2.15/x64" --with-openssl=%OPENSSL_DIR% --with-openssl32=%OPENSSL32_DIR% --with-qt5=%QT_DIR%/qtbase --with-python=c:/Python38 --with-libcurl=%CURL_DIR%/builds/libcurl-vc10-x64-release-dll-ipv6-sspi-winssl --with-libcurl32=%CURL_DIR%/builds/libcurl-vc10-x86-release-dll-ipv6-sspi-winssl --with-vc="C:/Program Files (x86)/Microsoft Visual Studio 10.0/VC" --with-openssl32="D:/Tools/VBox/vc-common-src/Common/Lib/openssl/10.0/x86" env kmk kmk VBoxVMM VBOX_WITHOUT_HARDENING=1 VBOX_WITH_ADDITIONS= VBOX_WITH_TESTCASES= VBOX_WITH_TESTSUITE= echo %INCLUDE% kmk VBoxVMM VBOX_WITHOUT_HARDENING=1 VBOX_WITH_ADDITIONS= VBOX_WITH_TESTCASES= VBOX_WITH_TESTSUITE= set INCLUDE=C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include;D:\Tools\MSSDK\Windows\v7.1\Include set LIB=D:\Tools\MSSDK\Windows\v7.1\Lib\x64;C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\lib\amd64 kmk VBoxVMM VBOX_WITHOUT_HARDENING=1 VBOX_WITH_ADDITIONS= VBOX_WITH_TESTCASES= VBOX_WITH_TESTSUITE=

Dont forget to include this include ammintrin.h to D:\Tools\MSSDK\Windows\v7.1\Include

/****

pragma once

ifndef __midl

ifndef _INCLUDED_AMM

define _INCLUDED_AMM

if defined(_M_CEE_PURE)

error ERROR: This file is not supported in the pure mode!

else

if defined __cplusplus

extern "C" { / Intrinsics use C name-mangling. /

endif

/*

define _MM_PCOMCTRL_LT 0

define _MM_PCOMCTRL_LE 1

define _MM_PCOMCTRL_GT 2

define _MM_PCOMCTRL_GE 3

define _MM_PCOMCTRL_EQ 4

define _MM_PCOMCTRL_NEQ 5

define _MM_PCOMCTRL_FALSE 6

define _MM_PCOMCTRL_TRUE 7

/*

define _mm_comlt_epu8(v1, v2) _mm_com_epu8(v1, v2, _MM_PCOMCTRL_LT)

define _mm_comle_epu8(v1, v2) _mm_com_epu8(v1, v2, _MM_PCOMCTRL_LE)

define _mm_comgt_epu8(v1, v2) _mm_com_epu8(v1, v2, _MM_PCOMCTRL_GT)

define _mm_comge_epu8(v1, v2) _mm_com_epu8(v1, v2, _MM_PCOMCTRL_GE)

define _mm_comeq_epu8(v1, v2) _mm_com_epu8(v1, v2, _MM_PCOMCTRL_EQ)

define _mm_comneq_epu8(v1, v2) _mm_com_epu8(v1, v2, _MM_PCOMCTRL_NEQ)

define _mm_comfalse_epu8(v1, v2) _mm_com_epu8(v1, v2, _MM_PCOMCTRL_FALSE)

define _mm_comtrue_epu8(v1, v2) _mm_com_epu8(v1, v2, _MM_PCOMCTRL_TRUE)

define _mm_comlt_epu16(v1, v2) _mm_com_epu16(v1, v2, _MM_PCOMCTRL_LT)

define _mm_comle_epu16(v1, v2) _mm_com_epu16(v1, v2, _MM_PCOMCTRL_LE)

define _mm_comgt_epu16(v1, v2) _mm_com_epu16(v1, v2, _MM_PCOMCTRL_GT)

define _mm_comge_epu16(v1, v2) _mm_com_epu16(v1, v2, _MM_PCOMCTRL_GE)

define _mm_comeq_epu16(v1, v2) _mm_com_epu16(v1, v2, _MM_PCOMCTRL_EQ)

define _mm_comneq_epu16(v1, v2) _mm_com_epu16(v1, v2, _MM_PCOMCTRL_NEQ)

define _mm_comfalse_epu16(v1, v2) _mm_com_epu16(v1, v2, _MM_PCOMCTRL_FALSE)

define _mm_comtrue_epu16(v1, v2) _mm_com_epu16(v1, v2, _MM_PCOMCTRL_TRUE)

define _mm_comlt_epu32(v1, v2) _mm_com_epu32(v1, v2, _MM_PCOMCTRL_LT)

define _mm_comle_epu32(v1, v2) _mm_com_epu32(v1, v2, _MM_PCOMCTRL_LE)

define _mm_comgt_epu32(v1, v2) _mm_com_epu32(v1, v2, _MM_PCOMCTRL_GT)

define _mm_comge_epu32(v1, v2) _mm_com_epu32(v1, v2, _MM_PCOMCTRL_GE)

define _mm_comeq_epu32(v1, v2) _mm_com_epu32(v1, v2, _MM_PCOMCTRL_EQ)

define _mm_comneq_epu32(v1, v2) _mm_com_epu32(v1, v2, _MM_PCOMCTRL_NEQ)

define _mm_comfalse_epu32(v1, v2) _mm_com_epu32(v1, v2, _MM_PCOMCTRL_FALSE)

define _mm_comtrue_epu32(v1, v2) _mm_com_epu32(v1, v2, _MM_PCOMCTRL_TRUE)

define _mm_comlt_epu64(v1, v2) _mm_com_epu64(v1, v2, _MM_PCOMCTRL_LT)

define _mm_comle_epu64(v1, v2) _mm_com_epu64(v1, v2, _MM_PCOMCTRL_LE)

define _mm_comgt_epu64(v1, v2) _mm_com_epu64(v1, v2, _MM_PCOMCTRL_GT)

define _mm_comge_epu64(v1, v2) _mm_com_epu64(v1, v2, _MM_PCOMCTRL_GE)

define _mm_comeq_epu64(v1, v2) _mm_com_epu64(v1, v2, _MM_PCOMCTRL_EQ)

define _mm_comneq_epu64(v1, v2) _mm_com_epu64(v1, v2, _MM_PCOMCTRL_NEQ)

define _mm_comfalse_epu64(v1, v2) _mm_com_epu64(v1, v2, _MM_PCOMCTRL_FALSE)

define _mm_comtrue_epu64(v1, v2) _mm_com_epu64(v1, v2, _MM_PCOMCTRL_TRUE)

define _mm_comlt_epi8(v1, v2) _mm_com_epi8(v1, v2, _MM_PCOMCTRL_LT)

define _mm_comle_epi8(v1, v2) _mm_com_epi8(v1, v2, _MM_PCOMCTRL_LE)

define _mm_comgt_epi8(v1, v2) _mm_com_epi8(v1, v2, _MM_PCOMCTRL_GT)

define _mm_comge_epi8(v1, v2) _mm_com_epi8(v1, v2, _MM_PCOMCTRL_GE)

define _mm_comeq_epi8(v1, v2) _mm_com_epi8(v1, v2, _MM_PCOMCTRL_EQ)

define _mm_comneq_epi8(v1, v2) _mm_com_epi8(v1, v2, _MM_PCOMCTRL_NEQ)

define _mm_comfalse_epi8(v1, v2) _mm_com_epi8(v1, v2, _MM_PCOMCTRL_FALSE)

define _mm_comtrue_epi8(v1, v2) _mm_com_epi8(v1, v2, _MM_PCOMCTRL_TRUE)

define _mm_comlt_epi16(v1, v2) _mm_com_epi16(v1, v2, _MM_PCOMCTRL_LT)

define _mm_comle_epi16(v1, v2) _mm_com_epi16(v1, v2, _MM_PCOMCTRL_LE)

define _mm_comgt_epi16(v1, v2) _mm_com_epi16(v1, v2, _MM_PCOMCTRL_GT)

define _mm_comge_epi16(v1, v2) _mm_com_epi16(v1, v2, _MM_PCOMCTRL_GE)

define _mm_comeq_epi16(v1, v2) _mm_com_epi16(v1, v2, _MM_PCOMCTRL_EQ)

define _mm_comneq_epi16(v1, v2) _mm_com_epi16(v1, v2, _MM_PCOMCTRL_NEQ)

define _mm_comfalse_epi16(v1, v2) _mm_com_epi16(v1, v2, _MM_PCOMCTRL_FALSE)

define _mm_comtrue_epi16(v1, v2) _mm_com_epi16(v1, v2, _MM_PCOMCTRL_TRUE)

define _mm_comlt_epi32(v1, v2) _mm_com_epi32(v1, v2, _MM_PCOMCTRL_LT)

define _mm_comle_epi32(v1, v2) _mm_com_epi32(v1, v2, _MM_PCOMCTRL_LE)

define _mm_comgt_epi32(v1, v2) _mm_com_epi32(v1, v2, _MM_PCOMCTRL_GT)

define _mm_comge_epi32(v1, v2) _mm_com_epi32(v1, v2, _MM_PCOMCTRL_GE)

define _mm_comeq_epi32(v1, v2) _mm_com_epi32(v1, v2, _MM_PCOMCTRL_EQ)

define _mm_comneq_epi32(v1, v2) _mm_com_epi32(v1, v2, _MM_PCOMCTRL_NEQ)

define _mm_comfalse_epi32(v1, v2) _mm_com_epi32(v1, v2, _MM_PCOMCTRL_FALSE)

define _mm_comtrue_epi32(v1, v2) _mm_com_epi32(v1, v2, _MM_PCOMCTRL_TRUE)

define _mm_comlt_epi64(v1, v2) _mm_com_epi64(v1, v2, _MM_PCOMCTRL_LT)

define _mm_comle_epi64(v1, v2) _mm_com_epi64(v1, v2, _MM_PCOMCTRL_LE)

define _mm_comgt_epi64(v1, v2) _mm_com_epi64(v1, v2, _MM_PCOMCTRL_GT)

define _mm_comge_epi64(v1, v2) _mm_com_epi64(v1, v2, _MM_PCOMCTRL_GE)

define _mm_comeq_epi64(v1, v2) _mm_com_epi64(v1, v2, _MM_PCOMCTRL_EQ)

define _mm_comneq_epi64(v1, v2) _mm_com_epi64(v1, v2, _MM_PCOMCTRL_NEQ)

define _mm_comfalse_epi64(v1, v2) _mm_com_epi64(v1, v2, _MM_PCOMCTRL_FALSE)

define _mm_comtrue_epi64(v1, v2) _mm_com_epi64(v1, v2, _MM_PCOMCTRL_TRUE)

/ SSE5 intrinsics /

/ Float/double multiply-accumulate / m128 _mm_macc_ps(m128, m128, m128); m128d _mm_macc_pd(m128d, m128d, m128d); m128 _mm_macc_ss(m128, m128, m128); m128d _mm_macc_sd(m128d, m128d, m128d); m128 _mm_maddsub_ps(m128, m128, m128); m128d _mm_maddsub_pd(m128d, m128d, m128d); m128 _mm_msubadd_ps(m128, m128, m128); m128d _mm_msubadd_pd(m128d, m128d, m128d); m128 _mm_msub_ps(m128, m128, m128); m128d _mm_msub_pd(m128d, m128d, m128d); m128 _mm_msub_ss(m128, m128, m128); m128d _mm_msub_sd(m128d, m128d, m128d); m128 _mm_nmacc_ps(m128, m128, m128); m128d _mm_nmacc_pd(m128d, m128d, m128d); m128 _mm_nmacc_ss(m128, m128, m128); m128d _mm_nmacc_sd(m128d, m128d, m128d); m128 _mm_nmsub_ps(m128, m128, m128); m128d _mm_nmsub_pd(m128d, m128d, m128d); m128 _mm_nmsub_ss(m128, m128, m128); m128d _mm_nmsub_sd(m128d, m128d, m128d);

/ Integer multiply-accumulate / m128i _mm_maccs_epi16(m128i, m128i, m128i); m128i _mm_macc_epi16(m128i, m128i, m128i); m128i _mm_maccsd_epi16(m128i, m128i, m128i); m128i _mm_maccd_epi16(m128i, m128i, m128i); m128i _mm_maccs_epi32(m128i, m128i, m128i); m128i _mm_macc_epi32(m128i, m128i, m128i); m128i _mm_maccslo_epi32(m128i, m128i, m128i); m128i _mm_macclo_epi32(m128i, m128i, m128i); m128i _mm_maccshi_epi32(m128i, m128i, m128i); m128i _mm_macchi_epi32(m128i, m128i, m128i); m128i _mm_maddsd_epi16(m128i, m128i, m128i); m128i _mm_maddd_epi16(m128i, m128i, m128i);

/ Horizontal add/subtract / m128i _mm_haddw_epi8(m128i); m128i _mm_haddd_epi8(m128i); m128i _mm_haddq_epi8(m128i); m128i _mm_haddd_epi16(m128i); m128i _mm_haddq_epi16(m128i); m128i _mm_haddq_epi32(m128i); m128i _mm_haddw_epu8(m128i); m128i _mm_haddd_epu8(m128i); m128i _mm_haddq_epu8(m128i); m128i _mm_haddd_epu16(m128i); m128i _mm_haddq_epu16(m128i); m128i _mm_haddq_epu32(m128i); m128i _mm_hsubw_epi8(m128i); m128i _mm_hsubd_epi16(m128i); __m128i _mm_hsubq_epi32(__m128i);

/ Vector conditional moves / m128i _mm_cmov_si128(m128i, m128i, m128i); m128i _mm_perm_epi8(m128i, m128i, m128i);

/ Vector shifts and rotates / m128i _mm_rot_epi8(m128i, m128i); __m128i _mm_rot_epi16(m128i, m128i); m128i _mm_rot_epi32(m128i, m128i); m128i _mm_rot_epi64(m128i, m128i); __m128i _mm_roti_epi8(m128i, int); m128i _mm_roti_epi16(m128i, int); m128i _mm_roti_epi32(m128i, int); m128i _mm_roti_epi64(m128i, int); m128i _mm_shl_epi8(m128i, m128i); m128i _mm_shl_epi16(m128i, m128i); m128i _mm_shl_epi32(m128i, m128i); __m128i _mm_shl_epi64(m128i, m128i); m128i _mm_sha_epi8(m128i, m128i); m128i _mm_sha_epi16(m128i, m128i); __m128i _mm_sha_epi32(m128i, m128i); m128i _mm_sha_epi64(m128i, m128i);

/ Vector integer comparisons /

m128i _mm_com_epu8(m128i, m128i, int); __m128i _mm_com_epu16(m128i, m128i, int); m128i _mm_com_epu32(m128i, m128i, int); m128i _mm_com_epu64(m128i, m128i, int); __m128i _mm_com_epi8(m128i, m128i, int); m128i _mm_com_epi16(m128i, m128i, int); m128i _mm_com_epi32(m128i, m128i, int); __m128i _mm_com_epi64(m128i, __m128i, int);

/ Precision control /

m128 _mm_frcz_ps(m128); m128d _mm_frcz_pd(m128d); m128 _mm_frcz_ss(m128, m128); __m128d _mm_frcz_sd(m128d, __m128d);

/ Control values for permute2 intrinsics /

define _MM_PERMUTE2_COPY 0 / just copy the selected value /

/ Note that using the constant 1 would have the same effect as 0 /

define _MM_PERMUTE2_ZEROIF1 2 / zero selected value if src3 bit is 1 /

define _MM_PERMUTE2_ZEROIF0 3 / zero selected value if src3 bit is 3 /

/ Permutation / m128 _mm_permute2_ps(m128, m128, m128i, int); m128d _mm_permute2_pd(m128d, m128d, m128i, int);

/ YMM versions / m256 _mm256_macc_ps(m256, m256, m256); m256d _mm256_macc_pd(m256d, m256d, m256d); m256 _mm256_maddsub_ps(m256, m256, m256); m256d _mm256_maddsub_pd(m256d, m256d, m256d); m256 _mm256_msubadd_ps(m256, m256, m256); m256d _mm256_msubadd_pd(m256d, m256d, m256d); m256 _mm256_msub_ps(m256, m256, m256); m256d _mm256_msub_pd(m256d, m256d, m256d); m256 _mm256_nmacc_ps(m256, m256, m256); m256d _mm256_nmacc_pd(m256d, m256d, m256d); m256 _mm256_nmsub_ps(m256, m256, m256); m256d _mm256_nmsub_pd(m256d, m256d, m256d); m256i _mm256_cmov_si256(m256i, m256i, m256i); m256 _mm256_frcz_ps(m256); m256d _mm256_frcz_pd(m256d); m256 _mm256_permute2_ps(m256, m256, m256i, int); __m256d _mm256_permute2_pd(m256d, m256d, __m256i, int);

/ LWP intrinsics / void llwpcb(void ); void slwpcb(); void lwpval32(unsigned int, unsigned int, unsigned int); void lwpval64(unsigned int64, unsigned int, unsigned int); unsigned char lwpins32(unsigned int, unsigned int, unsigned int); unsigned char lwpins64(unsigned int64, unsigned int, unsigned int);

if defined __cplusplus

}; / End "C" /

endif / __cplusplus /

endif / _M_CEE_PURE /

endif / INCLUDED_AMM /

endif / __midl /

bamiaux commented 4 years ago

Yes, building on windows is not easy. Did you follow instructions from here ? https://github.com/thalium/icebox/blob/master/doc/BUILD.md Those will work, if you use the same checksums. Unfortunately, I don't know how to do a windows container under Docker, so it's not possible. If you want to use it under Linux, it's much easier to build here