HaxeFoundation / HaxeFoundation/haxe
EEXIST for one of two parallel cpp builds
- Dominant language
- Haxe
- Stars
- 6.9k
- Forks
- 715
- Avg merge
- 2d 2h
- Merged PRs (30d)
- 11
Description
(Not sure if this is the best place to file this, but following a hunch. Feel free to redirect or close pending a smaller repro case -- but it seems like it might have a relatively obvious cause, if not fix.)
We have an OpenFL 6.2.0 + Lime 5.6.0 project that we're building to iOS by running `haxelib run openfl update ios -verbose -clean` and then `xcodebuild archive` (with appropriate parameters).
At the start of the `Build Haxe` target build, I sometimes (maybe ~50% of attempts on this build slave over the last day or two) see:
``` /Applications/Xcode.app/Contents/Developer/usr/bin/make
Haxe device build: Release-iphoneos-v7
Haxe device build: Release-iphoneos-64
haxe Build.hxml -D HXCPP_ARMV7 -cpp build/Release-iphoneos-v7
Make build-haxe-armv7 build-haxe-arm64
haxe Build.hxml -D HXCPP_ARM64 -cpp build/Release-iphoneos-64
Unix.Unix_error(Unix.EEXIST, "mkdir", "build")
make: *** [build-haxe-armv7] Error 1
make: *** Waiting for unfinished jobs....
```
And indeed examining the workspace I see e.g. `build/Debug-iphoneos-64` but not `build/Debug-iphoneos-v7` or vice versa.
To take a random stab it might be racing between https://github.com/HaxeFoundation/haxe/blob/67e4c6336531b4b494218ec2061f3f3f5e0a0fce/src/context/common.ml#L841 and the subsequent line across the two instances, called from e.g. https://github.com/HaxeFoundation/haxe/blob/3df0c6d4916df51a518c80cef277b1e9b2a1c82d/src/generators/gencpp.ml#L8110 or similar?
(Any easy way to get a stack out of it next time I see it? Complicated a little by the likely need to edit .pbxproj or similar between autobuild steps...)
Having just written this up I bet I can work around this by premaking the "build" dir...
Contributor guide
Assessment
This issue has not been assessed yet.