【问题标题】:building MUPDF for Android为 Android 构建 MUPDF
【发布时间】:2012-04-16 01:12:14
【问题描述】:

我是使用 NDK 的新手,我想为我的 PDF 查看器项目构建 MUPDF 库,我跟着 Integrate MuPDF Reader in an app 和这个ReadMe.txt 我遇到了这个错误:。

home@home-desktop:/$ ndk-build -C /home/home/Downloads/MUPDFlib/mupdf-0.9/android
make: Entering directory `/home/home/Downloads/MUPDFlib/mupdf-0.9/android'
Gdbserver      : [arm-linux-androideabi-4.4.3] libs/armeabi/gdbserver
Gdbsetup       : libs/armeabi/gdb.setup
Gdbserver      : [arm-linux-androideabi-4.4.3] libs/armeabi-v7a/gdbserver
Gdbsetup       : libs/armeabi-v7a/gdb.setup
Compile thumb  : mupdf <= mupdf.c
Compile thumb  : mupdfcore <= base_error.c
Compile thumb  : mupdfcore <= base_geometry.c
Compile thumb  : mupdfcore <= base_getopt.c
Compile thumb  : mupdfcore <= base_hash.c
Compile thumb  : mupdfcore <= base_memory.c
Compile thumb  : mupdfcore <= base_object.c
Compile thumb  : mupdfcore <= base_string.c
Compile thumb  : mupdfcore <= base_time.c
Compile thumb  : mupdfcore <= crypt_aes.c
Compile thumb  : mupdfcore <= crypt_arc4.c
Compile thumb  : mupdfcore <= crypt_md5.c
Compile thumb  : mupdfcore <= crypt_sha2.c
Compile thumb  : mupdfcore <= dev_bbox.c
Compile thumb  : mupdfcore <= dev_list.c
Compile thumb  : mupdfcore <= dev_null.c
Compile thumb  : mupdfcore <= dev_text.c
jni/../../fitz/dev_text.c:6:22: error: ft2build.h: No such file or directory
jni/../../fitz/dev_text.c:7:10: error: #include expects "FILENAME" or <FILENAME>
jni/../../fitz/dev_text.c:8:10: error: #include expects "FILENAME" or <FILENAME>
jni/../../fitz/dev_text.c: In function 'fz_text_extract_span':
jni/../../fitz/dev_text.c:215: error: 'FT_Face' undeclared (first use in this function)
jni/../../fitz/dev_text.c:215: error: (Each undeclared identifier is reported only once
jni/../../fitz/dev_text.c:215: error: for each function it appears in.)
jni/../../fitz/dev_text.c:215: error: expected ';' before 'face'
jni/../../fitz/dev_text.c:237: error: 'face' undeclared (first use in this function)
jni/../../fitz/dev_text.c:318: error: 'FT_Fixed' undeclared (first use in this function)
jni/../../fitz/dev_text.c:318: error: expected ';' before 'ftadv'
jni/../../fitz/dev_text.c:319: error: 'FT_LOAD_NO_BITMAP' undeclared (first use in this    function)
jni/../../fitz/dev_text.c:319: error: 'FT_LOAD_NO_HINTING' undeclared (first use in this function)
jni/../../fitz/dev_text.c:319: error: 'FT_LOAD_IGNORE_TRANSFORM' undeclared (first use in this function)
jni/../../fitz/dev_text.c:324: error: 'ftadv' undeclared (first use in this function)
make: *** [obj/local/armeabi/objs-debug/mupdfcore/__/__/fitz/dev_text.o] Error 1
make: Leaving directory `/home/home/Downloads/MUPDFlib/mupdf-0.9/android'
home@home-desktop:/$ 

希望有人可以在这里帮助我。

【问题讨论】:

标签: android android-ndk mupdf


【解决方案1】:

here

  • 首先,在你的电脑上安装android NDK
  • 然后下载mupdf 0.8.15源码(1.0版本不要下载,1.0.0没有mupdf源码)
  • 下载第三方压缩包 (mupdf-thirdparty-2011-02-24.zip) ,url:mupdf.com//download/archive ,

你将编译成功。

【讨论】:

  • Please provide a summary 指向非英文页面的链接。
  • 我可以简单地把这个页面翻译成英文。首先,在你的电脑上安装android NDK。然后下载mupdf 0.8.15源代码(不要下载1.0版本,1.0没有mupdf源代码。 0),下载第三方压缩包(mupdf-thirdparty-2011-02-24.zip),url:mupdf.com//download/archive,编译就这么简单。
  • @MorrsionMacleo 您可以直接更新您的答案,而不是通过评论更新您的答案。我冒昧地为您演示了编辑和布局功能。如果您对它不满意,您可以回滚或进一步编辑它
【解决方案2】:

mupdf-0.9 文件夹中运行命令make,然后在android 文件夹中运行ndk-build

【讨论】:

    猜你喜欢
    • 2017-02-06
    • 2014-08-05
    • 1970-01-01
    • 2014-12-20
    • 2011-11-09
    • 1970-01-01
    • 2021-05-06
    • 2013-03-07
    • 1970-01-01
    相关资源
    最近更新 更多