gpt4 book ai didi

macos - 在 Mac 上构建 GLSDK - 找不到 platform.h

转载 作者:行者123 更新时间:2023-12-01 02:27:44 24 4
gpt4 key购买 nike

我正在尝试在 mac 上构建 GLSDK。
我下载了源码,做了premake4 xcode3它为 xcode 创建了所有项目文件。
现在我正在尝试构建所有东西,设法构建 glload、glimg、glutil、glmesh 就好了,我已经从 XQuartz 包中获得了 freeglut,所以我想我不需要构建 glsdk 中包含的那个。

当我尝试构建 glfw 时出现问题:

Wojciechs-MacBook-Air:glfw wojciechmusialkiewicz$ xcodebuild
=== BUILD NATIVE TARGET glfw OF PROJECT glfw WITH THE DEFAULT CONFIGURATION (Debug) ===
Check dependencies

CompileC obj/Debug/glfw.build/Objects-normal/x86_64/enable.o lib/enable.c normal x86_64 c com.apple.compilers.llvm.clang.1_0.compiler
cd /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw
setenv LANG en_US.US-ASCII
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x c -arch x86_64 -fmessage-length=0 -std=gnu99 -Wno-trigraphs -fpascal-strings -O0 -Wno-missing-field-initializers -Wno-missing-prototypes -Wreturn-type -Wformat -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wno-empty-body -Wno-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wno-constant-conversion -Wno-int-conversion -Wno-enum-conversion -Wno-shorten-64-to-32 -Wpointer-sign -Wno-newline-eof -D_CRT_SECURE_NO_WARNINGS -D_SCL_SECURE_NO_WARNINGS -D_LIB -D_DEBUG -fasm-blocks -fstrict-aliasing -Wdeprecated-declarations -g -Wno-sign-conversion -iquote /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-generated-files.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-own-target-headers.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-all-target-headers.hmap -iquote /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-project-headers.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/library/include -Iinclude -Ilib -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/DerivedSources/x86_64 -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/DerivedSources -F/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/library -MMD -MT dependencies -MF /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/enable.d --serialize-diagnostics /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/enable.dia -c /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/lib/enable.c -o /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/enable.o
In file included from /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/lib/enable.c:31:
lib/internal.h:92:10: fatal error: 'platform.h' file not found
#include "platform.h"
^
1 error generated.

CompileC obj/Debug/glfw.build/Objects-normal/x86_64/glext.o lib/glext.c normal x86_64 c com.apple.compilers.llvm.clang.1_0.compiler
cd /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw
setenv LANG en_US.US-ASCII
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x c -arch x86_64 -fmessage-length=0 -std=gnu99 -Wno-trigraphs -fpascal-strings -O0 -Wno-missing-field-initializers -Wno-missing-prototypes -Wreturn-type -Wformat -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wno-empty-body -Wno-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wno-constant-conversion -Wno-int-conversion -Wno-enum-conversion -Wno-shorten-64-to-32 -Wpointer-sign -Wno-newline-eof -D_CRT_SECURE_NO_WARNINGS -D_SCL_SECURE_NO_WARNINGS -D_LIB -D_DEBUG -fasm-blocks -fstrict-aliasing -Wdeprecated-declarations -g -Wno-sign-conversion -iquote /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-generated-files.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-own-target-headers.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-all-target-headers.hmap -iquote /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-project-headers.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/library/include -Iinclude -Ilib -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/DerivedSources/x86_64 -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/DerivedSources -F/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/library -MMD -MT dependencies -MF /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/glext.d --serialize-diagnostics /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/glext.dia -c /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/lib/glext.c -o /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/glext.o
In file included from /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/lib/glext.c:31:
lib/internal.h:92:10: fatal error: 'platform.h' file not found
#include "platform.h"
^
1 error generated.

