Osmo version 0.2.14 patched for libgtkhtml

Moderator: BarryK

Post Reply
User avatar
BarryK
Posts: 2692
Joined: Tue Dec 24, 2019 1:04 pm
Has thanked: 132 times
Been thanked: 738 times

Osmo version 0.2.14 patched for libgtkhtml

Post by BarryK »

My blog post explains:

https://bkhome.org/news/202201/osmo-pim ... in-oe.html

Pup and pup-derivative developers would be interested in this.

I have created a woofQ template, packages-templates/osmo, like you have in woof-CE, that has a script in /root/Startup to start osmo in the systray at startup, and a skeleton /root/.osmo/config.xml file:

Code: Select all

<?xml version="1.0"?>
<osmo_config>
  <general>
    <date_format>2</date_format>
    <time_format>0</time_format>
    <enable_systray>1</enable_systray>
    <start_minimised_in_systray>1</start_minimised_in_systray>
    <blink_on_events>1</blink_on_events>
    <override_locale_settings>1</override_locale_settings>
    <web_browser>defaultbrowser %s</web_browser>
    <email_client>defaultemail %s</email_client>
    <sound_player>aplay %s</sound_player>
  </general>
  <calendar>
    <di_show_current_day_distance>0</di_show_current_day_distance>
    <di_show_week_number>0</di_show_week_number>
    <di_show_weekend_days>0</di_show_weekend_days>
    <di_show_moon_phase>0</di_show_moon_phase>
  </calendar>
</osmo_config>

The template also deletes /usr/share/applications, as don't start it from the menu anymore.

User avatar
rudyt
Posts: 26
Joined: Tue Sep 21, 2021 1:19 am
Location: Montreal, Canada
Been thanked: 1 time

Re: Osmo version 0.2.14 patched for libgtkhtml

Post by rudyt »

Barry, did you investigate using the latest version of Osmo (currently at 0.4.2) instead of 0.2.14? The Osmo webpage you linked lists the webkit2gtk library as Optional.

I'm guessing you have other reasons for staying with the older version (probably bloat) , but it doesn't hurt to ask ;-)

Proud Puppy user since 2007 (Puppy 4.x)

User avatar
OscarTalks
Posts: 623
Joined: Tue Jul 14, 2020 10:11 pm
Location: London UK
Has thanked: 2 times
Been thanked: 247 times

Re: Osmo version 0.2.14 patched for libgtkhtml

Post by OscarTalks »

BarryK,
Thanks for this. Patched version of 0.2.14 compiled in my remastered "everyday" Wheezy and Stretch Pups. All seems OK at first glance.

rudyt,
There is 0.4.4 available as well, but from version 0.4.0 it was migrated to GTK+3 among other things.
In the case of 0.2.14 without any patches, it was possible to configure the build without the webkitgtk optional dependency (--without-contacts disable Contacts module), but then the Contacts database feature (and tab) would be missing from the build.

User avatar
BarryK
Posts: 2692
Joined: Tue Dec 24, 2019 1:04 pm
Has thanked: 132 times
Been thanked: 738 times

Re: Osmo version 0.2.14 patched for libgtkhtml

Post by BarryK »

Yes, that is an interesting question about 0.4.x

I restored libgtkhtml for 0.2.12, took a bit of work, then more work for 0.2.14. I just assumed that the 0.4.x series would be too different. But maybe not...

What you could try, is grab 0.4.4 source, and my patch for 0.2.14:

https://distro.ibiblio.org/easyos/sourc ... html.patch

Apply the patch. There will be failures, and there will be .rej files created showing the failures.
If 0.4.4 is not too different, it might be possible to manually fix the failures.

If succeed, delete all the .orig and .rej files, and create a diff patch, relative to the original 0.4.4. Basically, like this:

Code: Select all

# diff -Naur osmo-0.4.4ORIG osmo-0.4.4NEW > osmo-0p4p4-restore-libgtkhtml.patch

I have to take off, family gathering today. Any of you guys interested in attempting this, go for it.

User avatar
BarryK
Posts: 2692
Joined: Tue Dec 24, 2019 1:04 pm
Has thanked: 132 times
Been thanked: 738 times

Re: Osmo version 0.2.14 patched for libgtkhtml

Post by BarryK »

I think all the 0.4.x series is gtk3.
If that's the only real difference, then maybe not worth the hassle. Unless there are some more improvements and fixes.
But then, I know that dimkr wants to migrate everything in his next-gen puppy off of gtk2 to gtk3.

User avatar
BarryK
Posts: 2692
Joined: Tue Dec 24, 2019 1:04 pm
Has thanked: 132 times
Been thanked: 738 times

Re: Osmo version 0.2.14 patched for libgtkhtml

Post by BarryK »

Back from the family gathering... you have got me curious whether this can be done. Applying the patch:

Code: Select all

