-
Notifications
You must be signed in to change notification settings - Fork 164
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
Compil readium SDK branch feature mo smil model #22
Comments
To complete post, I'm under linux debian, I try to compil SDK for install on Android, and test smil audio in my ePub. |
We regret at this time we do not support Debian and the team is so busy we don't have the bandwidth to investigate it at this time. We will consider extending the support after 1.0 is released. |
I am not able to answer specifically for Android, but here is a summary of the Media Overlays state of affairs: (I am on MacOSX 10.7.5, XCode4) === LauncherOSX compiles fine on the "develop" branches of SDKLauncher-OSX, readium-sdk, and readium-shared-js. The app runs fine and opens ebooks without or with Media Overlays (it just dumps some values in the console). === To use the "feature/mo_smil_model" branch of readium-sdk, SDKLauncher-OSX must be on "feature/mo_player2" (otherwise it will not even compile). I suspect that the Android launcher must be updated as well to support the new MO features / updated APIs. Additionally, readium-shared-js must be on the "feature/mo_player" branch, otherwise books will fail to load (the app-specific reader.html cannot load required shared JS files). So, one good step forward to harmonise the codebase, and to enable an upcoming MO merge into "develop", would be to create a branch for the Android launcher, so that it compiles against readium-sdk[ feature/mo_smil_model ], and so that it runs fine with readium-shared-js[ feature/mo_player ]. I am not familiar at all with the Android launcher, but I will take a look to see how I can help. Eclipse right? On 4 Oct 2013, at 16:00, TienHai wrote:
|
Hi Dan, thanks for your reply Yes I used Eclipse |
The first two undefined references: Seem to be due to not linking with Can you please verify that your If your Cheers, Pedro |
Hi Pedro, I just check, but I don't have this file in LOCAL_SRC_FILES |
I was checking and I corrected that missing Maybe if you do a If this is the case, then you cloned/pulled the develop branch in a 'under development' state, before I checked it and corrected the missing file. You should have a file
|
I put Platform/Android/jni/resource_stream.cpp in file Android.mk in LOCAL_SRC_FILES. After retry compil I have: /home/tien/Src/Android/ndk/sources/cxx-stl/gnu-libstdc++/4.7/include/ext/new_allocator.h:110: error: undefined reference to 'ePub3::MediaOverlaysSmilModel::MediaOverlaysSmilModel(std::shared_ptrePub3::Package)' Tien Haï |
Then please update your copy of the code with:
Because you don't have the latest version of the code in develop branch. Cheers, Pedro |
Pedro, Thanks, I can compil SDK in develop branch. But when I open ePub file, the page is blank? |
Did you also update Launcher-Android and readium-shared-js to the latest code in develop? On my side the epub files open ok and show pages. Cheers, Pedro |
good to know pedro, thanks! On Friday, October 4, 2013, Pedro Reis Colaço wrote:
|
Pedro, 1 - I clean up all my Readium directory, and restart with latest code in develop. 2 - When a compil readium-sdk I have some many error: rename ePub3/ThirdParty/libzip/Config.h to config.h After all this correction, I can compil readium-sdk for platform Android with this command line: After compil, import the project under Plateform/Android in eclipse , import the project LauncherAndroid in eclipse. 3 - I launch the App SDKLauncher-Android, but the app not start, have one error: couldn't find class 'org/readium/sdk/android/ResourceInputStream' I found the file ResourceInputStream.java under readium-sdk/Platform/Android/src/org/readium/sdk/android/util I recompiled readium-sdk, and reinstall SDKLauncher-Android app in my device. 4 - App start, I open the ePub cole-voyage-of-life-20120320.epub (I found it inreadium-sdk/TestData/ ) 10-07 12:14:01.711: D/libepub3 ./../../Platform/Android/jni/epub3.cpp:352: EPub3.openBook(): package added Thanks for your help, Tien Haï |
Hello Tien Haï, Hello, I had to execute the "clean" command before "build" every time any .h header file was modified...MarkerHeader.sh did not make any difference. ./readium-sdk/Platform/Android/ndk-compile.sh build /Applications/android-ndk-r9/ Any tip to avoid the time-consuming full rebuild? (localised "clean"?) By the way, as per the README, I applied the following fixes to the NDK, as part of the initial setup: r8e and r9: ${ANDROID_NDK}/ndk-build file -L “$SHELL” | grep -q “x86[_-]64″ ifneq (,$(shell file -L $(SHELL) | grep ‘x86[_-]64′)) ==> REPLACE: r8e: ${ANDROID_NDK}/build/core/build-binary.mk $(cleantarget): PRIVATE_CLEAN_FILES := ($(my)OBJS) ==> ADD THE MISSING DOLLAR SIGN: $($(my)OBJS) Okay, so then I cranked-up Eclipse, and I had to fix a few things (unrelated to Media Overlays) in both the Launcher app and core SDK code: e.g. the ResourceInputStream Java class was in the "util" package, but is referenced elsewhere from the parent package...so I moved it up to avoid having to fix the SDK and recompile everything once more. https://github.com/readium/readium-sdk/commits/feature/mo_smil_model As you can see, I merged the latest "develop" SDK code into my "mo_smil_model" feature branch, to make sure I had all the bleeding-edge Android stuff. I created a new "mo_smil_model" feature branch for the LauncherAndroid app, based on the latest "develop" codebase. Here are the few changes I made to run the app on my device: readium/SDKLauncher-Android@834f432 I have not changed anything in Shared JS, and I used its "develop" branch to test the Android app. Therefore, none of the MO playback stuff has been involved in my tests, only the SMIL-parsing backend. Outcome: the app launches on my device (4.2.2 Jelly Bean), I can read the EPUB files from the SD card ("epubtest" folder), the metadata + TOC(s) are displaying fine, but the content (WebView) is empty. The logcat doesn't really give me any clues. What is the recommended working build of LauncherAndroid? (what branches of readium-sdk and readium-shared-js should I use?) Note: I am preparing some documentation to help port the functioning OSX Media Overlays player to iOS, this should be useful for Android + Windows too. Regards, On 7 Oct 2013, at 11:17, Tien haï wrote:
|
Hi Tien, 1- OK 2- This is due to the use of Linux, since the filesystem is case sensitive and default OSX or Windows isn't. 3- I noted this problem, also reported from other people and will be corrected soon. Thanks. 4- You have to include/enable in your eclipse project dependencies the android-support-v4.jar support library. The error is: |
Hi Daniel, Pedro First thanks for your help. Daniel, I see your post this week. Pedro, after include android-support-v4.jar, the app no crash when try to open ePub file. 10-07 13:06:13.631: I/NavigationTableActivity(6592): Open webview at : 0-intro.xhtml With the latest code in readium-shared-js branch develop. Tien Haï |
Hi Daniel and Tien, Thanks for the reports. Daniel, I replied to your email on the mailing list. Tien, I think these javascript errors are preventing the page from being rendered:
These come from "Web Console" and are generated from within the WebView when going through the javascript that renders the pages. I will try to get some help from the guys that worked more on the javascript and WebView integration parts. |
Pedro, thanks. |
I close this Issue, and open one in Readium Shared JS repository. |
Hi,
I try compil this branch of readium SDK, but a get this error:
./../../Platform/Android/jni/epub3.cpp:261: error: undefined reference to 'onLoad_cacheJavaElements_ResourceInputStream'
./../../Platform/Android/jni/package.cpp:478: error: undefined reference to 'javaResourceInputStream_createResourceInputStream'
/home/tien/Src/Android/ndk/sources/cxx-stl/gnu-libstdc++/4.7/include/ext/new_allocator.h:110: error: undefined reference to 'ePub3::MediaOverlaysSmilModel::MediaOverlaysSmilModel(std::shared_ptrePub3::Package)'
./../../ePub3/ePub/package.cpp:750: error: undefined reference to 'ePub3::MediaOverlaysSmilModel::Initialize()'
collect2: error: ld returned 1 exit status
thanks for your reply,
The text was updated successfully, but these errors were encountered: