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

ERROR while building winafl #420

Open
pmondon opened this issue Nov 21, 2023 · 1 comment
Open

ERROR while building winafl #420

pmondon opened this issue Nov 21, 2023 · 1 comment

Comments

@pmondon
Copy link

pmondon commented Nov 21, 2023

Hi, I have a problem when compiling Winafl and I don't understand at all where it comes from unfortunately,
Here is the output:
cmake -G"Visual Studio 16 2019" -A x64 .. -DDynamoRIO_DIR=C:\Users\User\Documents\folder\DynamoRIO-Windows-10.0.19678\DynamoRIO-Windows-10.0.19678\cmake
CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 3.5 will be removed from a future version of
CMake.

Update the VERSION argument value or use a ... suffix to tell
CMake that the project does not need compatibility with older versions.

-- Selecting Windows SDK version 10.0.19041.0 to target Windows 10.0.19045.
-- The C compiler identification is MSVC 19.29.30153.0
-- The CXX compiler identification is MSVC 19.29.30153.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Configuring done (6.8s)
-- Generating done (0.1s)
-- Build files have been written to: C:/Users/USER/Documents/folder/winafl/build64


cmake --build . --config Release
Microsoft (R) Build Engine version 16.11.2+f32259642 for .NET Framework
Copyright (C) Microsoft Corporation. All rights reserved.

