4 ms·
Browser engines like WebKit are (with some work) portable to any platform with a C++ compiler: that's how the current Haiku browser is built.
by panic 10y ago
Browser engines like WebKit are (with some work) portable to any platform with a C++ compiler: that's how the current Haiku browser is built.
- nickpsecurity 10y agoSo, now you just need to build a highly-optimizing, C++ compiler instead of a browser? That's another project that few got right over a period of a decade or so. Of course, one could use a C++ to C compiler or extend existing C++ compiler with OS-specific backend. Might still be plenty work but easier than clean-slate browser.
- Sanddancer 10y agoBoth gcc and clang have flags to emit raw object files. At which point, your porting work really centers around making sure you have a good standard library in place, and that your kernel has a reasonable implementation of parsing a binary format like ELF or PE, etc.
- nickpsecurity 10y agoNow that's pretty cool. Appreciate the tip.
- ori_b 10y ago> So, now you just need to build a highly-optimizing, C++ compiler instead of a browser? No. You just use gcc. Like everyone else.
- nickpsecurity 10y agoThe gist of the comment was whether GCC automatically made something like WebKit + JIT + Native Client work on very, different OS by a simple compile. I doubted that was true or that the work was easy.
- ori_b 10y agoYou only need to implement the window system and widget rendering glue. The layout, javascript, CSS, DOM, history, etc is all platform independent. But implementing `drawButton()`, `blitToScreen()` and similar is in no way similar to implementing a C++ compiler, as you implied. An example of a port is here, in this directory: https://trac.webkit.org/browser/trunk/Source/WebCore/platform/efl https://trac.webkit.org/browser/trunk/Source/WebCore/platfor...
- nickpsecurity 10y agoSounds a lot better than I thought. Appreciate the explanation. :)
- kobeya 10y agoI ran firefox on BeOS.
- nickpsecurity 10y agoIm curious how it ran. Was there a performance boost from BeOS architecture?
- kobeya 10y agoNot noticeably. It just rendered better than the built in browser..
- jwatte 10y agoI prefer clang.