GithubHelp home page GithubHelp logo

runt18 / javascriptcore-ios Goto Github PK

View Code? Open in Web Editor NEW

This project forked from phoboslab/javascriptcore-ios

0.0 2.0 0.0 21.05 MB

Apple's JavaScript Engine, with modified project files for iOS

C++ 58.00% Objective-C++ 0.95% Objective-C 0.69% C 9.17% HTML 0.24% JavaScript 27.03% CMake 0.17% Makefile 0.05% Batchfile 0.03% Shell 0.02% Python 0.83% Perl 0.47% Assembly 0.74% Ruby 1.58% DTrace 0.01% Java 0.02%

javascriptcore-ios's Introduction

This Project has been discontinued โ€“ Mar. 2016

JSC is now a public library on iOS and tvOS. Ejecta has switched to the JSC library provided by the System. It still has some limitations (no native Typed Array API) as of 2016.03.30, but they are mostly workaroundable.

Also, compiling it for tvOS requires bitcode compilation now, which this fork of JSC does not support. You can read up on the fascinating details in my blog.

JavaScriptCore iOS

The JavaScriptCore library is part of the WebKit project and thus Open Source. However, in the sources you get from the WebKit SVN, the XCode project files are curiously missing an iOS compile target. The sources you get from opensource.apple.com are missing the project files altogether. You can't compile it at all. That's quite the Open Source spirit, Apple!

This repo aims to re-produce the missing iOS targets while staying on a somewhat up-to-date version.

Currently, the Safari-538.11.1 tag is used as the basis. With the current settings, the WTF and JavaScriptCore libraries can be compiled for armv7, armv7s, arm64 and x86 (for the iOS simulator). It will be compiled without Unicode collation support, because Apple claims ICU is a private framework on iOS. It should be AppStore compatible this way.

This version of JSC deprecates the typed-arrays branch of this repository. JSC now supports Typed Arrays natively, without any hacks.

Note however, that the source code of JSC was still modified:

  • It includes some API methods to work with Typed Arrays in native code. Have a look at the API/JSTypedArray.h, it declares three new API functions. The documentation for these functions can be found in this header file as well.
  • Number.MIN_VALUE was fixed to return DBL_MIN instead of 0 when the CPU has not enabled support denormal numbers.

Binaries

A compiled version of the libJavaScriptCore.a for armv7, armv7s, arm64 and the Simulator can be found in the source tree of the Ejecta project.

How to Compile

  1. Run python make.py.
  2. Get coffee! Building this takes a while ;P

You can do python make.py --help for more options.

javascriptcore-ios's People

Contributors

drodriguez avatar martijnthe avatar namuol avatar phoboslab avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.