Problems to solve to be perfect
See original GitHub issueHi,
I finished my script to build the PDFium to iOS. All is here with manual patchs: https://github.com/prsolucoes/mobile-pdfium
It generate files:
- libpdfium_arm.a
- libpdfium_arm64.a
- libpdfium_x64.a
- libpdfium_x86.a
- libpdfium.a (universal)
FIRST PROBLEM
The problem is that i join all “.a” files on each library and each library have +/- 200MB and the universal near 1GB of size.
I want understand what libraries i need merge with libtool, i have this:
- pdfium/out/debug-arm/obj/libfpdfdoc.a
- pdfium/out/debug-arm/obj/libfxge.a
- pdfium/out/debug-arm/obj/libpdfium.a
- pdfium/out/debug-arm/obj/libfdrm.a
- pdfium/out/debug-arm/obj/libformfiller.a
- pdfium/out/debug-arm/obj/third_party/libjpeg_turbo/libsimd.a
- pdfium/out/debug-arm/obj/third_party/libjpeg_turbo/libjpeg.a
- pdfium/out/debug-arm/obj/third_party/libfx_agg.a
- pdfium/out/debug-arm/obj/third_party/zlib/libzlib_x86_simd.a
- pdfium/out/debug-arm/obj/third_party/zlib/libchrome_zlib.a
- pdfium/out/debug-arm/obj/third_party/libbigint.a
- pdfium/out/debug-arm/obj/third_party/libfx_freetype.a
- pdfium/out/debug-arm/obj/third_party/libfx_libopenjpeg.a
- pdfium/out/debug-arm/obj/third_party/libfx_lcms2.a
- pdfium/out/debug-arm/obj/third_party/icu/libicuuc.a
- pdfium/out/debug-arm/obj/libpwl.a
- pdfium/out/debug-arm/obj/libfpdftext.a
- pdfium/out/debug-arm/obj/libfpdfapi.a
- pdfium/out/debug-arm/obj/libfxcrt.a
- pdfium/out/debug-arm/obj/libfxcodec.a
- pdfium/out/debug-arm/obj/libfxjs.a
Today im merging all for each library and each arch and the library is with a huge file size.
SECOND PROBLEM
The libraries are compile always with iOS 10 and xcode give me 402 warning about it:
ld: warning: object file (/Users/paulo/Downloads/UXReader-iOS/UXReader/UXReader/PDFium/libpdfium.a(cpdf_formcontrol.o)) was built for newer iOS version (10.0) than being linked (8.0)
My project need be for iOS 8.0, but the libraries are compile with iOS 10.
How to solve it?
THIRD PROBLEM
I merge and link with all libraries (.a), but when i use with a sample project i still have some functions not linked inside the library “.a”:

FOURTY PROBLEM
How to build with bitcode support? How to enable and disable it?
FINISH
Can anyone help me with this problems?
Thanks.
Issue Analytics
- State:
- Created 5 years ago
- Comments:34 (18 by maintainers)
libpdfium.a
Architectures in the fat file: ./libpdfium.a are: armv7 i386 x86_64 arm64 P.S. for simulator, you should add libz.tbd to your target.
platform:iOS 8.
pdfium commit hash: a38996be8
@hhartz I was able to fix the third problem too. Besides that I think I can automate those manual patching steps too. I am busy with something else right now. I will commit all I can do once I get some free time.