Login  •  Register


The time is now: Wed Sep 18, 2019 5:01 am

Emaculation wiki  •  Delete all board cookies



Post new topic  Reply to topic Page 1 of 1 [ 11 posts ]
Print view Previous topic  |  Next topic
Author Message
PostPosted: Thu Nov 22, 2018 3:04 pm 
Offline
Tinkerer
User avatar

Joined: Fri Dec 29, 2017 3:43 pm
Posts: 58
Hi, I wonder if there is any project to make a Rosetta clone for new Macs. Or just a port of it.
I’m reading here and there some stuff. I found a 2004 tread about SoftPear and it seem the thing I’m looking for.

Some links:
https://www.insanelymac.com/forum/topic ... a-on-lion/
https://www.software.ac.uk/blog/2016-09 ... transitive
http://softpear.sourceforge.net/index.php
viewtopic.php?f=34&t=9054&hilit=softpear
viewtopic.php?f=7&t=6624&hilit=Dynamic+binary+translation

Since there are many old and quite recent tread about this topic, if you have any external links, resources, similar treads, share them here.

Some keywords I think are relevant but I don’t know perfectly the meaning of:
• Dynamic binary translator (would be the final achievement)
• Static binary translator (Translating and optimizing each PPC app into the relative x86 one, we could start with this (easier to do, or not?))

Start a repository and add members in it. So we can “see” each other and try to work together, better.
PS: I’m not a programmer, I’ll try my best to help.


Top
 Profile  
Reply with quote Post a reply  
PostPosted: Thu Nov 22, 2018 5:41 pm 
Offline
Forum All-Star
User avatar

Joined: Fri Nov 27, 2009 5:11 am
Posts: 2682
Location: Emaculation.com
SoftPear was an attempt that AFAIK didn't go anywhere.

However, I've had my eye on a simpler prize recently; I haven't investigated thoroughly enough to see if it's possible though.

We all know that Classic.app depends on a whole bunch of frameworks that were never written for Intel, and so running Classic under Rosetta won't work.

However, I recently got the idea to look at running MacOS.app from OS X Server under 10.6.8 -- it appears to have fewer framework dependencies than Classic, and will run Mac OS 8.6. 10.6.8 will still run inside VirtualBox and the server variant will run in VMWare and Parallels. So it theoretically should be possible to run all non-hardware-dependent PPC/32-bit Intel Mac software in one place by this method.

As far as Rosetta itself goes: best to just run 10.6.8 in a VM at this point, as there's a huge framework dependency chain that's been broken between 10.6.8 and 10.14.1. You'd have to not only replicate Rosetta at this point, but also port all those deprecated frameworks (or run them under Rosetta). Easier just to run them under a stable OS in a VM -- and Parallels Desktop Lite has host OS integration (and VMWare Fusion has Finder Integration as well) so the end result is almost the same.


Top
 Profile  
Reply with quote Post a reply  
PostPosted: Thu Nov 22, 2018 7:00 pm 
Offline
Tinkerer
User avatar

Joined: Fri Dec 29, 2017 3:43 pm
Posts: 58
Ok...

Let’s try to be more “explicit” (?) (I’m sorry for my English)

In my opinion it could be just great to make a similar software. Just for fun, for challenging ourself!
I think there is no reason to develop a Rosetta software just for executing apps. You said it, you can simply run a VM with Snow Leopard in it and you are done.

Simply, it would be fantastic, would be extremely challenging; that “WOW” thing everybody will speak about. And we are not going to make it for the “WOW” thing, but because we loved that software, we still love it, and we want to take it back on macOS.

Now...
The true is: there is no problem to solve for the things I wrote before.

My request could be put simply:
“Would you like to run PPC apps and games without any VM and copies of old Mac OS X images?”
“Would you finally like to see that software you had never seen?”

If yes, and you are a developer, these are some questions for you:
“Are you ready to start this hard challenge?”
“Are you motivated enough?”
“Would you like to collaborate with people around the world for a very exciting project?”

Then I was thinking: that post about SoftPear was written in 2004. Why they stopped? Could we have had something it they continued working on it after 14 years?
Think about 14 years from now, would you be happy to see this project done or not?
Are there some things who really cannot be done? Is not it just a question of 0 and 1?


Top
 Profile  
