problem with swt4-gtk update

2020-12-28 Thread Sudip Mukherjee
Hi Emmanuel,

With the latest update of swt4-gtk to 4.18.0-1 I am seeing a problem
in loading the library. After a little debugging it seems its not
finding a symbol.

/usr/lib/jni/libswt-pi3-gtk-4940r23.so: undefined symbol:
gdk_texture_new_from_file

Then it tries to find "/usr/lib/jni/libswt-pi4-gtk.so" which is not
present and so the application fails.

Any ideas?


-- 
Regards
Sudip



Re: problem with swt4-gtk update

2020-12-28 Thread Sudip Mukherjee
Hi Emmanuel,

On Mon, Dec 28, 2020 at 10:33 PM Sudip Mukherjee
 wrote:
>
> Hi Emmanuel,
>
> With the latest update of swt4-gtk to 4.18.0-1 I am seeing a problem
> in loading the library. After a little debugging it seems its not
> finding a symbol.
>
> /usr/lib/jni/libswt-pi3-gtk-4940r23.so: undefined symbol:
> gdk_texture_new_from_file
>
> Then it tries to find "/usr/lib/jni/libswt-pi4-gtk.so" which is not
> present and so the application fails.
>
> Any ideas?

'gdk_texture_new_from_file' is from gtk4 and the below patch will fix
the problem.
Do you want me to go ahead with this change ?


diff --git a/debian/rules b/debian/rules
index 803ce85a..f23618c4 100755
--- a/debian/rules
+++ b/debian/rules
@@ -2,7 +2,7 @@

 include /usr/share/dpkg/pkg-info.mk

-export DEB_CFLAGS_MAINT_APPEND=-fPIC
+export DEB_CFLAGS_MAINT_APPEND=-fPIC -DNO_gdk_1texture_1new_1from_1file
 DEB_BUILD_MAINT_OPTIONS=hardening=+all
 include /usr/share/dpkg/buildflags.mk
 CFLAGS+=$(CPPFLAGS)


-- 
Regards
Sudip



Re: problem with swt4-gtk update

2020-12-28 Thread Thorsten Glaser
On Tue, 29 Dec 2020, Sudip Mukherjee wrote:

> +export DEB_CFLAGS_MAINT_APPEND=-fPIC -DNO_gdk_1texture_1new_1from_1file

-D goes to CPPFLAGS, not CFLAGS.

bye,
//mirabilos
-- 
tarent solutions GmbH
Rochusstraße 2-4, D-53123 Bonn • http://www.tarent.de/
Tel: +49 228 54881-393 • Fax: +49 228 54881-235
HRB 5168 (AG Bonn) • USt-ID (VAT): DE122264941
Geschäftsführer: Dr. Stefan Barth, Kai Ebenrett, Boris Esser, Alexander Steeg

*

Mit unserem Consulting bieten wir Unternehmen maßgeschneiderte Angebote in
Form von Beratung, Trainings sowie Workshops in den Bereichen
Softwaretechnologie, IT Strategie und Architektur, Innovation und Umsetzung
sowie Agile Organisation.

Besuchen Sie uns auf https://www.tarent.de/consulting .
Wir freuen uns auf Ihren Kontakt.

*



Re: problem with swt4-gtk update

2020-12-28 Thread Sudip Mukherjee
On Tue, Dec 29, 2020 at 12:18 AM Thorsten Glaser  wrote:
>
> On Tue, 29 Dec 2020, Sudip Mukherjee wrote:
>
> > +export DEB_CFLAGS_MAINT_APPEND=-fPIC -DNO_gdk_1texture_1new_1from_1file
>
> -D goes to CPPFLAGS, not CFLAGS.

oops. thanks Thorsten. So the modified patch is pasted below. But even
if we add it to CPPFLAGS it will eventually get added to CFLAGS as
d/rules is doing "CFLAGS+=$(CPPFLAGS)".


diff --git a/debian/rules b/debian/rules
index 803ce85a..5add19ce 100755
--- a/debian/rules
+++ b/debian/rules
@@ -3,6 +3,7 @@
 include /usr/share/dpkg/pkg-info.mk

 export DEB_CFLAGS_MAINT_APPEND=-fPIC
+export DEB_CPPFLAGS_MAINT_APPEND=-DNO_gdk_1texture_1new_1from_1file
 DEB_BUILD_MAINT_OPTIONS=hardening=+all
 include /usr/share/dpkg/buildflags.mk
 CFLAGS+=$(CPPFLAGS)


-- 
Regards
Sudip



Re: problem with swt4-gtk update

2020-12-28 Thread Thorsten Glaser
On Tue, 29 Dec 2020, Sudip Mukherjee wrote:

> if we add it to CPPFLAGS it will eventually get added to CFLAGS as
> d/rules is doing "CFLAGS+=$(CPPFLAGS)".

Maybe, but it’s the semantically right thing after all ;-)

Maybe the upstream build system will become unbroken one day and
not require that any more, and then it’ll not need fixing up.

bye,
//mirabilos
-- 
tarent solutions GmbH
Rochusstraße 2-4, D-53123 Bonn • http://www.tarent.de/
Tel: +49 228 54881-393 • Fax: +49 228 54881-235
HRB 5168 (AG Bonn) • USt-ID (VAT): DE122264941
Geschäftsführer: Dr. Stefan Barth, Kai Ebenrett, Boris Esser, Alexander Steeg

*

Mit unserem Consulting bieten wir Unternehmen maßgeschneiderte Angebote in
Form von Beratung, Trainings sowie Workshops in den Bereichen
Softwaretechnologie, IT Strategie und Architektur, Innovation und Umsetzung
sowie Agile Organisation.

Besuchen Sie uns auf https://www.tarent.de/consulting .
Wir freuen uns auf Ihren Kontakt.

*



Re: problem with swt4-gtk update

2020-12-28 Thread Sudip Mukherjee
On Tue, Dec 29, 2020 at 12:38 AM Thorsten Glaser  wrote:
>
> On Tue, 29 Dec 2020, Sudip Mukherjee wrote:
>
> > if we add it to CPPFLAGS it will eventually get added to CFLAGS as
> > d/rules is doing "CFLAGS+=$(CPPFLAGS)".
>
> Maybe, but it’s the semantically right thing after all ;-)

Agreed.
So, I will wait for any other objection or Ack till tomorrow night and
then upload.

-- 
Regards
Sudip



Re: problem with swt4-gtk update

2020-12-28 Thread Emmanuel Bourg
Le 29/12/2020 à 01:46, Sudip Mukherjee a écrit :

> So, I will wait for any other objection or Ack till tomorrow night and
> then upload.

Thank you for spotting issue. Please go ahead and upload the fix.

Emmanuel Bourg