1>Checking Build System
Building Custom Rule C:/Users/USER/Documents/folder/winafl/CMakeLists.txt
afl-analyze.c
afl-analyze.vcxproj -> C:\Users\USER\Documents\folder\winafl\build64\bin\Release\afl-analyze.exe
Building Custom Rule C:/Users/USER/Documents/folder/winafl/CMakeLists.txt
afl-fuzz.c
afl-fuzz.vcxproj -> C:\Users\USER\Documents\folder\winafl\build64\bin\Release\afl-fuzz.exe
Building Custom Rule C:/Users/USER/Documents/folder/winafl/CMakeLists.txt
afl-showmap.c
afl-showmap.vcxproj -> C:\Users\USER\Documents\folder\winafl\build64\bin\Release\afl-showmap.exe
Building Custom Rule C:/Users/USER/Documents/folder/winafl/CMakeLists.txt
afl-tmin.c
afl-tmin.vcxproj -> C:\Users\USER\Documents\folder\winafl\build64\bin\Release\afl-tmin.exe
Building Custom Rule C:/Users/USER/Documents/folder/winafl/CMakeLists.txt
custom_net_fuzzer.c
Creating library C:/Users/USER/Documents/folder/winafl/build64/Release/custom_net_fuzzer.lib and object C:/Users/USER/Documents/folder/winafl/build64/Release/cust
om_net_fuzzer.exp
custom_net_fuzzer.vcxproj -> C:\Users\USER\Documents\folder\winafl\build64\bin\Release\custom_net_fuzzer.dll
Building Custom Rule C:/Users/USER/Documents/folder/winafl/CMakeLists.txt
custom_winafl_server.c
Creating library C:/Users/USER/Documents/folder/winafl/build64/Release/custom_winafl_server.lib and object C:/Users/USER/Documents/folder/winafl/build64/Release/c
ustom_winafl_server.exp
custom_winafl_server.vcxproj -> C:\Users\USER\Documents\folder\winafl\build64\bin\Release\custom_winafl_server.dll
Building Custom Rule C:/Users/USER/Documents/folder/winafl/CMakeLists.txt
test.cpp
test.vcxproj -> C:\Users\USER\Documents\folder\winafl\build64\bin\Release\test.exe
Building Custom Rule C:/Users/USER/Documents/folder/winafl/CMakeLists.txt
gdiplus.cpp
test_gdiplus.vcxproj -> C:\Users\USER\Documents\folder\winafl\build64\bin\Release\test_gdiplus.exe
Building Custom Rule C:/Users/USER/Documents/folder/winafl/CMakeLists.txt
test_netmode.cpp
test_netmode.vcxproj -> C:\Users\USER\Documents\folder\winafl\build64\bin\Release\test_netmode.exe
Building Custom Rule C:/Users/USER/Documents/folder/winafl/CMakeLists.txt
test_simple_winsock_client.cpp
test_servermode.vcxproj -> C:\Users\USER\Documents\folder\winafl\build64\bin\Release\test_servermode.exe
Building Custom Rule C:/Users/USER/Documents/folder/winafl/CMakeLists.txt
winafl.c
C:\Users\USER\Documents\folder\winafl\winafl.c(460,50): error C2143: syntax error: missing ')' before 'type' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxp
roj]
C:\Users\USER\Documents\folder\winafl\winafl.c(460,50): error C2081: 'INOUT': name in formal parameter list illegal [C:\Users\USER\Documents\folder\winafl\build64\wina
fl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(460,61): error C2059: syntax error: ')' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(461,1): error C2085: 'user_data': not in formal parameter list [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcx
proj]
C:\Users\USER\Documents\folder\winafl\winafl.c(461,1): error C2143: syntax error: missing ';' before '{' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(505,44): error C2143: syntax error: missing ')' before 'type' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxp
roj]
C:\Users\USER\Documents\folder\winafl\winafl.c(505,44): error C2081: 'INOUT': name in formal parameter list illegal [C:\Users\USER\Documents\folder\winafl\build64\wina
fl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(505,55): error C2059: syntax error: ')' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(506,1): error C2085: 'user_data': not in formal parameter list [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcx
proj]
C:\Users\USER\Documents\folder\winafl\winafl.c(506,1): error C2143: syntax error: missing ';' before '{' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(594,51): error C2143: syntax error: missing ')' before 'type' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxp
roj]
C:\Users\USER\Documents\folder\winafl\winafl.c(594,51): error C2081: 'INOUT': name in formal parameter list illegal [C:\Users\USER\Documents\folder\winafl\build64\wina
fl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(594,62): error C2059: syntax error: ')' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(595,1): error C2085: 'user_data': not in formal parameter list [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcx
proj]
C:\Users\USER\Documents\folder\winafl\winafl.c(595,1): error C2143: syntax error: missing ';' before '{' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(602,51): error C2143: syntax error: missing ')' before 'type' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxp
roj]
C:\Users\USER\Documents\folder\winafl\winafl.c(602,51): error C2081: 'INOUT': name in formal parameter list illegal [C:\Users\USER\Documents\folder\winafl\build64\wina
fl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(602,62): error C2059: syntax error: ')' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(603,1): error C2085: 'user_data': not in formal parameter list [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcx
proj]
C:\Users\USER\Documents\folder\winafl\winafl.c(603,1): error C2143: syntax error: missing ';' before '{' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(610,62): error C2143: syntax error: missing ')' before 'type' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxp
roj]
C:\Users\USER\Documents\folder\winafl\winafl.c(610,62): error C2081: 'INOUT': name in formal parameter list illegal [C:\Users\USER\Documents\folder\winafl\build64\wina
fl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(610,73): error C2059: syntax error: ')' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(611,1): error C2085: 'user_data': not in formal parameter list [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcx
proj]
C:\Users\USER\Documents\folder\winafl\winafl.c(611,1): error C2143: syntax error: missing ';' before '{' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(621,48): error C2143: syntax error: missing ')' before 'type' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxp
roj]
C:\Users\USER\Documents\folder\winafl\winafl.c(621,48): error C2081: 'INOUT': name in formal parameter list illegal [C:\Users\USER\Documents\folder\winafl\build64\wina
fl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(621,59): error C2059: syntax error: ')' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(622,1): error C2085: 'user_data': not in formal parameter list [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcx
proj]
C:\Users\USER\Documents\folder\winafl\winafl.c(622,1): error C2143: syntax error: missing ';' before '{' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(628,44): error C2143: syntax error: missing ')' before 'type' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxp
roj]
C:\Users\USER\Documents\folder\winafl\winafl.c(628,44): error C2081: 'INOUT': name in formal parameter list illegal [C:\Users\USER\Documents\folder\winafl\build64\wina
fl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(628,55): error C2059: syntax error: ')' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(629,1): error C2085: 'user_data': not in formal parameter list [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcx
proj]
C:\Users\USER\Documents\folder\winafl\winafl.c(629,1): error C2143: syntax error: missing ';' before '{' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(635,69): error C2143: syntax error: missing ')' before 'type' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxp
roj]
C:\Users\USER\Documents\folder\winafl\winafl.c(635,69): error C2081: 'INOUT': name in formal parameter list illegal [C:\Users\USER\Documents\folder\winafl\build64\wina
fl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(635,80): error C2059: syntax error: ')' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(636,1): error C2085: 'user_data': not in formal parameter list [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcx
proj]
C:\Users\USER\Documents\folder\winafl\winafl.c(636,1): error C2143: syntax error: missing ';' before '{' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(637,54): warning C4311: 'type cast': pointer truncation from 'void *' to 'DWORD' [C:\Users\USER\Documents\folder\winafl
build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(638,16): error C2065: 'user_data': undeclared identifier [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(638,5): error C2100: illegal indirection [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(638,32): warning C4312: 'type cast': conversion from 'DWORD' to 'void *' of greater size [C:\Users\USER\Documents\folder
\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(638,32): warning C4047: '=': 'int' differs in levels of indirection from 'void *' [C:\Users\USER\Documents\folder\winafl
\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(644,37): warning C4311: 'type cast': pointer truncation from 'void *' to 'DWORD' [C:\Users\USER\Documents\folder\winafl
build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(656,68): error C2143: syntax error: missing ')' before 'type' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxp
roj]
C:\Users\USER\Documents\folder\winafl\winafl.c(656,68): error C2081: 'INOUT': name in formal parameter list illegal [C:\Users\USER\Documents\folder\winafl\build64\wina
fl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(656,79): error C2059: syntax error: ')' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(657,1): error C2085: 'user_data': not in formal parameter list [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcx
proj]
C:\Users\USER\Documents\folder\winafl\winafl.c(657,1): error C2143: syntax error: missing ';' before '{' [C:\Users\USER\Documents\folder\winafl\build64\winafl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(706,45): warning C4028: formal parameter 2 different from declaration [C:\Users\USER\Documents\folder\winafl\build64\win
afl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(710,51): warning C4028: formal parameter 2 different from declaration [C:\Users\USER\Documents\folder\winafl\build64\win
afl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(716,68): warning C4028: formal parameter 2 different from declaration [C:\Users\USER\Documents\folder\winafl\build64\win
afl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(718,59): warning C4028: formal parameter 2 different from declaration [C:\Users\USER\Documents\folder\winafl\build64\win
afl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(723,57): warning C4028: formal parameter 2 different from declaration [C:\Users\USER\Documents\folder\winafl\build64\win
afl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(725,57): warning C4028: formal parameter 2 different from declaration [C:\Users\USER\Documents\folder\winafl\build64\win
afl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(741,75): warning C4028: formal parameter 2 different from declaration [C:\Users\USER\Documents\folder\winafl\build64\win
afl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(743,74): warning C4028: formal parameter 2 different from declaration [C:\Users\USER\Documents\folder\winafl\build64\win
afl.vcxproj]
C:\Users\USER\Documents\folder\winafl\winafl.c(749,64): warning C4028: formal parameter 2 different from declaration [C:\Users\USER\Documents\folder\winafl\build64\win
afl.vcxproj]
modules.c
Generating Code...

@faran1512
Copy link

Go to winafl\build64 directory. Open the WinAFL.sln project in Visual Studio. On the solution explorer open winafl -> Soruce Files -> winafl.c. Now find INOUT in the winafl.c and remove all the INOUT keywords wherever you find them.

This way you can build the winafl. I thought it would break something but till now it is working fine. I can run the fuzzer, cmin, drrun all the good stuff.

But at the end it is just a work around and I hope it is fixed soon.

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