Reply with quote Post a reply  
PostPosted: Thu Nov 22, 2018 10:43 pm 
Offline
Forum All-Star
User avatar

Joined: Fri Nov 27, 2009 5:11 am
Posts: 2682
Location: Emaculation.com
Quote:
“Would you like to run PPC apps and games without any VM and copies of old Mac OS X images?”

That would be lovely, especially if it ran ALL PPC apps and games, and not just stuff targeted at 10.4 and 10.5.

Quote:
“Would you finally like to see that software you had never seen?”

Well, we've already established that there are already ways of running the software that will be more accurate and reliable than via a Rosetta-style emulation.

Quote:
“Are you ready to start this hard challenge?” “Are you motivated enough?”

Well, the project started in 2003, got abandoned in 2004, got picked up again by others in 2011 or so, and has languished since around 2012. The reason for this is that the amount of work required to make it work on modern OS X is roughly equivalent to the amount of work it would take to create a new OS from scratch that can support OS X binaries. Not impossible, but even starting from Darwin, you'd need a sizeable dedicated development team to get a workable system in any reasonable timeframe. Just look at Haiku and ReactOS as examples of the effort required.

Quote:
“Would you like to collaborate with people around the world for a very exciting project?”

The problem here is that the number of people around the world who are skilled enough to do this, knowledgeable enough to do this, have the time to invest in this, and still find it exciting, approaches zero -- minimizing the collaboration options. Most of the people capable of this who have the patience to see it through architectural design and 3-5 years of development before they get something functional are already working on more rewarding projects.

HOWEVER, if there's a bunch of kids fresh out of CompSci classes who've studied architectural design and are interested in implementing a PPC translation layer framework on top of OS X that just haven't spoken out before now... I'd love to have them get involved :)

Quote:
Then I was thinking: that post about SoftPear was written in 2004. Why they stopped? Could we have had something it they continued working on it after 14 years?

They stopped because it was essentially a side hobby for a couple of university students. They gathered the documentation, and slowly learned the scope of the project they had undertaken. But even if they'd kept going, they wouldn't have finished before OS X 10.4.4 was released in 2006 to do exactly what they were proposing: run OS X on x86 hardware. They were working at creating an emulation layer that OS X could run on top of, starting with Darwin, and then moving to Aqua-based software. They didn't even get as far as running Darwin CLI binaries on their proposed system. If they had continued, they would have stopped immediately when 10.4.4 was released, because it does exactly what they were attempting to do -- and Apple had actually been dual-compiling the OS for PPC and x86 from the Rhapsody DPs right through to 10.4.4; it just wasn't published.

The event that kicked off further interest in this project in 2011 was that 10.7 was announced at WWDC, and it didn't have Rosetta. There was much investigation by Mac developer houses, hobbyists, etc. to see how hard it would be to migrate Rosetta to 10.7.

The truth is, Apple discontinued it for two reasons: one, they were licensing the tech from a third party. This meant they had to pay royalties on each copy of OS X run up, which conflicted with the ability to virtualize the OS. This is why 10.4 through 10.6 essentially prohibit virtualization of the OS.

