zoukankan      html  css  js  c++  java
  • JSBinding / Plugins & Build Mozjswrap Library

    There are 2 libraries in Plugins:
    • mozjswrap. This is JSBinding library, it links C# and SpiderMonkey together and adds some supports specially for Unity.
     
    For mozjs-31, if you need to rebuild it, go to url above to get more information, or go to Mozilla website, or just email me: answerwinner@gmail.com.
     
    For mozjswrap, JSBinding already contains libraries for all supported platforms, so normally you don't need to rebuild this library. 
    Steps are written here in case you need them.
     
    Download source code
     
    for Android (use NDK)
    • 1. rename the folder to jni, after rename, 
    jni/
        mozjswrap.cpp
        mozjswrap.h
        Android.mk
    • 2. inside the folder jni/, execute command
            sh gen-android.sh
    • 3. output: ../libs/armeabi-v7a/libmozjswrap.so
     
    for Windows, Mac, iOS (use gyp, python, VisualStudio, XCode)
    • 1. Download google gyp. Put the gyp folder here. Like this:
    mozjswrap.h
    mozjswrap.cpp
    gyp/
       gyp_main.py
       LICENSE
     
    • 2. install python 2.7.x. (Mine is 2.7.6)
    • 3. For iOS: open moz.gyp, change js_debug to false. (line 9)
    • 4. build!
    Windows: double click gen-msvs2012.bat      output: ./build/Release/bin/mozjswrap.dll
    iOS:     bash gen-ios.sh                               output: ./build/Release-iphoneos/libmozjswrap.a
    Mac:     bash gen-mac.sh                             output: ./build/Default/mozjswrap.bundle
     
     
  • 相关阅读:
    sql server中count(*),count(col),count(1)的区别
    oracle 存储过程(1)
    Java线程:概念及原理
    H2 应用实例2
    H2 应用实例1
    H2 database 应用
    H2 database 操作操作内存表
    JDK 环境变量配置
    MySQL CREATE TRIGGER (1)
    MySQL 事务1
  • 原文地址:https://www.cnblogs.com/answerwinner/p/5648183.html
Copyright © 2011-2022 走看看