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

Build darwin target fail on Windows 10 host XCode 14.3 #187

Open
vinser opened this issue Apr 22, 2023 · 17 comments
Open

Build darwin target fail on Windows 10 host XCode 14.3 #187

vinser opened this issue Apr 22, 2023 · 17 comments

Comments

@vinser
Copy link

vinser commented Apr 22, 2023

Describe the bug:

Cross compilation with MacOSX13.3.sdk failed with error
could not package the Fyne app: could not package the Fyne app: exit status 1
Old chap MacOSX11.3.sdk does it well

To Reproduce:

Steps to reproduce the behaviour:

  1. Extracted SDK fyne-cross darwin-sdk-extract --xcode-path c:\MyDev\macOS\XC14.3\Command_Line_Tools_for_Xcode_14.3.dmg
  2. Compiled with fyne-cross darwin -macosx-sdk-path="C:\MyDev\macOS\XC14.3\SDKs\MacOSX13.3.sdk" >xc14.3.log
  3. Got
[i] Target: darwin/amd64
[i] Cleaning target directories...
[✓] "temp" dir cleaned: /app/fyne-cross/tmp/darwin-amd64
[✓] "bin" dir cleaned: /app/fyne-cross/bin/darwin-amd64
[✓] "dist" dir cleaned: /app/fyne-cross/dist/darwin-amd64
[i] Checking for go.mod: C:\MyDev\pixyne\go.mod
[✓] go.mod found
[i] Packaging app...
[✗] could not package the Fyne app: could not package the Fyne app: exit status 1
  1. xc14.3.log attached

Example code:

Device and debug info (please complete the following information):

Device info
  • OS: Windows 10 Pro
  • Version: 22H2
  • Go version: go1.20.3 windows/amd64
  • fyne-cross version: v1.4.0
  • Fyne version: v2.3.1