The second reason though was even more important: Apple wanted to drop not only PPC legacy frameworks and APIs from the OS, they also wanted to drop 32-bit x86 frameworks and APIs from the OS. This means that even if they had included Rosetta in 10.7, most of the PPC software that ran flawlessly under 10.6 would not run, or would run unreliably, under 10.7. I experienced this first-hand as a number of products I used that were essentially a PPC product with a 32-bit x86 wrapper around them (I'm looking at you, Adobe and Avid) broke with 10.7. This gave rise to the RoaringApps website.

So to overcome this, any potential replacement for Rosetta would have to do way more than Rosetta ever did: it would not only have to provide JIT translation of 32-bit PPC instructions into x86-64, it would ALSO have to clean-room re-implement all of the APIs and frameworks that were dropped by Apple with 10.7.

So if they had for some reason continued working on the project after 2006 even though Apple provided them with a superior alternative, they would have stopped in 2011 for the same reason that Apple did.

Quote:
Think about 14 years from now, would you be happy to see this project done or not?

14 years from now, I'd be much happier with some alternative OS that can selectively launch binaries from a single filesystem in the legacy OS required, linking them back to a single UI translation layer. Chasing legacy frameworks is a fruitless endeavour for the most part; it worked for ReactOS/WINE and Windows XP because XP hung around for so long and Microsoft has traditionally not tossed old frameworks and APIs, just added new ones.

Quote:
Are there some things who really cannot be done? Is not it just a question of 0 and 1?

Oh, it can be done, just like using a toothpick to mine for gold can be done. It's just that those in the best position to do so recognize that there are likely better things they could be doing with their time to achieve the same (or better) results.

[edit]
Just to clarify: Rosetta did one thing: took OS X code written for PPC interpretation and dynamically translated it to its 32-bit Intel equivalent.

By comparison, Classic booted a second OS running on the same architecture and enabled seamless UI and filesystem integration between the dual-booting OSes. WINE took the Windows 32-bit API from Windows 98 (and later Windows XP) and re-implemented them for any POSIX-compliant OS running the same architecture. ReactOS created a new open-source operating system that is ostensibly cross-platform, but written only for x86 at this point, and implemented WINE around a lightweight kernel.

What's needed to run OS X 10.2 software seamlessly on an OS X 10.14 desktop is essentially a combination of the 10.2 equivalent of WINE plus Rosetta. This effort would have to be re-done for 10.5 as well. And the tricky bit is that we're not just changing framework and API sets and CPU instruction sets, we're also switching from 32-bit to 64-bit instructions. And unlike Microsoft, who documented most of their OS with a few hidden API exceptions, Apple has for the most part kept Aqua a closed book, only exposing hooks to allow developers to interact with it. Sure, the Darwin source is available that underpins the whole thing, but that's not the part that needs to be re-implemented in the first place.


Top
 Profile  
Reply with quote Post a reply  
PostPosted: Fri Nov 23, 2018 11:16 pm 
Offline
Master Emulator

Joined: Fri Sep 17, 2004 4:22 am
Posts: 351
mePy2 wrote:
In my opinion it could be just great to make a similar software. Just for fun, for challenging ourself!

mePy2 wrote:
PS: I’m not a programmer


I suggest you challenge yourself to learn rudimentary programming rather than concocting fanciful ideas about what other people would find "fun".

Quote:
that “WOW” thing everybody will speak about.
The audience for such projects has dwindled to the point where practically no one would speak about it. Even the archive.org Mac software library doesn't seem to have attracted much notice.


Top
 Profile  
Reply with quote Post a reply  
PostPosted: Fri Nov 23, 2018 11:32 pm 
Offline
Forum All-Star
User avatar

Joined: Fri Nov 27, 2009 5:11 am
Posts: 2682
Location: Emaculation.com
Jorpho wrote:
Even the archive.org Mac software library doesn't seem to have attracted much notice.


Despite my efforts :\ Most people don't even realize that there's a full Javascript version of PCE/Macplus running each of the images on there. I believe it even has network capabilities.

To be fair though, most of that library is 68k software, and mePy2 seems to be talking about running PPC OS X software on x86-64 OS X. I bet he's never attempted to run software compiled for Debian 3 on Debian 9 (let's ignore the architectural differences for now) -- possibly he's attempted to run software compiled for Windows XP on Windows 10 and assumed that other platforms like Mac OS are as compatible across versions as these are.


Top
 Profile  
Reply with quote Post a reply  
PostPosted: Mon Nov 26, 2018 10:55 am 
Offline
Tinkerer
User avatar

Joined: Fri Dec 29, 2017 3:43 pm
Posts: 58
Thank you for your replies. As always I learned much from it.

Jorpho: the “fun” thing is for people who find it fun. Nobody force you or someone to do it.

About the “Wow” thing... I think it’s different. The result would not be a restoration of an old product or some “retro-software” thing. It would be something people would use on modern Macs and macOS.

And yes, I still can use software I bought for Win XP on my Win 10 pc. Why I cannot do the same on macOS? I think it is my right.
Many say it’s not the fault of Apple but of the Software companies. I think it’s not.


Top
 Profile  
Reply with quote Post a reply  
PostPosted: Mon Nov 26, 2018 6:01 pm 
Offline
Forum All-Star
User avatar

