To use MuPDF source code in Android

本文档详细介绍了如何为Android设备编译MuPDF源代码的过程。包括安装Android开发环境(如SDK、NDK、Cygwin)、下载并解压MuPDF源代码、配置本地属性文件、使用make命令生成所需文件夹及解决出现的错误提示、通过ndk-build命令创建libmupdf.so文件等步骤。

1.Install Android develop environment,including SDK,NDK,Cygwin.

2.Download MuPDF source code. Uncompress it.

  http://code.google.com/p/mupdf/downloads/list  You can choose mupdf-1.2-source.zip

3.Open the source folder,enter android folder.You can find that the android source code is there, but no library .The libs folder is empty.So you have to compile the library by yourself.

  open mupdf-*.*-source/android/local.properties.sample, save as local.properties, and add the location of sdk.dir.

  cd to mupdf-*.*-source folder,run "make",and you will get the “generated” folder which the project will need.

  I got the following errors when I execute this step.

    

    I noticed that most of the errors are from function "win**",so I think these errors are for Windows system.Besides,the "generated" folder is generated already,so I ignore these errors and move on.

    I believe some problem is with X11.. 

    Use: make NOX11=yes and you should find it works fine.

  cd to mupdf-*.*-source/android folder,run "ndk-build" and you will get the libmupdf.so file in lib(s) folder

    

    ......

    

  ④......

then you android code can run normally.

For details :http://mupdf.com/doc/how-to-build-mupdf-for-android

转载于:https://www.cnblogs.com/qiengo/archive/2013/03/18/2965889.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值