02-22-2009, 11:17 AM | #1 |
Member
Posts: 10
Karma: 14
Join Date: Dec 2008
Location: China
Device: irex iliad
|
fbreader 0.10.2
Hi,
I just comile fbreader 0.10.2 for iliad, with the adam's vm, and other people' experience, now it's running on my iliad, currently I change toolbar icon with my own habbit, replace undo/redo with nextpage/previouspage, and findprevious/findnext with nextTOCsection/previousTOCsection, and help with exit, I just ensure the card version working on my SD card, the cf for cf card version doesn't try, and because the icon work perfect, so I don't concern with the hardware key. you just download the package, and unrar to your SD/CF card root and name it fbreader, and change the permission with 755, you can got it running within contentlist, for people who want to direct open file with extension, maybe you will need modify registry, For now, I don't know how to do it with script to create a package, anybody want to help me do it? Just give it a try, though something maybe not so comfortable. Good luck. Mike Hi all, For those who are not professional programmer also, here is what I do when I compile ipdf&fbreader for my iliad: 1. download adam.B virtual machine, then official SDK from: http://developer.irexnet.com/pub/iLi...091648.tar.bz2 2.use putty login debian, and use command (ifconfig) to find out what the IP address for your vm(it's depend on what's the network setting on your vmware), then change it according to your need on file /etc/network/interfaces 3.use winscp to copy the SDK to vm /tmp directory, command (su - developer) to become the only user can run scratchbox, then use command (scratchbox) then choose select->iliad-dev to enter into developer environment 4.setup the PKG_CONFIG_PATH to your login shell with (vi .bash_profile) and add one line: export PKG_CONFIG_PATH=/usr/local/arm/oe/arm-linux/lib/pkgconfig 5.tar -xvf oe-sdk-20071004091648.tar.bz2 to root directory. 6.you can compile the ipdf&fbreader now, caution:all the file I download to vm tmp directory, and all these files will be wipe out after restart. 7.ipdf compile example: cd /tmp tar xvf fullscreen-1.0a1-svn25.tar.bz2 cd trunk-new/ ./autogen.sh and following one line is very important, when configure script generate the make file, it will insert the predefined LD_LIBRARY_PATH for you, but when you compile, must export this variable to the compile path: export LD_LIBRARY_PATH=/usr/local/arm/oe/arm-linux/lib make then you will find ipdf in src directory, if you like you can use command (strip) to strip out the debug symbol and therefore reduce the binary size much smaller. for the fbreader the compile is another long long story, if you have patient, you can read below: at the very first I was very exciting that I can compile ipdf and produce my first touch version ipdf as I want, then I think I can compile fbreader, though I know it's difficult, but never think I need so long time to finish it(almost one month), I list the problem below: 1. I want to set up another platform according to the /fbreader-0.10.2/makefiles/target.mk, but soon I know I can't finish that, so I tried with this config TARGET_ARCH = desktop UI_TYPE = gtk and quickly I find I missing lib for expat, libcurl,libz,libbz2,liblinebreak,libfribidi, all these lib described in file README.build at the root directory of the source ocode f the fbreader. it's time to download these lib and compile one by one. 2. I can compile the fbreader, but don't know where the binary have been put, so I open every file under the makefiles, several file worth mention: config.mk the fbreader zlibrary compile include lib path and compile flag target.mk what's platform and the release/debug version for your target platform desktop.mk the UI gtk incude lib path and the install dir for the target ok, change desktop.mk INSTALLDIR=/usr/local to INSTALLDIR=/tmp I got the binary version of fbreader,it's cool, but soon I be sad, it won't running both on vmware(irex-iliad) and iliad, what's wrong? I search a lot on mobileread forum, and got many useful info to drive me go on: https://www.mobileread.com/forums/showthread.php?t=10035 this thread let me know I must insert some code into the fbreader source to let the pageflip bar respond to fbreader, much later I use adam.B's diff file for 0.8.2b, that patch to fbreader to compile for iliad. https://www.mobileread.com/forums/showthread.php?t=33369 this thread let me know how to add one line code to produce which library are missing when run fbreader, so I copy the code to the corresponding position to get the missing lib name: libfribidi.so.0 libexpat.so.1 libcurl.so.4 libpng.so.3 ok, time to test, yeah! it's running on vmware(iliad-irex), happy never last for long time, when I copy it to iliad, nothing happen except led blink serveral second. What's wrong? I try to copy the who /usr/local/lib that locate in iliad-dev environment to fbreader/lib and put onto iliad simulate the test environment, and install adam.B's 0.8.4fbreader and override all the file with the one I compiled, still nothing happen, I almost give up, because I'm not a programmer, I just read a little of programming book as interest, never writing code. I think I can do something for my iliad this thought still drive me going on. Then, I want to know where's the problem, gdb give me some hope, I looking for how gdb work, but it's too complex and difficult to learn quickly, anyway, try it, at the beginning, I meet a big problem, gdb doesn't run fbreader on iliad-dev environment, why? search a lot, the answer is: the debug only can be on the target running gdbserver, and network connect or serial connect to host to debug, now time to compile gdbserver, fortunately the gdbserver inside gdb 6.1 compiled without problem, but when I put it on iliad, and use command gdbserver :7000 FBReader and run command (gdb), then command (target remote ip-address:7000 FBReader), I can run and can see the source code when I type break 3, but it won't display zlibrary function's source code, why? finally, I put the fbreader and fbreader source code in the same directory both vmware and iliad, then on gdb, type (add-symbol-file the path to include the libzlcore.so.0.10&libzltext.so.0.10) that fbreader depends on, and type (set debug-file-directory) to include the source code directory, ok I can step by step running the fbreader on iliad, finally I see where is the problem, when it running, it always to find the path defined in desktop.mk INSTALLDIR=/tmp, the path that test on vmware, so I change it to /media/card/fbreader, recompile, it just as same as before:led blink several second nothing happen, debug again, this time I see endless loop on process some file fbreader/share/FBReader/formats/fb2 directory, I change the name of fb2genres.xml to another one because I saw some special character in this file, ok this time fbreader are display on my iliad, but without any response with pageflip bar and doesn't refresh any time, when I touch on some icon on the toolbar and press the home key, the screen do changed, I know this is a running version of fbreader for my iliad. it's time to insert the diff file line by line to the source code with adam.B patch for 0.8.2b version to respond to the hardware key, the code I used as below: diff -r fbreader-0.8.2b/zlibrary/src/gtk/application-desktop/ ZLGtkApplicationWindow.cpp fbreaderiliad/zlibrary/src/gtk/application- desktop/ZLGtkApplicationWindow.cpp 65a66,67 > gtk_window_set_title(GTK_WINDOW(myMainWindow), "sh"); > gtk_window_set_wmclass(GTK_WINDOW(myMainWindow), "sh", "sh"); diff -r fbreader-0.8.2b/zlibrary/src/gtk/application-desktop/ ZLGtkApplicationWindow.h fbreaderiliad/zlibrary/src/gtk/application- desktop/ZLGtkApplicationWindow.h 52c52 < void setCaption(const std::string &caption) { gtk_window_set_title (myMainWindow, caption.c_str ()); } --- > void setCaption(const std::string &caption) { gtk_window_set_title (myMainWindow, "sh"); } diff -r fbreader-0.8.2b/zlibrary/src/gtk/view-desktop/ ZLGtkViewWidget.cpp fbreaderiliad/zlibrary/src/gtk/view-desktop/ ZLGtkViewWidget.cpp 24c24,25 < --- > #include <liberdm/erdm.h> > #include <liberipc/eripcbusyd.h> 26a28,30 > erClientChannel_t erbusyChannel; > erClientChannel_t ertoolbarChannel; 92a97,101 > // Turn off busy LED if we were invoked via [SHELL] > erIpcStartClient(ER_BUSYD_CHANNEL, &erbusyChannel); > busySetBusy(erbusyChannel, ccBusyState_Off); > dmDisplay(dmCmdPriorNormal, dmQFull); after this time of compile, fbreader are running on my iliad, but the display alway not satisfied, so I remove the last line dmDisplay(dmCmdPriorNormal, dmQFull); from source code and use xepdmgr to control the refresh issue, now I have a functional fbreader, but the key still not function properly as defined by the option.xml used by adam.B, I don't know how to change it, but I have another way to meet my needs, I use the icon inside the /fbreader/share/pixmaps/FBReader/ directory, and put some icon into it, and rename it the action defined in source code fbreader-0.10.2/fbreader/src/fbreader/FBReaderActionCode.cpp: const std::string ActionCode::SHOW_READING = "showReading"; const std::string ActionCode::SHOW_COLLECTION = "showLibrary"; const std::string ActionCode::SHOW_NET_LIBRARY = "showNetLibrary"; const std::string ActionCode::SHOW_OPTIONS = "preferences"; const std::string ActionCode::UNDO = "undo"; const std::string ActionCode::REDO = "redo"; const std::string ActionCode::SHOW_CONTENTS = "toc"; const std::string ActionCode::SEARCH = "search"; const std::string ActionCode::FIND_PREVIOUS = "findPrevious"; const std::string ActionCode::FIND_NEXT = "findNext"; const std::string ActionCode::LARGE_SCROLL_FORWARD = "largeScrollForward"; const std::string ActionCode::LARGE_SCROLL_BACKWARD = "largeScrollBackward"; const std::string ActionCode::SMALL_SCROLL_FORWARD = "smallScrollForward"; const std::string ActionCode::SMALL_SCROLL_BACKWARD = "smallScrollBackward"; const std::string ActionCode::MOUSE_SCROLL_FORWARD = "mouseScrollForward"; const std::string ActionCode::MOUSE_SCROLL_BACKWARD = "mouseScrollBackward"; const std::string ActionCode::TAP_SCROLL_FORWARD = "tapScrollForward"; const std::string ActionCode::TAP_SCROLL_BACKWARD = "tapScrollBackward"; const std::string ActionCode::SCROLL_TO_HOME = "gotoHome"; const std::string ActionCode::SCROLL_TO_START_OF_TEXT = "gotoSectionStart"; const std::string ActionCode::SCROLL_TO_END_OF_TEXT = "gotoSectionEnd"; const std::string ActionCode::CANCEL = "cancel"; const std::string ActionCode::INCREASE_FONT = "increaseFont"; const std::string ActionCode:ECREASE_FONT = "decreaseFont"; const std::string ActionCode::SHOW_HIDE_POSITION_INDICATOR = "toggleIndicator"; const std::string ActionCode::TOGGLE_FULLSCREEN = "toggleFullscreen"; const std::string ActionCode::FULLSCREEN_ON = "onFullscreen"; const std::string ActionCode::ADD_BOOK = "addBook"; const std::string ActionCode::SHOW_BOOK_INFO = "bookInfo"; const std::string ActionCode::SHOW_HELP = "showHelp"; const std::string ActionCode::ROTATE_SCREEN = "rotate"; const std::string ActionCode::QUIT = "quit"; const std::string ActionCode::OPEN_PREVIOUS_BOOK = "previousBook"; const std::string ActionCode::GOTO_NEXT_TOC_SECTION = "nextTOCSection"; const std::string ActionCode::GOTO_PREVIOUS_TOC_SECTION = "previousTOCSection"; const std::string ActionCode::COPY_SELECTED_TEXT_TO_CLIPBOARD = "copyToClipboard"; const std::string ActionCode::CLEAR_SELECTION = "clearSelection"; const std::string ActionCode::OPEN_SELECTED_TEXT_IN_DICTIONARY = "openInDictionary"; const std::string ActionCode::GOTO_PAGE_NUMBER = "gotoPageNumber"; const std::string ActionCode::GOTO_PAGE_NUMBER_WITH_PARAMETER = "gotoPageNumberWithParameter"; const std::string ActionCode::SEARCH_ON_NETWORK = "searchOnNetwork"; const std::string ActionCode::ADVANCED_SEARCH_ON_NETWORK = "advancedSearchOnNetwork"; const std::string ActionCode::ORGANIZE_BOOKS_BY_AUTHOR = "byAuthor"; const std::string ActionCode::ORGANIZE_BOOKS_BY_TAG = "byTag"; like nextTOCSection.png(the image resolution I used is 32*32, other don't know), and change the install directory /fbreader/share/FBReader/default/toolbar.xml, replace the string after <button id="undo"/> with my <button id="nextTOCSection"/> after done this, I don't need to conside how the fbreader respond to the hardware key:-) but I still want to more read area on iliad, and I find the original code can't enter/exit fullscreen mode, and I modify a little to source code /fbreader-0.10.2/zlibrary/ui/src/gtk/application-desktop/ZLGtkApplicationWindow.cpp add one line at the beginning static int fullscreenFlag=0; add one line within void ZLGtkApplicationWindow::setFullscreen after the fullscreen function finished fullscreenFlag=1; and one line after the unfullscreen function finished fullscreenFlag=1; and replace function bool ZLGtkApplicationWindow::isFullscreen() const { return gdk_window_get_state(GTK_WIDGET(myMainWindow)->window) & GDK_WINDOW_STATE_FULLSCREEN; } with bool ZLGtkApplicationWindow::isFullscreen() const { return fullscreenFlag; } now the fullscreen mode can normally function, but on iliad, still need modify the install file /fbreader/share/FBReader/default/fullscreen_toolbar.xml, you can define yourself function icon or just copy all from toolbar.xml as you want. my icon sequence as below: showReading|showLibrary|addBook|showNetLibrary|got oHome|largeScrollForward|largeScrollBackward|gotoP ageNumberWithParameter|toc|search|nextTOCSection|p reviousTOCSection|bookInfo|preferences|rotate|togg leFullscreen|quit Currently I don't make sure how to make a correct installer for all you. I tried with ipkg-build tool to produce a ipk installer,but I realize that I must test the install root on cf/sd/internal memory, and test the /usr/local directory created before reside on which medium, or whether I need to create it by myself, all these can't be done without strong shell knowledge, I don't want to brick anyones iliad, before I make sure it just running as I expect, so I still don't make a installer. the attach is cf/sd card of fbreader binary, unzip it to your root directory and run it from contentlister, if want hardware key function, pls copy the option.xml to the .FBReader/ directory on your cf/sd card, should be _local\home\.FBReader if you installed adam.B's fbreader, for people who success running on his iliad, pls report here which version you used, so other one know it's a working version, therefore can give it a try. good luck! another one is the source code of fbreader0.10.2 I modified as your reference, pls rename the extension to tgz because mb doesn't accept tgz I change it to tar. especially thanks for: adam.B for developer vmware, and the patch for fbreader and other great work done on iliad platform. ericshliao for how to send the debug info to screen for fbreader lib handling. Antartica for xepdmgr control the fbreader screen refresh and so many kindly people, without your creative work, the fbreader 0.10.2 won't be running on my iliad. thank you all! Last edited by istudy; 02-28-2009 at 10:25 AM. Reason: updates |
02-22-2009, 09:19 PM | #2 |
Connoisseur
Posts: 56
Karma: 28
Join Date: Jun 2008
Location: Athens/Greece
Device: Prs-500/Iliad v2
|
fbreader
Hello istudy Thanks very much for your program I download it cf ver i copy it to cf i tried to run it it and it does like loading for some seconds and then nothing but i dont know how to do the 755 is that my mistake ?
|
Advert | |
|
02-23-2009, 07:40 AM | #3 |
Addict
Posts: 325
Karma: 1725
Join Date: Dec 2007
Location: Münster, Germany
Device: iRex iLiad v2
|
Doing a chmod 0755 on the CF card is usually not necessary as it's a FAT filesystem. Changing permissions works only on the root partition (/).
|
02-23-2009, 01:14 PM | #4 |
Connoisseur
Posts: 80
Karma: 111
Join Date: Apr 2008
Device: iliad V2; ipad 2-64GB,3G
|
Quick question regarding Chmod
Hi Thomas,
What will be the best way to do chmod 755/777 on a root partition,I had this issue with wikipedia, on a ext2 mini USB stick, and I was not able to resolve that issue. I have requested some help from you fellow "gurus" but never got any... Can we change the mod (chmod 755/777) 1) Using mxrvt installed on the internal memory 2) Should we have to use Putty and SSH on the iliad to connect to the iliad root system and be able to make the change 3) Can we simply apply chmod 755 on the usb stick, under Ubuntu and using the terminal... Thank you very much for your consideration. Dabon |
02-24-2009, 05:09 AM | #5 |
Apeist
Posts: 2,126
Karma: 381090
Join Date: Oct 2008
Location: The sunny part of California
Device: Generic virtual reality story-experiential device
|
Any chance this can be integrated with the new ContentLister into a native installer, for the less advanced among us?
|
Advert | |
|
02-24-2009, 08:51 AM | #6 | |
Addict
Posts: 325
Karma: 1725
Join Date: Dec 2007
Location: Münster, Germany
Device: iRex iLiad v2
|
Quote:
Code:
chmod 0755 /whatever/your/file But not to confuse anyone: USB sticks, CF or SD cards are usually formatted with a FAT filesystem, and a chmod is not necessary there (it doesn't even work, so don't bother ) |
|
02-24-2009, 09:11 AM | #7 |
Connoisseur
Posts: 80
Karma: 111
Join Date: Apr 2008
Device: iliad V2; ipad 2-64GB,3G
|
Thank you very much for your response, Thomas!
Very helpful!! Take good care, Dabon. |
02-24-2009, 05:43 PM | #8 |
Enthusiast
Posts: 28
Karma: 10
Join Date: Nov 2007
Device: Irex Technologies Iliad
|
for the new FBReader.
I know it was asked but please can any of the gurus here make a simple install package, something that replaces the old one if it can be done. It has been a long time since a new application was released for us simple users. Thanks, Ido |
02-25-2009, 03:09 PM | #9 | |
Apeist
Posts: 2,126
Karma: 381090
Join Date: Oct 2008
Location: The sunny part of California
Device: Generic virtual reality story-experiential device
|
Quote:
Or, if possible, at least some idiot-proof instructions on how to integrate this (ideally, together with ContentLister) into the iLiad OS? |
|
02-26-2009, 09:37 AM | #10 |
Enthusiast
Posts: 26
Karma: 11
Join Date: Jan 2009
Location: Spain
Device: iLiad
|
I really am out of time now but, couldn't you take the installer of the previous version of FBReader around here and adapt it to this version?
If you got to compile it, I think it shouldn't be too much of a problem for you to adapt the installer to your version. I took a look at it some time ago and if I recall properly it is quite clear what it does.... it's just a matter of a few bash scripts. |
03-06-2009, 04:37 PM | #11 |
Apeist
Posts: 2,126
Karma: 381090
Join Date: Oct 2008
Location: The sunny part of California
Device: Generic virtual reality story-experiential device
|
Sorry to be a pest.
Would it be possible to integrate this into the OS, maybe together with the new Content Manager, and have it in an idiot-proof installer? I don't know how difficult this would be (thus "idiot-proof"), but I am sure a lot of iLiad users would appreciate it greatly. |
03-06-2009, 05:09 PM | #12 |
Connoisseur
Posts: 80
Karma: 111
Join Date: Apr 2008
Device: iliad V2; ipad 2-64GB,3G
|
Hi Sonist,
I fifth, sixth and seventh your request After your request, I was hoping that one of our "beloved Gurus", will have the time to package the all thing with "an idiot prof" installer (including registry change), as they have done so many times in the past, for people like me: "Linux illiterates" ; but it seems that they are pretty busy right now.... I still hope that this day will come.... Thanks, Dabon. |
03-10-2009, 05:12 PM | #13 |
Apeist
Posts: 2,126
Karma: 381090
Join Date: Oct 2008
Location: The sunny part of California
Device: Generic virtual reality story-experiential device
|
O.K., I am going to cry....
|
03-11-2009, 11:58 AM | #14 |
Connoisseur
Posts: 80
Karma: 111
Join Date: Apr 2008
Device: iliad V2; ipad 2-64GB,3G
|
|
03-13-2009, 05:34 PM | #15 |
Enthusiast
Posts: 28
Karma: 10
Join Date: Nov 2007
Device: Irex Technologies Iliad
|
Installer please, installer please
Ido |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Classic FBReader? | JDługosz | Barnes & Noble NOOK | 2 | 07-13-2010 11:28 PM |
Get FBReader 0.10.7 on OS 5.0 | rogue_ronin | Alternative Devices | 11 | 09-27-2009 06:53 AM |
fbreader on v3? | ckphk | HanLin eBook | 7 | 03-31-2009 04:04 AM |
where fbreader is placed? | artur | iRex | 11 | 07-23-2008 02:38 PM |
Why use FBReader? | DeathtoToasters | iRex | 4 | 01-21-2008 01:34 PM |