Skip to content

No link with 25.0.1 #64

Description

@Hubilari

-Using GtkAda 24.0.0, i've installed 25.0.1 version with success (below) but the linker was unable to do the job.
The error message indicates compile again with -fPIE, I hadn't any success with this recompilation, same error.
-Configuration is Ubuntu 24.04.1 LTS. On On a Ryzen AMD 8 cores 64 bits with 16Go RAM.
Thanks
Mark

=== Building ================

$ alr get --build gtkada
ⓘ Deploying gtkada=25.0.1...
-=O=- # # # #
ⓘ Running post-fetch actions for gtkada=25.0.1...
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking target system type... x86_64-pc-linux-gnu
checking for pkg-config... /usr/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
etc....
[Ada] gtk-grid.adb
[C] misc_generated.c
[C] misc.c
/media/4To/Donnees/Courrier/020-Ada/X-Bibliotheque/gtkada_25.0.1_d3787772/src/misc.c: In function 'ada_g_module_build_path':
/media/4To/Donnees/Courrier/020-Ada/X-Bibliotheque/gtkada_25.0.1_d3787772/src/misc.c:161:3: warning: 'g_module_build_path' is deprecated [-Wdeprecated-declarations]
161 | return g_module_build_path (directory, module_name);
| ^~~~~~
In file included from /usr/include/glib-2.0/gio/giomodule.h:31,
from /usr/include/glib-2.0/gio/gio.h:102,
from /usr/include/gtk-3.0/gdk/gdkapplaunchcontext.h:28,
from /usr/include/gtk-3.0/gdk/gdk.h:32,
from /media/4To/Donnees/Courrier/020-Ada/X-Bibliotheque/gtkada_25.0.1_d3787772/src/misc.c:38:
/usr/include/glib-2.0/gmodule.h:142:23: note: declared here
142 | gchar* g_module_build_path (const gchar *directory,
| ^~~~~~~~~~~~~~~~~~~
Build Libraries
[gprlib] gtkada.lexch
[archive] libgtkada.a
[index] libgtkada.a

gtkada=25.0.1 successfully retrieved and built.
Dependencies were solved as follows:

+📦 libgtk3 3.24.41 (new,system package)
+📦 make 4.3.0 (new,system package)
+📦 pkg_config 1.8.1 (new,system package)

======= Building End =====

====== Compile & link ======

$ ./compile.sh

Compilation de glade_9 25.01.2025

Bind
[gprbind] glade_9.bexch
[Ada] glade_9.ali
Link
[link] glade_9.adb
/usr/bin/ld: /media/4To/Donnees/Courrier/020-Ada/X-Bibliotheque/gtkada_25.0.1_d3787772/src/lib/gtkada/static/libgtkada.a(misc.o): relocation R_X86_64_32 against `.rodata.str1.1' can not be used when making a PIE object; recompile with -fPIE
/usr/bin/ld : impossible de fixer les tailles des sections dynamiques : bad value
collect2: error: ld returned 1 exit status
gprbuild: link of glade_9.adb failed
gprbuild: failed command was: /usr/bin/gcc-13 glade_9.o b__glade_9.o /media/4To/Donnees/Courrier/020-Ada/M-Sources/020-GtkAda-Glade/170-Glade/A-Exemples/Ex_9/B-objali/Release/window_callbacks.o /media/4To/Donnees/Courrier/020-Ada/X-Bibliotheque/gtkada_25.0.1_d3787772/src/lib/gtkada/static/libgtkada.a -L/media/4To/Donnees/Courrier/020-Ada/X-Bibliotheque/gtkada_25.0.1_d3787772//lib -L/media/4To/Donnees/Courrier/020-Ada/X-Bibliotheque/gtkada_25.0.1_d3787772//bin -lgtk-3 -lgdk-3 -lz -lpangocairo-1.0 -lpango-1.0 -lharfbuzz -latk-1.0 -lcairo-gobject -lcairo -lgdk_pixbuf-2.0 -lgio-2.0 -lgobject-2.0 -lglib-2.0 -Wl,--export-dynamic -lgmodule-2.0 -pthread -lglib-2.0 -lglib-2.0 -lfontconfig -lfreetype -L/media/4To/Donnees/Courrier/020-Ada/M-Sources/020-GtkAda-Glade/170-Glade/A-Exemples/Ex_9/B-objali/Release/ -L/media/4To/Donnees/Courrier/020-Ada/M-Sources/020-GtkAda-Glade/170-Glade/A-Exemples/Ex_9/B-objali/Release/ -L/media/4To/Donnees/Courrier/020-Ada/X-Bibliotheque/gtkada_25.0.1_d3787772/src/lib/gtkada/static/ -L/usr/lib/gcc/x86_64-linux-gnu/13/adalib/ -shared-libgcc -lgnat-13 -ldl -Wl,-rpath-link,/usr/lib/gcc/x86_64-linux-gnu/13//adalib -Wl,-z,origin,-rpath,$ORIGIN/../../../../../..//X-Bibliotheque/gtkada_25.0.1_d3787772/lib:$ORIGIN/../../../../../..//X-Bibliotheque/gtkada_25.0.1_d3787772/bin:$ORIGIN/..//B-objali/Release:$ORIGIN/../../../../../..//X-Bibliotheque/gtkada_25.0.1_d3787772/src/lib/gtkada/static:/usr/lib/gcc/x86_64-linux-gnu/13/adalib -o /media/4To/Donnees/Courrier/020-Ada/M-Sources/020-GtkAda-Glade/170-Glade/A-Exemples/Ex_9/Z-exec//glade_9
dubois@PC:/media/4To/Donnees/Courrier/020-Ada/M-Sources/020-GtkAda-Glade/170-Glade/A-Exemples/Ex_9/Z-exec$
====== Compile & link END ======

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions