Tiny Core Linux

Tiny Core Extensions => TCE Q&A Forum => Topic started by: nimday on March 10, 2016, 11:16:17 AM

Title: Static flwm_topside
Post by: nimday on March 10, 2016, 11:16:17 AM
Is there any reason why the topside is static also i see from this topic (http://forum.tinycorelinux.net/index.php/topic,3306.msg29113.html#msg29113) only 28 kb ?

I checked the source from the git (0.25) and i think this topside doesn't need text rotation stuff like the left side so the static flag can be removed.
About the left side i don't know ,i'm not too comfortable anyway.

Just my curiousity,thanks
 
Title: Re: Static flwm_topside
Post by: curaga on March 10, 2016, 03:47:38 PM
IIRC it wasn't the rotation code, but general code that used some private fltk symbol, requiring static linking.
Title: Re: Static flwm_topside
Post by: nimday on March 10, 2016, 06:38:26 PM
IIRC it wasn't the rotation code, but general code that used some private fltk symbol, requiring static linking.

you're right about the rotation, i just downloaded the latest snapshot from Mr Bill and also bbidulock  (https://github.com/bbidulock/flwm)for comparison and Rotated.C has been removed from both.

Maybe you can check this:

I copied from commit 7dbb70 (https://sourceforge.net/p/flwm/flwm/ci/7dbb3043930c04a2b3eb41abd2b1202e2521beed/) and didn't remove any line from Frame.C but filled the blank lines.
465-470
Code: [Select]
#if FL_MAJOR_VERSION < 2 && FL_MINOR_VERSION < 3
// fltk bug: it does not clear these pointers when window is deleted,
// causing flwm to crash on window close sometimes:
extern Fl_Window *fl_xfocus;
extern Fl_Window *fl_xmousewin;
#endif

480-485
Code: [Select]
#if FL_MAJOR_VERSION < 2 && FL_MINOR_VERSION < 3
  // fix fltk bug:
  fl_xfocus = 0;
  fl_xmousewin = 0;
  Fl::focus_ = 0;
#endif

compileit
Code: [Select]
#!/bin/sh -e

CXXFLAGS="$CXXFLAGS `fltk-config --cxxflags`"
CXXFLAGS="$CXXFLAGS -Wall -ffunction-sections -fdata-sections -Wno-strict-aliasing"
LDFLAGS="$LDFLAGS `fltk-config --ldflags --use-images`"
LDFLAGS="$LDFLAGS -Wl,-gc-sections"

echo Building flwm_topside...
g++ -flto -fuse-linker-plugin -march=i486 -mtune=i686 -Os -pipe -fno-exceptions -fno-rtti -o flwm_topside -DTOPSIDE *.C $CXXFLAGS $LDFLAGS
sstrip flwm_topside

echo Building flwm...
g++ -flto -fuse-linker-plugin -march=i486 -mtune=i686 -Os -pipe -fno-exceptions -fno-rtti -o flwm *.C $CXXFLAGS $LDFLAGS
sstrip flwm


the last issue only for the left side , i have no idea
Code: [Select]
/tmp/ccHTkiVw.ltrans0.ltrans.o: In function `draw_rot90(char const*, int, int, int) [clone .lto_priv.58]':
ccHTkiVw.ltrans0.o:(.text._ZL10draw_rot90PKciii.lto_priv.58+0x37): undefined reference to `Fl_XFont_On_Demand::value()'
ccHTkiVw.ltrans0.o:(.text._ZL10draw_rot90PKciii.lto_priv.58+0x6f): undefined reference to `Fl_XFont_On_Demand::value()'
collect2: error: ld returned 1 exit status

 
Maybe you also can check this commit (https://sourceforge.net/p/flwm/flwm/ci/3938480dc18b56a2eaf3cb9302b6ebfe6cb3064e/)

Thanks
Title: Re: Static flwm_topside
Post by: curaga on March 11, 2016, 03:55:24 AM
Oh, nice, Bill is back in dev. Those two changes should indeed allow linking dynamically with fltk 1.3.

I don't think I'll be doing those for a week or two at least, though.
Title: Re: Static flwm_topside
Post by: Juanito on March 11, 2016, 04:43:36 AM
It'd be nice if we could look at flwm "classic" too  :)
Title: Re: Static flwm_topside
Post by: nimday on March 11, 2016, 05:39:09 PM
Oh, nice, Bill is back in dev. Those two changes should indeed allow linking dynamically with fltk 1.3.

I don't think I'll be doing those for a week or two at least, though.

No problem  :)

It'd be nice if we could look at flwm "classic" too  :)

Where i can see this classic ?

Offtopic:
This forum is fast yahoo can find it, i can't  imagine with google.
Title: Re: Static flwm_topside
Post by: Juanito on March 12, 2016, 05:01:50 AM
By flwm classic, I mean the original flwm with the window title on the left-hand side.
Title: Re: Static flwm_topside
Post by: nimday on April 11, 2016, 09:26:13 PM
Thanks for the update,shared for both now.
Maybe you can update compileit too.
Title: Re: Static flwm_topside
Post by: curaga on April 12, 2016, 04:25:19 AM
It wasn't working with a non-xft build, I'm afraid.