CompileC obj/Debug/glfw.build/Objects-normal/x86_64/image.o lib/image.c normal x86_64 c com.apple.compilers.llvm.clang.1_0.compiler
cd /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw
setenv LANG en_US.US-ASCII
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x c -arch x86_64 -fmessage-length=0 -std=gnu99 -Wno-trigraphs -fpascal-strings -O0 -Wno-missing-field-initializers -Wno-missing-prototypes -Wreturn-type -Wformat -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wno-empty-body -Wno-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wno-constant-conversion -Wno-int-conversion -Wno-enum-conversion -Wno-shorten-64-to-32 -Wpointer-sign -Wno-newline-eof -D_CRT_SECURE_NO_WARNINGS -D_SCL_SECURE_NO_WARNINGS -D_LIB -D_DEBUG -fasm-blocks -fstrict-aliasing -Wdeprecated-declarations -g -Wno-sign-conversion -iquote /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-generated-files.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-own-target-headers.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-all-target-headers.hmap -iquote /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-project-headers.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/library/include -Iinclude -Ilib -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/DerivedSources/x86_64 -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/DerivedSources -F/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/library -MMD -MT dependencies -MF /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/image.d --serialize-diagnostics /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/image.dia -c /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/lib/image.c -o /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/image.o
In file included from /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/lib/image.c:56:
lib/internal.h:92:10: fatal error: 'platform.h' file not found
#include "platform.h"
^
1 error generated.

CompileC obj/Debug/glfw.build/Objects-normal/x86_64/fullscreen.o lib/fullscreen.c normal x86_64 c com.apple.compilers.llvm.clang.1_0.compiler
cd /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw
setenv LANG en_US.US-ASCII
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -x c -arch x86_64 -fmessage-length=0 -std=gnu99 -Wno-trigraphs -fpascal-strings -O0 -Wno-missing-field-initializers -Wno-missing-prototypes -Wreturn-type -Wformat -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wno-empty-body -Wno-uninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-conversion -Wno-constant-conversion -Wno-int-conversion -Wno-enum-conversion -Wno-shorten-64-to-32 -Wpointer-sign -Wno-newline-eof -D_CRT_SECURE_NO_WARNINGS -D_SCL_SECURE_NO_WARNINGS -D_LIB -D_DEBUG -fasm-blocks -fstrict-aliasing -Wdeprecated-declarations -g -Wno-sign-conversion -iquote /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-generated-files.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-own-target-headers.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-all-target-headers.hmap -iquote /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/glfwD-project-headers.hmap -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/library/include -Iinclude -Ilib -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/DerivedSources/x86_64 -I/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/DerivedSources -F/Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/library -MMD -MT dependencies -MF /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/fullscreen.d --serialize-diagnostics /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/fullscreen.dia -c /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/lib/fullscreen.c -o /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/obj/Debug/glfw.build/Objects-normal/x86_64/fullscreen.o
In file included from /Users/wojciechmusialkiewicz/glsdk_0.4.4/glfw/lib/fullscreen.c:31:
lib/internal.h:92:10: fatal error: 'platform.h' file not found
#include "platform.h"
^
1 error generated.


** BUILD FAILED **


The following build commands failed:
CompileC obj/Debug/glfw.build/Objects-normal/x86_64/enable.o lib/enable.c normal x86_64 c com.apple.compilers.llvm.clang.1_0.compiler
CompileC obj/Debug/glfw.build/Objects-normal/x86_64/glext.o lib/glext.c normal x86_64 c com.apple.compilers.llvm.clang.1_0.compiler
CompileC obj/Debug/glfw.build/Objects-normal/x86_64/image.o lib/image.c normal x86_64 c com.apple.compilers.llvm.clang.1_0.compiler
CompileC obj/Debug/glfw.build/Objects-normal/x86_64/fullscreen.o lib/fullscreen.c normal x86_64 c com.apple.compilers.llvm.clang.1_0.compiler
(4 failures)

我试过在谷歌上搜索这个 platform.h文件是,但没有明确的答案,即使它存在于 MacOS 上 - 我在我的计算机上找不到它,所以我想它不是。
有人知道发生了什么吗?

最佳答案

有一个glfw.lua glfw 中的文件文件夹。打开它并为“ macosx ”进行配置,然后将目录“lib/cocoa ”添加到包含目录中。我还定义了 _GLFW_COCOA , _GLFW_NSGL , 和 _GLFW_USE_OPENGL

关于macos - 在 Mac 上构建 GLSDK - 找不到 platform.h,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15064257/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com