openfl / lime

A foundational Haxe framework for cross-platform development
https://lime.openfl.org/
MIT License
753 stars 365 forks source link

have the -xcode flag option for mac? #1651

Open JonnycatMeow opened 1 year ago

JonnycatMeow commented 1 year ago

i was thinking that if the ios has the -xcode flag how come mac don't have one?

joshtynjala commented 1 year ago

As I understand it, an Xcode project is basically always required to compile an iOS app, even if that project isn't made available as a build artifact. On the other hand, to compile for macOS, I think that you can compile everything by executing directly the compiler, linker, and any other command line tools that are required, so no Xcode project is required.

With that in mind, the -xcode option was very easy to implement with iOS because the project would already exist from the start. With macOS, extra work would need to go into generating a project file that isn't normally used. It's probably not impossible, but I doubt it would be worth the effort, except by someone who has a very specific reason to need it.

JonnycatMeow commented 1 year ago

ok i understand where your coming from and it is kinda useless making a whole xcode project. but there is the thing i have a intel mac and i want to make a arm64 build but i don't have a mac silicon arm64 computer but i have xcode so i can make the arm64 that why i was thinking of implementing that -xcode flag.

JonnycatMeow commented 1 year ago

and see i used this version of lime https://github.com/openfl/lime/pull/1642 from someone else's request and i tried to build it even though i have xcode and it did not work because i didn't have a apple silicon

JonnycatMeow commented 1 year ago

thats why i wanted to implement -xcode on macOS. yes it will be diffrent and it will be hard but at the same time i can choose which arch i can use on xcode

joshtynjala commented 1 year ago

I wonder if you can add -DHXCPP_ARM64 to your build command.

JonnycatMeow commented 1 year ago

ima try

JonnycatMeow commented 1 year ago

and if it does not want to build it for arm64 for macos then can you consider my idea for the -xcode flag for mac?

JonnycatMeow commented 1 year ago

I wonder if you can add -DHXCPP_ARM64 to your build command.

i tried that but it doesn't work

JonnycatMeow commented 1 year ago

its because i have a x86_64 mac