Education Project/Effort/Various adaptations on Sugar/Work In Progress

From Apache OpenOffice Wiki
Jump to: navigation, search

@Adbdelkader and Thomas, please add there what you are currently doing

Means :

  • a list of tasks
  • the history
  • a planning
  • whatever information needed for the current work in progress, and who will be removed once put in a better shape elsewhere


First Objective : Compilation of OOo and OOo4Kids

After four days of desperate struggles with Ubuntu, packages and lack of space on the hard drive, both Abdelkader and myself have been able to generate and launch the makefile of OOo this afternoon. This will last the whole night, hopefully void of compilation error.

After 8 hours, the compilation ended for both of us.

Then, we had to compile OOo4Kids. We had a tough time getting past some errors, but they were almost all caused by using a wrong version of the sources so we had to apply a patch. After this, we had to build && deliver from the *new* scp2 directory but not to forget to make an "export PKGFORMAT="installed" (we went through some errors forgetting this). Then all we had to do was to make a dmake.

Then, we worked on a small installation problem on Linux. In fact, the installation directory have the pref, and it shouldn't. In the common_brand.scp (which is located in scp2/sources/ooo/) from line 829 to 843 we can see few conditions, depending the system, to put the things on the good place. It works well on Macsosx and Windows but it goes in the wrong place for linux, it hits the "StandaloneValue = "$ORIGIN/..". We don't really understand why yet but we will work on this later. Then, we tried some tests on OOo4Kids with valgrind, we saw some memory leaks and we will see about this.

The next step is for me to work on building OOo4Kids for Windows and work on the wiki page for this step and for Thomas to build OOo4Kids on Sugar.


IRC meeting / 17th July 2009

Attendees : Thomas Fontenay, Abdelkader Bellabes, Eric Bachard

Point 1 : what has been done

  • OOO build on Linux : verified OK
  • OOo4Kids build on Linux : verified OK
  • First steps in the source code
  • Started with Valgrind ( log of the leak ?)

Point 2 : Planning for the two coming weeks 30 and 31 ( 17th to 31st July) :

Action Items :

  • document the use of Valgrind
  • document the memory leak (supposed)

Objectives for the next two weeks are :

  • ( Abdelkader) setup Windows install set, and build OOo4Kids + complete the wiki page (OOo4Kids wiki page, Windows dedicated)
  • ( Thomas ): setup a Sugar set, and do the same

Objective : complete two builds in 2 differents OS's

  • start documenting Valgrind use
  • start working with gdb, in particular, be able to set breakpoints in 3 cases :
  1. at a given line
  2. using a given method
  3. when a condition is true

+ providing examples

(if time allows) Case study : catch and trace what happens when changing some color. e.g. changing the color of the background in a Writer document

Objective : trace and document

Scheduled : IRC meeting to make a point around the 3rd August

20/07/09-HOW TO : Crash OOo4Kids

Today, we have been working on watching when OOo4Kids was using a lot of the CPU's power. Going with this, we saw a few cases when it was maybe overdooing and some times crashed:

  -Using a special character and pasting it recklessly would end up with a crash.
  -On the same way, but without special chars (so that may be linked in a way), OOo4Kids is in some cases stopping and you have to go to the next line to be able to put an other char, or in other cases, it's not responding anymore.