Joined: Fri Nov 27, 2009 5:11 am
Posts: 2682
Location: Emaculation.com
mePy2 wrote:
And yes, I still can use software I bought for Win XP on my Win 10 pc. Why I cannot do the same on macOS? I think it is my right.
Many say it’s not the fault of Apple but of the Software companies. I think it’s not.


It's 90% Apple's fault -- they're the ones that changed their software architecture multiple times.

The reason Windows XP software will run in Windows 10 is that Microsoft has been very careful about how it changes the OS architecture between versions.

Apple, on the other hand, has decided to rip the band-aid off and do mostly clean-starts.

Also, Apple has, over time, switched processors from 68k to PPC to PPC-64 to x86 to x86-64. During this time, Microsoft has switched from x86 to x86-64. Apple has switched underlying architectures in a major way once (Classic to OS X) but has also made massive changes to the architecture during OS X (part of the reason to call it macOS now instead of OS X).

It's kind of like if you bought a coffee maker for your house to sit on the counter, and then you moved to a new house made by the same construction firm. The coffee maker isn't guaranteed to fit on the new counter in your new house, even though the overall house may look similar to the previous one.

[edit] well... this is timely: https://arstechnica.com/gadgets/2018/11 ... n-general/

The difference being that Microsoft is scrambling to fix the problems, while Apple announced around a decade ago that XP-era Mac software wouldn't work for much longer.


Top
 Profile  
Reply with quote Post a reply  
PostPosted: Wed Dec 26, 2018 7:08 am 
Offline
Student Driver

Joined: Sun Sep 11, 2016 6:35 am
Posts: 10
adespoton wrote:
However, I recently got the idea to look at running MacOS.app from OS X Server under 10.6.8 -- it appears to have fewer framework dependencies than Classic, and will run Mac OS 8.6. 10.6.8 will still run inside VirtualBox and the server variant will run in VMWare and Parallels. So it theoretically should be possible to run all non-hardware-dependent PPC/32-bit Intel Mac software in one place by this method.


Adespoton, good idea here. I thought I’d chime in to mention some things I’ve learnt about the classic side of Classic.

Early boot code (the ROM StartMgr and the ‘boot’ resources in the System file or Classic Enabler) is largely 68k, and indeed very old. In several awkward places, an $FE22 F-line trap is issued with a dispatch selector in D0 and arguments on the stack. This instruction seems to be a “BlueBoxDispatch” call. Presumably the emulator translates it to a PowerPC ‘twi’, which then gets caught by Mach’s syscall indirection layer.

It seems natural that Classic’s transition to windowed and double-buffered mode would be triggered by one of these traps. (You might have noticed that the Aqua and the Platinum progress bars on the splash screen proceed in lockstep -- this is certainly FE22-mediated.) Maybe you could keep a newer and more capable version of Classic, but customise it to your liking by patching the MacOS boot code?


Top
 Profile  
Reply with quote Post a reply  
PostPosted: Wed Dec 26, 2018 8:24 pm 
Offline
Apple Corer
User avatar

Joined: Fri Aug 27, 2010 1:02 am
Posts: 223
It might be better to run them in a VM, and develop graphics and shared folders drivers for Mac OS X, rather than reimplementing all the frameworks from scratch.

Once graphics drivers are developed, the UI on the emulated machine should feel like the same performance as the UI on the original machine.

I know about the "RemoteApp" feature of RDP. I'm not sure if it's possible to do something similar in Mac OS X, however.


Top
 Profile  
Reply with quote Post a reply  
PostPosted: Thu Dec 27, 2018 9:45 pm 
Offline
Forum All-Star
User avatar

Joined: Fri Nov 27, 2009 5:11 am
Posts: 2682
Location: Emaculation.com
julialy wrote:
It might be better to run them in a VM, and develop graphics and shared folders drivers for Mac OS X, rather than reimplementing all the frameworks from scratch.

Once graphics drivers are developed, the UI on the emulated machine should feel like the same performance as the UI on the original machine.

I know about the "RemoteApp" feature of RDP. I'm not sure if it's possible to do something similar in Mac OS X, however.


Aqua doesn't have that kind of piping support, and instead uses VNC framebuffers for ARD; it could be done using X though.


Top
 Profile  
Reply with quote Post a reply  
Display posts from previous:  Sort by  
Post new topic  Reply to topic Page 1 of 1 [ 11 posts ]


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
 

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group