Re: [hatari-devel] Hatari macOS builds - handover need?

[ Thread Index | Date Index | More lists.tuxfamily.org/hatari-devel Archives ]


Am Sun, 23 Apr 2023 17:29:49 +0100
schrieb Chris Jenkins <cdpjenkins@xxxxxxxxx>:

> Hi Thomas,
> 
> I'm a noob when it comes to Xcode but I was able to follow similar steps to
> the Cirrus CI steps in your email and build an executable:
> 
> $ mkdir build-release
> $ cmake -G Xcode -DCMAKE_BUILD_TYPE:STRING="Release"
> -DCMAKE_CROSSCOMPILING:BOOL=1 ..
> $ cmake --build .  --config Release -j$(sysctl -n hw.ncpu)
> 
> Does the Cirrus CI output any useful jobs that will give us a clue why it
> failed to create cpudefs.c? As far as I understand it, that should be
> generated by an earlier part of the build process... right?

I finally figured it out: The problem only occurs when you're trying an
in-tree build with the Xcode generator. It works fine when doing an
out-of-tree build.

> (Unfortunately, my build fails because it can't sign my executable - I
> still have to figure out how to make it sign it with my Apple developer
> certificate. I also note that the executable that it created it an arm64
> binary, not a universal binary, so I still need to figure out how to make a
> universal binary!)

I did some more trial-and-error compile tests on cirrus-ci.com and finally
figured it out how to by-pass the signing step and thanks to Andreas' hint,
it seems like I'm also able to create universal binaries there.
My CMake calls now looks like this:

  mkdir build
  cd build
  cmake -G Xcode -DCMAKE_BUILD_TYPE:STRING="Release"
        -DCMAKE_XCODE_ATTRIBUTE_CODE_SIGNING_REQUIRED="NO"
        -DCMAKE_XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY=""
        -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING="10.9"
        -DCMAKE_OSX_ARCHITECTURES:STRING="x86_64;arm64" ..
 cmake --build . --verbose --config Release -j$(sysctl -n hw.ncpu) -t hatari

Could you or someone with macOS >= 10.9 please check whether this build
works (i.e. the application can be started):

 https://cirrus-ci.com/task/5543185464688640

(click on Artifacts -> hatari -> hatari-snapshot.zip)

It's still in a rough shape, no libpng or other libraries included yet, no
EmuTOS in the package and no nice readme files yet, but it would be
interesting to know whether it basically works or whether I'm still on the
wrong track.

 Thomas



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/