Unknown type name 'uint8_t' after update Xcode
-
Hello. I have a problem with my Qt Project. I updated Xcode SDK to 15.0. When I try to build my project I got strange error:
And the file:
So I decided to check resource.h
I also noticed that I have unix instead of uint8_t
Any suggestions how can I fix my project?
Have a good day
BushyAxis793 -
C Christian Ehrlicher moved this topic from General and Desktop on
-
Hi,
Which version of Qt are you using ?
Did you completely nuke the build folder after the Xcode update ? -
Hi,
Which version of Qt are you using ?
Did you completely nuke the build folder after the Xcode update ?@SGaist Thanks for reply. I got Qt 6.5.0. And I didn’t remove build folder after Xcode update.
-
@hskoglund Thanks for reply. I will check and let you know.
-
@SGaist Thanks for reply. I got Qt 6.5.0. And I didn’t remove build folder after Xcode update.
@BushyAxis793 said in Unknown type name 'uint8_t' after update Xcode:
And I didn’t remove build folder after Xcode update
You should to do a complete rebuild
-
@BushyAxis793 said in Unknown type name 'uint8_t' after update Xcode:
And I didn’t remove build folder after Xcode update
You should to do a complete rebuild
@jsulm I deleted my debug folder and try build again. I got the same error.
-
@hskoglund Yes I got the same problem after upgrade Xcode to 16.0.
-
Do you have the same issue if you create a new project ?
-
-
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