Unknown type name 'uint8_t' after update Xcode
-
-
I just checked on my Mac running Xcode 16.0 (Sonoma 14.6.1) the definition for uint8_t comes from this file:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/_types/_uint8_t.hThe file contains a single typedef:
typedef unsigned char uint8_t; -
EDIT:
Errors are gone after two steps:- Added
set(CMAKE_OSX_SYSROOT "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.sdk")
to top-level CMakeLists.txt; - In build configuration (Project options) changed value of
WrapOpenGL_AGL
to point to the right SDK (15 instead of 14.5).
I presume those would not be necessary once the proper update to Qt comes in, with support for the new SDK?
EDIT ENDS.
Weird errors after the update:
/Qt/Tools/CMake/CMake.app/Contents/share/cmake-3.29/Modules/Platform/Darwin-Initialize.cmake:308 (message): Ignoring CMAKE_OSX_SYSROOT value: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.5.sdk because the directory does not exist.
and
In file included from /Users/artwaw/Qt/6.7.2/macos/lib/QtSql.framework/Headers/QSqlRelationalTableModel:1: In file included from /Users/artwaw/Qt/6.7.2/macos/lib/QtSql.framework/Headers/qsqlrelationaltablemodel.h:7: In file included from /Users/artwaw/Qt/6.7.2/macos/lib/QtSql.framework/Headers/qtsqlglobal.h:11: /Users/artwaw/Qt/6.7.2/macos/lib/QtCore.framework/Headers/qglobal.h:13:12: fatal error: 'type_traits' file not found 13 | # include <type_traits>```
- Added
-
EDIT:
Errors are gone after two steps:- Added
set(CMAKE_OSX_SYSROOT "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.sdk")
to top-level CMakeLists.txt; - In build configuration (Project options) changed value of
WrapOpenGL_AGL
to point to the right SDK (15 instead of 14.5).
I presume those would not be necessary once the proper update to Qt comes in, with support for the new SDK?
EDIT ENDS.
Weird errors after the update:
/Qt/Tools/CMake/CMake.app/Contents/share/cmake-3.29/Modules/Platform/Darwin-Initialize.cmake:308 (message): Ignoring CMAKE_OSX_SYSROOT value: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX14.5.sdk because the directory does not exist.
and
In file included from /Users/artwaw/Qt/6.7.2/macos/lib/QtSql.framework/Headers/QSqlRelationalTableModel:1: In file included from /Users/artwaw/Qt/6.7.2/macos/lib/QtSql.framework/Headers/qsqlrelationaltablemodel.h:7: In file included from /Users/artwaw/Qt/6.7.2/macos/lib/QtSql.framework/Headers/qtsqlglobal.h:11: /Users/artwaw/Qt/6.7.2/macos/lib/QtCore.framework/Headers/qglobal.h:13:12: fatal error: 'type_traits' file not found 13 | # include <type_traits>```
@artwaw Thanks for reply! I followed your steps but still got an error.
- Added
-
I just checked on my Mac running Xcode 16.0 (Sonoma 14.6.1) the definition for uint8_t comes from this file:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/_types/_uint8_t.hThe file contains a single typedef:
typedef unsigned char uint8_t;@hskoglund I confirm.
-
@artwaw Thanks for reply! I followed your steps but still got an error.
@BushyAxis793 said in Unknown type name 'uint8_t' after update Xcode:
but still got an error
Please post the error...
-
@BushyAxis793 said in Unknown type name 'uint8_t' after update Xcode:
but still got an error
Please post the error...
-
This post is deleted!
-
I got a few new errors
-
At this point, you should try to build a dummy basic hello world using uint8_t without anything Qt in it to ensure that your setup is working.
-
At this point, you should try to build a dummy basic hello world using uint8_t without anything Qt in it to ensure that your setup is working.
@SGaist After created new project I got notification about new update available. I updated everything. I reopen my project and I have no more errors!
Thanks everyone for help!
Have a good day -
Great !
Then please mark the thread as solved so other forum users may know a solution has been found :-)
-