Some other cases of huge delay/crashes:

   -In OOo4Kids Writer : fill one page of text, copy it. Paste it, again, again, ag... Around page 15, pasting will stop and the user is unable to write anymore. From this point on, OOo4Kids become extremely unstable, and will crash if you erase the last character written and try to write something else, select a different font...
   -Everything that is "drag'n'droppable" may be victim of extreme delay (and CPU overuse) if you try to be too fast. Same thing goes with the "draw line" in the writer. Moreover, if you draw a huge pack of lines in the writer, trying to type text will make the CPU skyrocket to 95%+ usage (whereas without lines, it won't go over 30-35%). Same goes with scrolling up and down on a filled page.

21/07/09-HOW TO : Use Gdb

Few subtle experimentations on a simple C++ program to learn how to break :

-at a given line:

(gdb) attach #processnumber

{Loading...}

(gdb) break 7

Breakpoint 1 at 0x8048918: file zzz.cpp, line 7.

(gdb) run


Observations : I'm yet to fine how to select the correct file. This syntax will break line number 'x' in the file containing the main.


-using a given methode

(gdb) attach #processnumber

{Loading...}

(gdb) break Class::method

Breakpoint 1 at 0x8048932: file Test.cpp, line 18.

(gdb) run


Observations : just like setting the breakpoint for a function, except you have to precise which class the method belongs to. Breakpoint will occur each time the method is called.


-when a condition is true

(gdb) attach #processnumber

{Loading...}

(gdb) break randomfunction

Breakpoint #brkpoint at 0x8048757: file main.cpp, line 9.

(gdb) condition #brkpoint i==5

(gdb) continue


Observations: #brkpoint is the breakpoint number that will be associated with the condition. In this case, the breakpoint will only occur when the variable i equals 5. Of course, trying to set a wrong condition is not possible.


Using gdb, one of the crashes has been localized !

Here is how I proceeded:

(gdb) attach #OOo4kidsPID

{Loading...}

(gdb) continue

Continuing.

..


From this point on, using OOo4Kids, I go to one the crash point I mentioned few days ago (the one about copying and pasting a whole page). Just as planned, OOo4Kids crashes. I go back on the terminal.

^C Program received signal SIGINT, Interrupt. [Switching to Thread 0xb5a93920 (LWP 5391)] 0xaeb1eb30 in ?? ()

from /home/twarz/OOo/DEV300_m52/instsetoo_native/unxlngi6.pro/OOo4Kids/installed/install/fr/ooo4kids0.4/program/../basis-link/program/libswli.so

(gdb)

The interesting thing is that the execution apparently stopped in the "libswli.so" library. Therefore, there is a good probability that the problem is located here. Time to build the library with the debugging symbols...


  • Building OOo4Kids on Sugar

... was going smoothly until I typed "make" in the terminal. Few things to know: I'm using the Sugar on a Stick "Strawberry" version of Sugar on a 4GB USB flash device, which is way too little to contain the sources of OOo4Kids. Therefore, I stocked them on an external drive for the time being. The configure was successfully passed, but a little problem came up when trying to launch the compilation:

"tar : [pretty much every file from the boost_1_34_1 directory]  : Cannot change ownership to uid 501, gid 501 : operation not permitted"

This line repeated for many if not all the files from the boost_1_34_1 directory. Still trying to find a correction, though I suspect the source of the problem is that I use this external drive to stock the sources...

  • Building OOo4Kids at Home

I tried building OOo4Kids on a more recent computer than the first time. Compiling OOo was okay, but when I apply the patch for OOo4Kids, run the configure / bootstrap / everything, the compilation will always send this error line: "dmake: /home/twarz/OOo/OpenOfficeSrc/DEV300_m52/solenv/inc/unxlngx6.mk: line 142: Error: -- Expecting macro or rule defn, found neither"

I'm still trying to fix this issue, but I'm a bit at a loss of words: I even tried to copy/paste the solenv directory from the working OOo4Kids build and it still doesn't work.

  • Buildind OOo4Kids on Windows Vista

Building OOo4Kids on Windows Vista is not that hard, but there is still some trouble to go through this process. Actually, until using CPAN on Cygwin. Until then, this is going smoothly but i had some trouble installing Archive::Zip and URI modules, after many unsucsessful try, it worked suddenly: i just made a reboot. Then applying the patch, the configure and all the other things went smoothly till the build. I tried on different version of OOo4Kids and even on OOo and there is still the same building problem that i don't know how to go through:

echos: Command not found. d:/OOo4Kids/DEV300_m52/solver/300/wntnsci12.pro/bin: Permission denied. dmake: Error code 1, while making '../wntmsci12.pro/obj/wrap_hidclex.obj' dmake: '../wntmsci12.pro/obj/wrap_hidclex.obj' removed. runnid processes: 0

3 module(s): hsqldb stax soltools need(s) to be rebuilt

Reasons:

ERROR: error 65280 occured while making /cygdrive/d/OOo4Kids/DEV300_m52/stax ERROR: error 65280 occured while making /cygdrive/d/OOo4Kids/DEV300_m52/soltools/support ERROR: error 65280 occured while making /cygdrive/d/OOo4Kids/DEV300_m52/soltools/HIDCompiler ERROR: error 65280 occured while making /cygdrive/d/OOo4Kids/DEV300_m52/hsqld

I'm still trying to go through this.

Personal tools