Debug info
[xc14.3.log](https://github.com/fyne-io/fyne-cross/files/11301516/xc14.3.log)
@wudimenghuan
Copy link

systray_darwin.m:1:9: fatal error: 'Cocoa/Cocoa.h' file not found

@andydotxyz
Copy link
Member

systray_darwin.m:1:9: fatal error: 'Cocoa/Cocoa.h' file not found

This doesn't look like a fyne_cross log - is there surrounding info missing? Or does this refer to fyne instead of fyne_cross

@vorlif
Copy link

vorlif commented Jun 20, 2023

Hey, I have the same problem on Linux.

Logfile from @vinser xc14.3.log
Logfile from me log.txt

@Bluebugs
Copy link
Contributor

I think I have seen this issue, but haven't had time investigating it. Switching to an older release of the sdk solve the problem. If I remember there is two of them in the package distributed by Apple.

@zwindler
Copy link
Contributor

same here (ubuntu 22.04)

I've tried SDKs 12.4, 12.5.1, 13.4 and 14.3.1

@andydotxyz
Copy link
Member

Are you able to provide the error info or debug log?

@zwindler
Copy link
Contributor

zwindler commented Aug 5, 2023

Sure, sorry for not doing it in the first place

OS: Ubuntu 22.04
go version : 1.18.1

When trying to use Command_Line_Tools_for_Xcode_14.3.1.dmg, extraction seem OK

fyne-cross darwin-sdk-extract --xcode-path /home/zwindler/sources/gocastle/bin/Command_Line_Tools_for_Xcode_14.3.1.dmg
[i] Checking for a newer version of the docker image: fyneio/fyne-cross-images:darwin-sdk-extractor
[✓] Image is up to date
[i] Extracting SDKs from "Command_Line_Tools_for_Xcode_14.3.1.dmg", please wait it could take a while...
4890813 blocks
821231 blocks
958238 blocks
1035535 blocks
2 blocks
[✓] SDKs extracted to: /home/zwindler/sources/gocastle/bin/SDKs

And 12.4, too, even though there are some messages from cpio (directory was cleaned before doing extraction)

fyne-cross darwin-sdk-extract --xcode-path /home/zwindler/sources/gocastle/bin/Command_Line_Tools_for_Xcode_12.4.dmg 
[i] Checking for a newer version of the docker image: fyneio/fyne-cross-images:darwin-sdk-extractor
[✓] Image is up to date
[i] Extracting SDKs from "Command_Line_Tools_for_Xcode_12.4.dmg", please wait it could take a while...
3211668 blocks
707176 blocks
1007757 blocks
2 blocks
cpio: ./private/tmp/.BBE72B41371180178E084EEAF106AED4F350939DB95D3516864A1CC62E7AE82F not created: newer or same age version exists
2 blocks
cpio: ./private/tmp/.BBE72B41371180178E084EEAF106AED4F350939DB95D3516864A1CC62E7AE82F not created: newer or same age version exists
2 blocks
cpio: ./private/tmp/.BBE72B41371180178E084EEAF106AED4F350939DB95D3516864A1CC62E7AE82F not created: newer or same age version exists
2 blocks
cpio: ./private/tmp/.BBE72B41371180178E084EEAF106AED4F350939DB95D3516864A1CC62E7AE82F not created: newer or same age version exists
2 blocks
cpio: ./private/tmp/.BBE72B41371180178E084EEAF106AED4F350939DB95D3516864A1CC62E7AE82F not created: newer or same age version exists
2 blocks
cpio: ./private/tmp/.BBE72B41371180178E084EEAF106AED4F350939DB95D3516864A1CC62E7AE82F not created: newer or same age version exists
2 blocks
2 blocks
[✓] SDKs extracted to: /home/zwindler/sources/gocastle/bin/SDKs

I'm attaching the logs from the fyne-cross darwin build from both SDKs

fyne-cross darwin -arch=amd64 --macosx-sdk-path /home/zwindler/sources/gocastle/bin/SDKs -app-id fr.zwindler.gocastle
fyne-cross darwin -arch=amd64 --macosx-sdk-path /home/zwindler/sources/gocastle/bin/SDKs -app-id fr.zwindler.gocastle 

12.4.log
14.3.1.log

Since readme tells to use a SDK >= 12.4 I haven't tried an older one

@Bluebugs
Copy link
Contributor

Bluebugs commented Aug 8, 2023

I haven't tried this latest SDK, but is it possible that Apple has removed the distribution of Cocoa.h?

@andydotxyz
Copy link
Member

For Xcode 14.2, macOS SDK 13.1 the file is found at:

/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Cocoa.framework/Versions/A/Headers/Cocoa.h

@andydotxyz
Copy link
Member

--macosx-sdk-path /home/zwindler/sources/gocastle/bin/SDKs

This command parameter does not look correct - it is almost certainly not a macOS SDK path as it is on a linux computer!
I may be wrong, but I think that parameter is for when you are running on macOS and want to use a local SDK. To use from Linux the sdk must be extracted into an image using the darwin-sdk-extract command before fyne-cross darwin will work. (like @vinser did in the original report)

@zwindler
Copy link
Contributor

zwindler commented Aug 10, 2023

If you look at my message, you will see that I did the extract just before

fyne-cross darwin-sdk-extract --xcode-path /home/zwindler/sources/gocastle/bin/Command_Line_Tools_for_Xcode_12.4.dmg

This creates the /home/zwindler/sources/gocastle/bin/SDKs path

But maybe I misunderstood the readme and I'm missing a step?

@andydotxyz
Copy link
Member

Ah apologies, I was confusing it with "bundled" option it seems. I missed that you had extracted it before. Are you certain that the SDK dir is the root of the extraction? Can you list what is in that directory?

@zwindler
Copy link
Contributor

There is no apologies needed, thanks for trying to help

I don't have my computer with me right now but I'll dig in that direction and get back to you

Thanks again

@zwindler
Copy link
Contributor

zwindler commented Aug 25, 2023

Ok, I had never listed the directory and now I understand what someone meant somewhere in the issue or another duplicate one.

The SDKs directory that is extracted by fyne-cross darwin-sdk-extract contains more than one SDK. And that's one of thosse you have to target.

ls -l /home/zwindler/sources/gocastle/bin/SDKs.12.4/
total 9
drwx------ 1 zwindler zwindler 4096 août   5 23:00 MacOSX10.15.sdk
drwx------ 1 zwindler zwindler 4096 août   5 23:00 MacOSX11.1.sdk
lrwxrwxrwx 1 zwindler zwindler   14 août   5 23:00 MacOSX.sdk -> MacOSX11.1.sdk

ls -l /home/zwindler/sources/gocastle/bin/SDKs.14.3.1/
total 14
drwx------ 1 zwindler zwindler 4096 août   5 23:04 MacOSX12.3.sdk
lrwxrwxrwx 1 zwindler zwindler   14 août   5 23:04 MacOSX12.sdk -> MacOSX12.3.sdk
drwx------ 1 zwindler zwindler 4096 août   5 23:05 MacOSX13.3.sdk
lrwxrwxrwx 1 zwindler zwindler   14 août   5 23:04 MacOSX13.sdk -> MacOSX13.3.sdk
lrwxrwxrwx 1 zwindler zwindler   14 août   5 23:05 MacOSX.sdk -> MacOSX13.3.sdk

Sorry for the missunderstanding. So now that I understand that I have to tell fyne-cross which of those SDKs I want to use, I can now do some tests with various versions of the SDK.

MacOSX11.1.sdk seems to work (though I don't have a Mac to try it), and so does MacOSX12.3.sdk (from Command_Line_Tools_for_Xcode_12.4.dmg and Command_Line_Tools_for_Xcode_14.3.1.dmg respectively)

fyne-cross darwin -arch=amd64 --macosx-sdk-path /home/zwindler/sources/gocastle/bin/SDKs.12.4/MacOSX.sdk -app-id fr.zwindler.gocastle 
[i] Target: darwin/amd64
...
[✓] Package: "/home/zwindler/sources/gocastle/fyne-cross/dist/darwin-amd64/gocastle.app"

yne-cross darwin -arch=amd64 --macosx-sdk-path /home/zwindler/sources/gocastle/bin/SDKs.14.3.1/MacOSX12.3.sdk -app-id fr.zwindler.gocastle 
[i] Target: darwin/amd64
...
[✓] Package: "/home/zwindler/sources/gocastle/fyne-cross/dist/darwin-amd64/gocastle.app"

However, MacOSX13.3.sdk doesn't

warning(link): unknown filetype for a library: '/sdk/usr/lib/libobjc.tbd'^M
warning(link): unknown filetype for a library: '/sdk/usr/lib/libSystem.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/Foundation.framework/Foundation.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/Foundation.framework/Foundation.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/Foundation.framework/Foundation.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/UserNotifications.framework/UserNotifications.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/Foundation.framework/Foundation.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/AppKit.framework/AppKit.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/Cocoa.framework/Cocoa.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/IOKit.framework/IOKit.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/CoreVideo.framework/CoreVideo.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/OpenGL.framework/OpenGL.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/Cocoa.framework/Cocoa.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/OpenGL.framework/OpenGL.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/OpenGL.framework/OpenGL.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/OpenGL.framework/OpenGL.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation.tbd'^M
warning(link): unknown filetype for a library: '/sdk/System/Library/Frameworks/Security.framework/Security.tbd'^M
error(link): undefined reference to symbol 'dyld_stub_binder'^M
error: UndefinedSymbolReference^M

I'll attach the full log

@zwindler
Copy link
Contributor

zwindler commented Aug 25, 2023

Here is the log

SDKs.14.3.1_MacOSX13.3.sdk.log

Though I'm totally fine with using SDKs.14.3.1/MacOSX12.3.sdk, which works

Many thanks for your help again


[Edit] Contrary to what I just said, SDKs.14.3.1/MacOSX12.3.sdk only works on amd64. It fails for arm64. But SDKs.12.4/MacOSX.sdk seems ok for both

In file included from /go/pkg/mod/github.com/go-gl/glfw/v3.3/[email protected]/native_darwin.go:7:
In file included from ./glfw/include/GLFW/glfw3native.h:108:
In file included from /sdk/System/Library/Frameworks/Cocoa.framework/Headers/Cocoa.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:91:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLError.h:15:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:23:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/AE.framework/Headers/AE.h:20:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/CarbonCore.h:87:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/Components.h:26:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/Files.h:56:
In file included from /sdk/System/Library/Frameworks/DiskArbitration.framework/Headers/DADisk.h:28:
In file included from /sdk/System/Library/Frameworks/IOKit.framework/Headers/IOKitLib.h:49:
/sdk/System/Library/Frameworks/IOKit.framework/Headers/IOTypes.h:81:49: error: expected ';' after top level declarator
typedef mach_vm_address_t       IOVirtualAddress __kernel_ptr_semantics;
                                                ^
In file included from /go/pkg/mod/github.com/go-gl/glfw/v3.3/[email protected]/native_darwin.go:7:
In file included from ./glfw/include/GLFW/glfw3native.h:108:
In file included from /sdk/System/Library/Frameworks/Cocoa.framework/Headers/Cocoa.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:91:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLError.h:15:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:23:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/AE.framework/Headers/AE.h:20:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/CarbonCore.h:87:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/Components.h:26:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/Files.h:56:
In file included from /sdk/System/Library/Frameworks/DiskArbitration.framework/Headers/DADisk.h:28:
In file included from /sdk/System/Library/Frameworks/IOKit.framework/Headers/IOKitLib.h:52:
/sdk/System/Library/Frameworks/IOKit.framework/Headers/OSMessageNotification.h:120:53: error: expected ';' after top level declarator
typedef natural_t OSAsyncReference[kOSAsyncRefCount] __kernel_ptr_semantics;

@zyfdegh
Copy link

zyfdegh commented Mar 20, 2024

Got similar issue, downloaded Command_Line_Tools_for_Xcode_15.3.dmg and extracted on Linux (Kernel 3.10.0, CentOS7, Docker 20.10) using fyne-cross extract command

$ ls /data/root/Command_Line_Tools_for_Xcode/SDKs
MacOSX13.3.sdk  MacOSX13.sdk  MacOSX14.4.sdk  MacOSX14.sdk  MacOSX.sdk

$ git clone https://github.com/fyne-io/examples.git && cd examples && ls
AUTHORS  bugs  clock  data.go  fractal  fyne-cross  fyne_metadata_init.go  go.mod  go.sum  Icon.png  img  LICENSE  main.go  README.md  tictactoe  vendor  xkcd
$ fyne-cross darwin -app-id io.fyne.example  -macosx-sdk-path /data/root/Command_Line_Tools_for_Xcode/SDKs/MacOSX13.3.sdk -arch=amd64 -debug -no-cache -env GOPROXY=https://goproxy.io,direct

# fyne.io/systray
clang version 13.0.1 ([email protected]:ziglang/zig-bootstrap.git 81f0e6c5b902ead84753490db4f0007d08df964a)
Target: x86_64-unknown-macosx-gnu
Thread model: posix
InstalledDir: /go/pkg/mod/fyne.io/[email protected]
 (in-process)
 "/usr/local/zig/zig" -cc1 -triple x86_64-unknown-macosx10.11.0-gnu -Wundef-prefix=TARGET_OS_ -Werror=undef-prefix -Wdeprecated-objc-isa-usage -Werror=deprecated-objc-isa-usage -emit-obj --mrelax-relocations -disable-free -disable-llvm-verifier -discard-value-names -main-file-name systray_darwin.m -mrelocation-model pic -pic-level 2 -mframe-pointer=all -fno-rounding-math -faligned-alloc-unavailable -target-sdk-version=13.3 -fcompatibility-qualified-id-block-type-checking -fvisibility-inlines-hidden-static-local-var -target-cpu core2 -tune-cpu generic -debugger-tuning=lldb -v -fcoverage-compilation-dir=/go/pkg/mod/fyne.io/[email protected] -nostdsysteminc -nobuiltininc -resource-dir /usr/local/lib/clang/13.0.1 -dependency-file /root/.cache/zig/tmp/730c5c84b88b598c-systray_darwin.o.d -MT /root/.cache/zig/tmp/730c5c84b88b598c-systray_darwin.o -sys-header-deps -MV -isystem /usr/local/zig/lib/include -isystem /usr/local/zig/lib/libc/include/x86_64-macos.10-gnu -isystem /usr/local/zig/lib/libc/include/any-macos.10-any -isystem /usr/local/zig/lib/libc/include/any-macos-any -isysroot /sdk -iwithsysroot /usr/include -iframeworkwithsysroot /System/Library/Frameworks -D _DEBUG -I /go/pkg/mod/fyne.io/[email protected] -I $WORK/b230/ -D DARWIN -fmacro-prefix-map=/tmp/go-build2505255251/b230=/tmp/go-build -fmacro-prefix-map=/go/pkg/mod/fyne.io/[email protected]=/_/fyne.io/[email protected] -fcoverage-prefix-map=/tmp/go-build2505255251/b230=/tmp/go-build -fcoverage-prefix-map=/go/pkg/mod/fyne.io/[email protected]=/_/fyne.io/[email protected] -Og -fdebug-compilation-dir=/go/pkg/mod/fyne.io/[email protected] -fdebug-prefix-map=/tmp/go-build2505255251/b230=/tmp/go-build -fdebug-prefix-map=/go/pkg/mod/fyne.io/[email protected]=/_/fyne.io/[email protected] -ferror-limit 19 -fsanitize=alignment,array-bounds,bool,builtin,enum,float-cast-overflow,function,integer-divide-by-zero,nonnull-attribute,null,object-size,pointer-overflow,return,returns-nonnull-attribute,shift-base,shift-exponent,signed-integer-overflow,unreachable,vla-bound -fsanitize-trap=alignment,array-bounds,bool,builtin,enum,float-cast-overflow,function,integer-divide-by-zero,nonnull-attribute,null,object-size,pointer-overflow,return,returns-nonnull-attribute,shift-base,shift-exponent,signed-integer-overflow,unreachable,vla-bound -pthread -stack-protector 2 -stack-protector-buffer-size 4 -fblocks -fencode-extended-block-signature -fregister-global-dtors-with-atexit -fgnuc-version=4.2.1 -fobjc-runtime=macosx-10.11.0 -fobjc-arc -fobjc-exceptions -fexceptions -fmax-type-align=16 -fno-spell-checking -target-cpu x86-64 -target-feature -16bit-mode -target-feature -32bit-mode -target-feature -3dnow -target-feature -3dnowa -target-feature +64bit -target-feature -adx -target-feature -aes -target-feature -amx-bf16 -target-feature -amx-int8 -target-feature -amx-tile -target-feature -avx -target-feature -avx2 -target-feature -avx512bf16 -target-feature -avx512bitalg -target-feature -avx512bw -target-feature -avx512cd -target-feature -avx512dq -target-feature -avx512er -target-feature -avx512f -target-feature -avx512ifma -target-feature -avx512pf -target-feature -avx512vbmi -target-feature -avx512vbmi2 -target-feature -avx512vl -target-feature -avx512vnni -target-feature -avx512vp2intersect -target-feature -avx512vpopcntdq -target-feature -avxvnni -target-feature -bmi -target-feature -bmi2 -target-feature -branchfusion -target-feature -cldemote -target-feature -clflushopt -target-feature -clwb -target-feature -clzero -target-feature +cmov -target-feature -cx16 -target-feature +cx8 -target-feature -enqcmd -target-feature -ermsb -target-feature -f16c -target-feature -false-deps-lzcnt-tzcnt -target-feature -false-deps-popcnt -target-feature -fast-11bytenop -target-feature -fast-15bytenop -target-feature -fast-7bytenop -target-feature -fast-bextr -target-feature -fast-gather -target-feature -fast-hops -target-feature -fast-lzcnt -target-feature -fast-movbe -target-feature -fast-scalar-fsqrt -target-feature -fast-scalar-shift-masks -target-feature -fast-shld-rotate -target-feature -fast-variable-crosslane-shuffle -target-feature -fast-variable-perlane-shuffle -target-feature -fast-vector-fsqrt -target-feature -fast-vector-shift-masks -target-feature -fma -target-feature -fma4 -target-feature -fsgsbase -target-feature -fsrm -target-feature +fxsr -target-feature -gfni -target-feature -hreset -target-feature -idivl-to-divb -target-feature +idivq-to-divl -target-feature -invpcid -target-feature -kl -target-feature -lea-sp -target-feature -lea-uses-ag -target-feature -lvi-cfi -target-feature -lvi-load-hardening -target-feature -lwp -target-feature -lzcnt -target-feature +macrofusion -target-feature +mmx -target-feature -movbe -target-feature -movdir64b -target-feature -movdiri -target-feature -mwaitx -target-feature +nopl -target-feature -pad-short-functions -target-feature -pclmul -target-feature -pconfig -target-feature -pku -target-feature -popcnt -target-feature -prefer-128-bit -target-feature -prefer-256-bit -target-feature -prefer-mask-registers -target-feature -prefetchwt1 -target-feature -prfchw -target-feature -ptwrite -target-feature -rdpid -target-feature -rdrnd -target-feature -rdseed -target-feature -retpoline -target-feature -retpoline-external-thunk -target-feature -retpoline-indirect-branches -target-feature -retpoline-indirect-calls -target-feature -rtm -target-feature -sahf -target-feature -serialize -target-feature -seses -target-feature -sgx -target-feature -sha -target-feature -shstk -target-feature +slow-3ops-lea -target-feature +slow-incdec -target-feature -slow-lea -target-feature -slow-pmaddwd -target-feature -slow-pmulld -target-feature -slow-shld -target-feature -slow-two-mem-ops -target-feature -slow-unaligned-mem-16 -target-feature -slow-unaligned-mem-32 -target-feature -soft-float -target-feature +sse -target-feature +sse2 -target-feature -sse3 -target-feature -sse4.1 -target-feature -sse4.2 -target-feature -sse4a -target-feature -sse-unaligned-mem -target-feature -ssse3 -target-feature -tbm -target-feature -tsxldtrk -target-feature -uintr -target-feature -use-aa -target-feature -use-glm-div-sqrt-costs -target-feature -vaes -target-feature -vpclmulqdq -target-feature +vzeroupper -target-feature -waitpkg -target-feature -wbnoinvd -target-feature -widekl -target-feature +x87 -target-feature -xop -target-feature -xsave -target-feature -xsavec -target-feature -xsaveopt -target-feature -xsaves -D__GCC_HAVE_DWARF2_CFI_ASM=1 -o /root/.cache/zig/tmp/730c5c84b88b598c-systray_darwin.o -x objective-c systray_darwin.m
clang -cc1 version 13.0.1 based upon LLVM 13.0.1 default target x86_64-linux-musl
ignoring nonexistent directory "/usr/local/zig/lib/libc/include/any-macos.10-any"
#include "..." search starts here:
#include <...> search starts here:
 /go/pkg/mod/fyne.io/[email protected]
 $WORK/b230
 /usr/local/zig/lib/include
 /usr/local/zig/lib/libc/include/x86_64-macos.10-gnu
 /usr/local/zig/lib/libc/include/any-macos-any
 /sdk/usr/include
 /sdk/System/Library/Frameworks (framework directory)
End of search list.
In file included from systray_darwin.m:1:
In file included from /sdk/System/Library/Frameworks/Cocoa.framework/Headers/Cocoa.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/NSBundle.h:6:
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSString.h:371:81: error: function does not return string type
- (nullable instancetype)initWithUTF8String:(const char *)nullTerminatedCString NS_FORMAT_ARGUMENT(1);
                                                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^                  ~
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:103:48: note: expanded from macro 'NS_FORMAT_ARGUMENT'
        #define NS_FORMAT_ARGUMENT(A) __attribute__ ((format_arg(A)))
                                                      ^          ~
In file included from systray_darwin.m:1:
In file included from /sdk/System/Library/Frameworks/Cocoa.framework/Headers/Cocoa.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/NSBundle.h:6:
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSString.h:372:52: error: function does not return NSString
- (instancetype)initWithString:(NSString *)aString NS_FORMAT_ARGUMENT(1);
                                ~~~~~~~~~~~~~~~~~~ ^                  ~
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:103:48: note: expanded from macro 'NS_FORMAT_ARGUMENT'
        #define NS_FORMAT_ARGUMENT(A) __attribute__ ((format_arg(A)))
                                                      ^          ~
In file included from systray_darwin.m:1:
In file included from /sdk/System/Library/Frameworks/Cocoa.framework/Headers/Cocoa.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/NSBundle.h:6:
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSString.h:387:53: error: function does not return NSString
+ (instancetype)stringWithString:(NSString *)string NS_FORMAT_ARGUMENT(1);
                                  ~~~~~~~~~~~~~~~~~ ^                  ~
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:103:48: note: expanded from macro 'NS_FORMAT_ARGUMENT'
        #define NS_FORMAT_ARGUMENT(A) __attribute__ ((format_arg(A)))
                                                      ^          ~
In file included from systray_darwin.m:1:
In file included from /sdk/System/Library/Frameworks/Cocoa.framework/Headers/Cocoa.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/NSBundle.h:6:
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSString.h:389:83: error: function does not return string type
+ (nullable instancetype)stringWithUTF8String:(const char *)nullTerminatedCString NS_FORMAT_ARGUMENT(1);
                                                     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^                  ~
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:103:48: note: expanded from macro 'NS_FORMAT_ARGUMENT'
        #define NS_FORMAT_ARGUMENT(A) __attribute__ ((format_arg(A)))
                                                      ^          ~
In file included from systray_darwin.m:1:
In file included from /sdk/System/Library/Frameworks/Cocoa.framework/Headers/Cocoa.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/NSBundle.h:6:
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSString.h:395:114: error: function does not return string type
- (nullable instancetype)initWithCString:(const char *)nullTerminatedCString encoding:(NSStringEncoding)encoding NS_FORMAT_ARGUMENT(1);
                                                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~                                     ^                  ~
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:103:48: note: expanded from macro 'NS_FORMAT_ARGUMENT'
        #define NS_FORMAT_ARGUMENT(A) __attribute__ ((format_arg(A)))
                                                      ^          ~
In file included from systray_darwin.m:1:
In file included from /sdk/System/Library/Frameworks/Cocoa.framework/Headers/Cocoa.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/NSBundle.h:6:
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSString.h:396:97: error: function does not return string type
+ (nullable instancetype)stringWithCString:(const char *)cString encoding:(NSStringEncoding)enc NS_FORMAT_ARGUMENT(1);
                                                  ~~~~~~~~~~~~~~                                ^                  ~
/sdk/System/Library/Frameworks/Foundation.framework/Headers/NSObjCRuntime.h:103:48: note: expanded from macro 'NS_FORMAT_ARGUMENT'
        #define NS_FORMAT_ARGUMENT(A) __attribute__ ((format_arg(A)))
                                                      ^          ~
In file included from systray_darwin.m:1:
In file included from /sdk/System/Library/Frameworks/Cocoa.framework/Headers/Cocoa.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:91:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLError.h:15:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:23:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/AE.framework/Headers/AE.h:20:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/CarbonCore.h:87:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/Components.h:26:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/Files.h:56:
In file included from /sdk/System/Library/Frameworks/DiskArbitration.framework/Headers/DADisk.h:28:
In file included from /sdk/System/Library/Frameworks/IOKit.framework/Headers/IOKitLib.h:49:
/sdk/System/Library/Frameworks/IOKit.framework/Headers/IOTypes.h:81:49: error: expected ';' after top level declarator
typedef mach_vm_address_t       IOVirtualAddress __kernel_ptr_semantics;
                                                ^
In file included from systray_darwin.m:1:
In file included from /sdk/System/Library/Frameworks/Cocoa.framework/Headers/Cocoa.h:12:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h:91:
In file included from /sdk/System/Library/Frameworks/Foundation.framework/Headers/NSURLError.h:15:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:23:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/AE.framework/Headers/AE.h:20:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/CarbonCore.h:87:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/Components.h:26:
In file included from /sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Headers/Files.h:56:
In file included from /sdk/System/Library/Frameworks/DiskArbitration.framework/Headers/DADisk.h:28:
In file included from /sdk/System/Library/Frameworks/IOKit.framework/Headers/IOKitLib.h:52:
/sdk/System/Library/Frameworks/IOKit.framework/Headers/OSMessageNotification.h:120:53: error: expected ';' after top level declarator
typedef natural_t OSAsyncReference[kOSAsyncRefCount] __kernel_ptr_semantics;
                                                    ^
8 errors generated.

This is the full log
fyne-cross-darwin.log

@calderonth
Copy link

Same problem as above, cannot seem to be able to cross compile to darwin with Xcode CLI 15.3.

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

8 participants