We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 5082 - [Build Failure] using master + cmake
Summary: [Build Failure] using master + cmake
Status: WAITING
Alias: None
Product: SDL
Classification: Unclassified
Component: *don't know* (show other bugs)
Version: HG 2.1
Hardware: x86_64 Windows 10
: P2 critical
Assignee: Ryan C. Gordon
QA Contact: Sam Lantinga
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-04-10 18:31 UTC by stephane
Modified: 2020-04-14 10:50 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description stephane 2020-04-10 18:31:24 UTC
Building The SDL on master failes ith the error :
```
src\sensor\SDL_sensor.c(48): error C2059: syntax error: '}' 
src\sensor\SDL_sensor.c(88): warning C4034: sizeof returns 0 
src\sensor\SDL_sensor.c(104): warning C4034: sizeof returns 0 
```

and lots of these also

We've also noticed build failure using vcpkg --head on linux. don't know if this is related but it really seems to be a linkage failure (linking statically, working on non-head vcpkg) :
```
src/audio/sndio/SDL_sndioaudio.c:95: undefined reference to `sio_open'
src/audio/sndio/SDL_sndioaudio.c:96: undefined reference to `sio_close'
src/ase-2.0.10-c1be3add38/src/audio/sndio/SDL_sndioaudio.c:97: undefined reference to `sio_setpar'
src/ase-2.0.10-c1be3add38/src/audio/sndio/SDL_sndioaudio.c:98: undefined reference to `sio_getpar'

and lots of these also
Comment 1 Sam Lantinga 2020-04-13 15:21:47 UTC
It seems odd that sndio would be enabled on Windows builds? What build system are you using?

Can you try the latest code and see if the sensor build issue has been fixed?
Comment 2 stephane 2020-04-14 10:50:00 UTC
Hi ! 
Well, the sndio stuff happens only on linux

On windows, using w10 MSVC 2017
On linux, using Ubuntu 18.04 + vcpkg

Windows build still failing :

\SDL-mirror\src\sensor\windows\SDL_windowssensor.c(44): error C2374: 'SENSOR_DATA_TYPE_ANGULAR_VELOCITY_X_DEGREES_PER_SECOND': redefinition; multiple initialization \SDL-mirror\build\SDL2-static.vcxproj]
  C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\um\Sensors.h(405): note: see declaration of 'SENSOR_DATA_TYPE_ANGULAR_VELOCITY_X_DEGREES_PER_SECOND'
SDL-mirror\src\sensor\windows\SDL_windowssensor.c(45): error C2374: 'SENSOR_DATA_TYPE_ANGULAR_VELOCITY_Y_DEGREES_PER_SECOND': redefinition; multiple initialization \SDL-mirror\build\SDL2-static.vcxproj]
  C:\Program Files (x86)\Windows Kits\10\Include\10.0.17763.0\um\Sensors.h(406): note: see declaration of 'SENSOR_DATA_TYPE_ANGULAR_VELOCITY_Y_DEGREES_PER_SECOND'
\SDL-mirror\src\sensor\windows\SDL_windowssensor.c(46): error C2374: 'SENSOR_DATA_TYPE_ANGULAR_VELOCITY_Z_DEGREES_PER_SECOND': redefinition; multiple initialization \SDL-mirror\build\SDL2-static.vcxproj] 

Seems some symbol are already defined.
Comment 3 stephane 2020-04-14 10:50:24 UTC
Sorry, forgot to mention the build is done with latest master