-
-
Notifications
You must be signed in to change notification settings - Fork 89
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problems to solve to be perfect #1
Comments
Thank you for saving my time by providing this script. I am still working on this project but let me share the solution to your first problem. You can use these args:
Please see the symbol_level documentation for further details. Although my need to build PDFium on iOS is for a different purpose and due to that I have some other issues rather than what you have mentioned here, I will see if can find any solution for them. |
Ok. I will test it now. It is args for gen or for ninja call? Im trying for gen now. |
My first problem is about merge all that libraries. The file size is too big. |
This is to fix the issued mentioned in the following issue as the first problem: paulocoutinhox#1 With this change I am able to achieve a 38 Mb universal .a file rather than a gigabyte file.
I hope that suggested change has also reduced the files sizes for you. |
@raghuwanshi maybe make a pull request? |
@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. |
Try change file |
@chml I tried that but that did not fix all errors. Then I found the real solution. I will commit that and make a pull request. |
I use the following patch file, which also removes the need for the whole chromium checkout (as it doesn't build the iossim test); http://ix.io/1lvz |
This is to fix the issued mentioned in the following issue as the first and third problem: paulocoutinhox#1 With this change I am able to achieve a 38 Mb universal .a file rather than a gigabyte file. Linker errors; which were thrown during build of application using this library; are also fixed. Other two problems mentioned in the issue are not related to the project I am working on. I will not be able to work on them.
@raghuwanshi did you manage to get |
@hhartz I am using it for Xamarin.iOS. I was able to build my application for all four platforms i.e. ARM, ARM64, x86 and x64 |
@raghuwanshi I'm getting linker issues for armv7, can you confirm your app builds when archiving, and that you have armv7 as one of the architectures?
|
I merged the pull request, but im still getting errors: Generated PDFium release: Sample project: ** replace "libpdfium.a" from project to lib inside "pdfium-release.zip". And have a lot of warnings about iOS version different from the used version for .a library. |
But all .a files is inside the main .a file. They are merged. |
The problems in related to arm64. It is running fine on simulator. I think that zlib or something is not compiling to arm64. |
ARMv7:
ARM64:
|
libpdfium.a |
I managed to get it building + running myself, by reverting the change that use libjpeg_turbo instead of libjpeg. @Changzw can you confirm it actually compiles if you archive a target which has armv7? in my experience it will fail due to having some specific SIMD symbols missing, even if |
I don't have armv7 devices and test armv7, but this lib can be archived. |
@Changzw Put here what config you use to: 1 - Change the iOS version that library was built Thanks. |
@prsolucoes In this branch you'll see instructions for how to build pdfium with working armv7. I took the liberty of copying your make.py (with attribution in the commit), and have a set of changes/reverts to make it work all outlined in the README.md. Basically it reverts the use of libjpeg_turbo to libjpeg. An improvement would be to only use that for arm and let it use libjpeg_turbo for other architectures, which I haven't gotten around to (yet). I played around with settings various compiler flags as mentioned in various threads, as well as adding gas-preprocessor.pl to PATH without any luck. Not a lasting solution, but it's the hammer that solves my issue at the moment :) The compiled binary can be fetched in |
I did it. use this link to download .a |
@Changzw As described in my earlier comments, I already have a working setup. Also, you should probably provide a build config instead, as people should have full control over the code they release to their customers. |
@hhartz Can you help me modify my script to build all with success? I want leave this repository as a reference to everyone that need it. After i will do the same for Android. |
it is a very huge project :( ! I not only change source code depended by pdfium, but also update UXReader code to support latest pdfium version and pdfium building config . Sorry, I don't have enough time to do this. |
@Changzw Thank you so much, I will report back with my results. |
Hi, I solved all problems. It is working now. Check travis and new README file for instructions. I something can be better, please report. Thanks. |
Maybe someone could help here: |
Hi, Problems solved. I have reimplemented read string methods from two files to solve memory bugs:
Now it is working very well on all devices. Thanks. |
Hi,
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:
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:
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:
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.
The text was updated successfully, but these errors were encountered: