• Problems with gprbuild (gnat)

    From reinert@21:1/5 to All on Sat Jun 3 05:58:51 2023
    Hello,

    I use gnat/alire under debian (latest version). Now suddenly I get the confusing error message below after "alr build". Anybody who could give me a hint?

    reinert

    alr build
    ⓘ Building kobio5/kobio5.gpr...
    Link
    [link] kobio0.adb /home/reinert/.config/alire/cache/dependencies/gnat_native_12.2.1_11f3b811/bin/../lib/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: warning: kobio0.o: requires executable stack (because the .note.GNU-stack section is executable)
    /home/reinert/.config/alire/cache/dependencies/gnat_native_12.2.1_11f3b811/bin/../lib/gcc/x86_64-pc-linux-gnu/12.2.0/../../../../x86_64-pc-linux-gnu/bin/ld: kobio0.o: in function `kobio0__execute_command1.242':
    kobio0.adb:(.text+0x351e7): undefined reference to `command_processing1__set_wellplate1'
    collect2: error: ld returned 1 exit status
    gprbuild: link of kobio0.adb failed
    gprbuild: failed command was: /home/reinert/.config/alire/cache/dependencies/gnat_native_12.2.1_11f3b811/bin/gcc kobio0.o b__kobio0.o /home/reinert/kobio5/obj/bzip2.o /home/reinert/kobio5/obj/bzip2-decoding.o /home/reinert/kobio5/obj/split_string.o /home/
    reinert/kobio5/obj/cpros.o /home/reinert/kobio5/obj/gid-buffering.o /home/reinert/kobio5/obj/gid-color_tables.o /home/reinert/kobio5/obj/gid-decoding_bmp.o /home/reinert/kobio5/obj/gid-decoding_gif.o /home/reinert/kobio5/obj/gid-decoding_jpg.o /home/
    reinert/kobio5/obj/gid-decoding_png-huffman.o /home/reinert/kobio5/obj/gid-decoding_png.o /home/reinert/kobio5/obj/gid-decoding_pnm.o /home/reinert/kobio5/obj/gid-decoding_tga.o /home/reinert/kobio5/obj/gid-headers.o /home/reinert/kobio5/obj/gid.o /home/
    reinert/kobio5/obj/gl.o /home/reinert/kobio5/obj/rkutil1.o /home/reinert/kobio5/obj/cell_names0.o /home/reinert/kobio5/obj/cell_names1.o /home/reinert/kobio5/obj/gl-io.o /home/reinert/kobio5/obj/gl-math.o /home/reinert/kobio5/obj/gl-geometry.o /home/
    reinert/kobio5/obj/gl-frustums.o /home/reinert/kobio5/obj/gl-materials.o /home/reinert/kobio5/obj/gl-simple_text.o /home/reinert/kobio5/obj/glu.o /home/reinert/kobio5/obj/gl-errors.o /home/reinert/kobio5/obj/gl-textures.o /home/reinert/kobio5/obj/gl-
    skins.o /home/reinert/kobio5/obj/gl-skinned_geometry.o /home/reinert/kobio5/obj/glut.o /home/reinert/kobio5/obj/glut_2d.o /home/reinert/kobio5/obj/lzma.o /home/reinert/kobio5/obj/lzma-decoding.o /home/reinert/kobio5/obj/version1.o /home/reinert/kobio5/
    obj/file_handling1.o /home/reinert/kobio5/obj/image1.o /home/reinert/kobio5/obj/plot1.o /home/reinert/kobio5/obj/cells.o /home/reinert/kobio5/obj/ctutil1.o /home/reinert/kobio5/obj/scene_objects1.o /home/reinert/kobio5/obj/statistics1.o /home/reinert/
    kobio5/obj/cells-pt_cell_scenes_p.o /home/reinert/kobio5/obj/cells-pt_cell_scenes_p-tree1_parameters1.o /home/reinert/kobio5/obj/network1.o /home/reinert/kobio5/obj/plot_image.o /home/reinert/kobio5/obj/plot_image-plot_cells1_p.o /home/reinert/kobio5/obj/
    io.o /home/reinert/kobio5/obj/command_processing1.o /home/reinert/kobio5/obj/segment_image.o /home/reinert/kobio5/obj/zip_streams.o /home/reinert/kobio5/obj/zip-headers.o /home/reinert/kobio5/obj/zip.o /home/reinert/kobio5/obj/zip-crc_crypto.o /home/
    reinert/kobio5/obj/unzip.o /home/reinert/kobio5/obj/unzip-decompress-huffman.o /home/reinert/kobio5/obj/unzip-decompress.o /home/reinert/kobio5/obj/unzip-streams.o /home/reinert/kobio5/obj/globe_3d-math.o /home/reinert/kobio5/obj/globe_3d-aux.o /home/
    reinert/kobio5/obj/globe_3d-options.o /home/reinert/kobio5/obj/globe_3d-portals.o /home/reinert/kobio5/obj/globe_3d-textures.o /home/reinert/kobio5/obj/globe_3d.o /home/reinert/kobio5/obj/globe_3d-software_anti_aliasing.o /home/reinert/kobio5/obj/game_
    control.o /home/reinert/kobio5/obj/actors.o /home/reinert/kobio5/obj/glut-windows.o /home/reinert/kobio5/obj/glut-devices.o -lglut -lGL -lGLU -L/home/reinert/kobio5/obj/ -L/home/reinert/kobio5/obj/ -L/home/reinert/.config/alire/cache/dependencies/gnat_
    native_12.2.1_11f3b811/lib/gcc/x86_64-pc-linux-gnu/12.2.0/adalib/ -static-libgcc /home/reinert/.config/alire/cache/dependencies/gnat_native_12.2.1_11f3b811/lib/gcc/x86_64-pc-linux-gnu/12.2.0/adalib/libgnarl.a /home/reinert/.config/alire/cache/
    dependencies/gnat_native_12.2.1_11f3b811/lib/gcc/x86_64-pc-linux-gnu/12.2.0/adalib/libgnat.a -lrt -lpthread -lm -ldl -Wl,-rpath-link,/home/reinert/.config/alire/cache/dependencies/gnat_native_12.2.1_11f3b811/lib/gcc/x86_64-pc-linux-gnu/12.2.0//adalib -Wl,
    -z,origin,-rpath,$ORIGIN/..//obj:$ORIGIN/../..//.config/alire/cache/dependencies/gnat_native_12.2.1_11f3b811/lib/gcc/x86_64-pc-linux-gnu/12.2.0/adalib -o /home/reinert/kobio5/bin//kobio0
    error: Command ["gprbuild", "-s", "-j0", "-p", "-P", "/home/reinert/kobio5/kobio5.gpr"] exited with code 4
    error: Compilation failed.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Maxim Reznik@21:1/5 to All on Mon Jun 5 02:59:36 2023
    It's hard to say without the source code. The linker can't find command_processing1__set_wellplate1 symbol used somewhere in kobio0.adb.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From reinert@21:1/5 to All on Tue Jun 6 13:18:10 2023
    The source code is more than 20K lines :-)
    Would be nice with error messages which are easier to understand.
    I did return to the version before the latest changes and retyped - now it works and the Ada goddess smiles to me.

    I googled "gnat undefined reference" and noticed that others also have encountered mysterious "undefined reference to...". Seems one have to be careful and frequently check when developing programmes above some size limit.

    reinert


    mandag 5. juni 2023 kl. 11:59:37 UTC+2 skrev Maxim Reznik:
    It's hard to say without the source code. The linker can't find command_processing1__set_wellplate1 symbol used somewhere in kobio0.adb.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)