# cp -a osmo-0.4.4 osmo-0.4.4ORIG
# cd osmo-0.4.4
# patch -p1 < ../osmo-0p2p14-restore-libgtkhtml.patch 
patching file configure.ac
Hunk #1 succeeded at 131 with fuzz 2 (offset -10 lines).
Hunk #2 succeeded at 150 (offset -10 lines).
Hunk #3 succeeded at 275 (offset -2 lines).
patching file data/osmo.1
Reversed (or previously applied) patch detected!  Assume -R? [n] 
Apply anyway? [n] 
Skipping patch.
1 out of 1 hunk ignored -- saving rejects to file data/osmo.1.rej
patching file data/osmo.desktop
patching file README
Hunk #1 FAILED at 78.
1 out of 1 hunk FAILED -- saving rejects to file README.rej
patching file src/calendar.c
Hunk #1 succeeded at 550 with fuzz 2 (offset -18 lines).
Hunk #2 FAILED at 678.
Hunk #3 FAILED at 750.
Hunk #4 succeeded at 2237 with fuzz 2 (offset -115 lines).
Hunk #5 succeeded at 2251 (offset -126 lines).
2 out of 5 hunks FAILED -- saving rejects to file src/calendar.c.rej
patching file src/contacts.c
Hunk #1 FAILED at 226.
Hunk #2 FAILED at 255.
Hunk #3 succeeded at 364 with fuzz 2 (offset -7 lines).
Hunk #4 succeeded at 1097 with fuzz 2 (offset -49 lines).
2 out of 4 hunks FAILED -- saving rejects to file src/contacts.c.rej
patching file src/gui.h
Hunk #1 succeeded at 41 with fuzz 2 (offset -4 lines).
Hunk #2 succeeded at 395 with fuzz 2 (offset 8 lines).
Hunk #3 succeeded at 494 with fuzz 1 (offset 15 lines).
Hunk #4 succeeded at 593 with fuzz 1 (offset 18 lines).
patching file src/Makefile.am
patching file src/tasks.c
Hunk #1 FAILED at 224.
Hunk #2 FAILED at 277.
Hunk #3 FAILED at 1886.
3 out of 3 hunks FAILED -- saving rejects to file src/tasks.c.rej
patching file src/utils.c
Hunk #1 succeeded at 148 (offset -49 lines).
patching file src/utils.h
Hunk #1 succeeded at 100 (offset -3 lines).
#

I am now working through it manually, see if it is achievable.

User avatar
JakeSFR
Posts: 276
Joined: Wed Jul 15, 2020 2:23 pm
Been thanked: 159 times

Re: Osmo version 0.2.14 patched for libgtkhtml

Post by JakeSFR »

I extensively use 0.2.10 in Fatdog, so I built 0.2.14 with your patches, but unfortunately I noticed two problems right away:

- both Tasks and Contacts don't show anything in "Task/Contact details:" in the bottom part of the window (slide it up using the "......." handle, if not visible) after clicking a task or a contact,
- Tasks' order is broken, e.g. 2023-12-04 shows before 2022-02-21 and even if I click the "Due date" header, then the already completed tasks take over the top of the list.

Greetings!

[O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource
Omnia mea mecum porto.
User avatar
BarryK
Posts: 2692
Joined: Tue Dec 24, 2019 1:04 pm
Has thanked: 132 times
Been thanked: 738 times

Re: Osmo version 0.2.14 patched for libgtkhtml

Post by BarryK »

JakeSFR wrote: Mon Jan 17, 2022 12:33 pm

I extensively use 0.2.10 in Fatdog, so I built 0.2.14 with your patches, but unfortunately I noticed two problems right away:

- both Tasks and Contacts don't show anything in "Task/Contact details:" in the bottom part of the window (slide it up using the "......." handle, if not visible) after clicking a task or a contact,
- Tasks' order is broken, e.g. 2023-12-04 shows before 2022-02-21 and even if I click the "Due date" header, then the already completed tasks take over the top of the list.

Greetings!

Hmmm, yes. I might redo the patch. I learnt some improvements today while patching 0.4.4.

User avatar
BarryK
Posts: 2692
Joined: Tue Dec 24, 2019 1:04 pm
Has thanked: 132 times
Been thanked: 738 times

Re: Osmo version 0.2.14 patched for libgtkhtml

Post by BarryK »

Ha ha, success creating patch for 0.4.4.
However:

Code: Select all

# make
....
In file included from /usr/include/gtkhtml-2.0/libgtkhtml/document/htmldocument.h:33,
                 from /usr/include/gtkhtml-2.0/libgtkhtml/view/htmlview.h:31,
                 from gui.h:45,
                 from about.h:25,
                 from about.c:22:
/usr/include/gtkhtml-2.0/libgtkhtml/document/htmlparser.h:67:2: error: unknown type name ‘GtkObjectClass’
   67 |  GtkObjectClass parent;
      |  ^~~~~~~~~~~~~~
make[2]: *** [Makefile:524: about.o] Error 1
make[2]: Leaving directory '/mnt/sda1/downloads/downloads2/input596/0-osmo2/osmo-0.4.4-p2/src'

Yes, it doesn't like libgtkhtml being gtk2!

Ref: https://docs.gtk.org/gtk3/migrating-2to3.html

Well, two ways to go here. Either convert libgtkhtml to gtk3, or convert osmo 0.4.4 to gtk2

User avatar
BarryK
Posts: 2692
Joined: Tue Dec 24, 2019 1:04 pm
Has thanked: 132 times
Been thanked: 738 times

Re: Osmo version 0.2.14 patched for libgtkhtml

Post by BarryK »

There is some good news. The patched 0.2.12 works properly.

I have removed the 0.2.14 source:

https://distro.ibiblio.org/easyos/sourc ... betical/o/

I compiled osmo-0.2.12-p2.tar.gz, and it all seems to be working.

I wonder what has broken it in 0.2.14? Perhaps could go to the osmo git site and pick out commits between 0.2.12 and 0.2.14, see if any worth having.

Post Reply

Return to “EasyOS”