connected to the project at Ada QT libraries - qt5

When connecting to a project on Ada QT library produces errors.
with QT; use QT;
.....
Log.
E:\GNAT\2013\qtada\qt-qchar.o:qt-qchar.adb:(.text+0x14): undefined reference to QChar1_create'
E:\GNAT\2013\qtada\qt-qchar.o:qt-qchar.adb:(.text+0x30): undefined reference toQChar2_create'
E:\GNAT\2013\qtada\qt-qchar.o:qt-qchar.adb:(.text+0x5a): undefined reference to QChar3_create'
E:\GNAT\2013\qtada\qt-qchar.o:qt-qchar.adb:(.text+0x6f): undefined reference toQChar4_create'
E:\GNAT\2013\qtada\qt-qchar.o:qt-qchar.adb:(.text+0x8b): undefined reference to QChar5_create'
E:\GNAT\2013\qtada\qt-qchar.o:qt-qchar.adb:(.text+0xa7): undefined reference toQChar6_create'
E:\GNAT\2013\qtada\qt-qchar.o:qt-qchar.adb:(.text+0xbb): undefined reference to QChar7_create'
E:\GNAT\2013\qtada\qt-qchar.o:qt-qchar.adb:(.text+0xcf): undefined reference toQChar8_create'
E:\GNAT\2013\qtada\qt-qchar.o:qt-qchar.adb:(.text+0xe3): undefined reference to QChar_latin1'
e:/gnat/2013/bin/../libexec/gcc/i686-pc-mingw32/4.7.4/ld.exe: E:\GNAT\2013\qtada\qt-qchar.o: bad reloc address 0x20 in section.eh_frame'
e:/gnat/2013/bin/../libexec/gcc/i686-pc-mingw32/4.7.4/ld.exe: final link failed: Invalid operation
collect2.exe: error: ld returned 1 exit status
gprbuild: link of main.adb failed
[2014-04-28 08:15:40] process exited with status 4 (elapsed time: 01.50s)

Are your installed QT,QTADA libraries compatible with the Mingw-Toolchain? Also regarding the bitness 32/64. The Versions of your libraries and the compile/linker command would be helpful.
You might also consider following hint:
GMP with MinGW on Windows

Related

Undefined symbol: _swift_getOpaqueTypeConformance - React Native & SwiftUI

I'm trying to port a SwiftUI view into react native following this guide. It build fine in swift project but not in a react native project.
I'm getting the following error:
Undefined symbols for architecture x86_64:
"_swift_getOpaqueTypeConformance", referenced from:
lava.ColorWheelView.body.getter : some in ColorWheelView.o
closure #2 (SwiftUI.GeometryProxy) -> <<opaque return type of lava.ColorWheelView.makeView(SwiftUI.GeometryProxy) -> some>>.0 in lava.ColorWheelView.body.getter : some in ColorWheelView.o
associated type witness table accessor for SwiftUI.View.Body : SwiftUI.View in lava.ColorWheelView : SwiftUI.View in lava in ColorWheelView.o
l_get_witness_table qd0__7SwiftUI4ViewHD3_AaBPAAE7gesture_9includingQrqd___AA11GestureMaskVtAA0F0Rd__lFQOyAA15ModifiedContentVyAA6ZStackVyAA05TupleC0VyAJyAA06_ShapeC0VyAA9RectangleVAA5ColorVGAA12_FrameLayoutVG_AJy4lava010GuitarPickC0VAA13_OffsetEffectVGtGGAA09_PositionP0VG_AA06_EndedF0VyAA0f5StateF0VyAA08_ChangedF0VyAA04DragF0VGSo7CGPointVSgGGQo_HO in ColorWheelView.o
associated type witness table accessor for SwiftUI.View.Body : SwiftUI.View in lava.TrianglePath : SwiftUI.View in lava in GuitarPickView.o
associated type witness table accessor for SwiftUI.View.Body : SwiftUI.View in lava.GuitarPickView : SwiftUI.View in lava in GuitarPickView.o
"_swift_getTypeByMangledNameInContextInMetadataState", referenced from:
___swift_instantiateConcreteTypeFromMangledNameAbstract in ColorWheelView.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
To reproduce I made this Github repo
Copy those files in a react native project and try to build. Make sure to replace the header file import with your test project name "<Replace This>-Swift.h"
My build target is iOS 13.5 iPhone 11 Pro Max simulator.

Problems compiling with libsoup (gstreamer)

I have build the gst-build Gstreamer 1.18 version, after installing libsoup2.4-dev and I can see that the dependency is detected:
|Dependency libsoup-2.4 found: YES 2.62.1 (cached).
Later on, compiling the project that I am developing related with WebRTC I have the following issue. How can I solve it?
undefined reference to `soup_websocket_connection_close'
undefined reference to `soup_logger_new'
undefined reference to `soup_websocket_connection_get_state'
undefined reference to `soup_message_new'
undefined reference to `soup_session_websocket_connect_async'
undefined reference to `soup_session_new_with_options'
undefined reference to `soup_session_websocket_connect_finish'
undefined reference to `soup_session_add_feature'
undefined reference to `_SOUP_METHOD_GET'
undefined reference to `soup_websocket_connection_send_text'
undefined reference to `soup_session_feature_get_type
collect2: error: ld returned 1 exit status

Installation of FluentBit failing at make stage

I'm trying to install FluentBit on Centos.
While running make it fails at 83% and I'm unable to understand the error. Cannot find anything in the web relating to this. Can someone please help me.
[ 83%] Building C object src/CMakeFiles/fluent-bit-bin.dir/fluent-bit.c.o
[ 83%] Building C object src/CMakeFiles/fluent-bit-bin.dir/flb_dump.c.o
Linking C executable ../bin/fluent-bit
../library/libflb-plugin-filter_grep.a(grep.c.o): In function `delete_rules':
grep.c:(.text+0x4e3): undefined reference to `flb_ra_destroy'
../library/libflb-plugin-filter_grep.a(grep.c.o): In function `set_rules':
grep.c:(.text+0x861): undefined reference to `flb_ra_create'
../library/libflb-plugin-filter_grep.a(grep.c.o): In function `grep_filter_data':
grep.c:(.text+0xa6a): undefined reference to `flb_ra_regex_match'
../library/libflb-plugin-filter_rewrite_tag.a(rewrite_tag.c.o): In function `process_config':
rewrite_tag.c:(.text+0x9b5): undefined reference to `flb_ra_create'
rewrite_tag.c:(.text+0xa9c): undefined reference to `flb_ra_destroy'
rewrite_tag.c:(.text+0xade): undefined reference to `flb_ra_create'
rewrite_tag.c:(.text+0xb3b): undefined reference to `flb_ra_destroy'
../library/libflb-plugin-filter_rewrite_tag.a(rewrite_tag.c.o): In function `process_record':
rewrite_tag.c:(.text+0xf6a): undefined reference to `flb_ra_regex_match'
rewrite_tag.c:(.text+0xfe2): undefined reference to `flb_ra_translate'
../library/libflb-plugin-filter_rewrite_tag.a(rewrite_tag.c.o): In function `destroy_rules':
rewrite_tag.c:(.text+0x12a3): undefined reference to `flb_ra_destroy'
rewrite_tag.c:(.text+0x12b3): undefined reference to `flb_ra_destroy'
collect2: error: ld returned 1 exit status
make[2]: *** [bin/fluent-bit] Error 1
make[1]: *** [src/CMakeFiles/fluent-bit-bin.dir/all] Error 2
make: *** [all] Error 2

undefined reference to `__cxa_throw_bad_array_new_length

There are several posts citing this (or similar) undefined references, but none of those was of help.
I have code which compiles nicely on gentoo 4.14.83, with both gcc-7.3.0 and gcc-8.2.0.
On CentOS 7 (CentOS Linux release 7.6.1810 (Core)), however, the linker of g++-7.3.1 says:
/home/jody/progs/multi_spc_QHG3/kernel/Geography.cpp:68: undefined reference to `__cxa_throw_bad_array_new_length'
/home/jody/progs/multi_spc_QHG3/kernel/Geography.cpp:69: undefined reference to `__cxa_throw_bad_array_new_length'
/home/jody/progs/multi_spc_QHG3/kernel/Geography.cpp:70: undefined reference to `__cxa_throw_bad_array_new_length'
/home/jody/progs/multi_spc_QHG3/kernel/Geography.cpp:71: undefined reference to `__cxa_throw_bad_array_new_length'
The referenced lines in Geography.cpp have simple new statements:
m_adLatitude = new geonumber[m_iNumCells];
m_adLongitude = new geonumber[m_iNumCells];
m_adAltitude = new geonumber[m_iNumCells];
m_adDistances = new geonumber[m_iNumCells*m_iMaxNeighbors];
(the type geonumber is actually double, m_iNumCells and m_iMaxNeighbors have type int)
Because i need g++ version 7, i use the compiler from devtoolset-7-gcc.x86_64.
Some of the posts i found stated that this error is caused by missing libstdc++, but this is not the case here.
What causes this error, and how can it be fixed?

Link target to libraries

I have a "CMakified" version of CryptoPP and I am using CMake-GUI to create a MakeFile which ming-make could process as shown in the image below.
The "MakeFile" creation was successful but when I executed mingw32-make.exe I got below errors at the very end.
Linking CXX executable cryptest.exe
CMakeFiles\cryptest.dir/objects.a(test.cpp.obj):test.cpp:(.text+0x8e82): undefined reference to `setsockopt#20'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x5cb): undefined reference to `socket#12'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x643): undefined reference to `closesocket#4'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x6f0): undefined reference to `htonl#4'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x70a): undefined reference to `inet_addr#4'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x759): undefined reference to `htons#4'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x7f4): undefined reference to `bind#12'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x85b): undefined reference to `listen#8'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x909): undefined reference to `inet_addr#4'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x922): undefined reference to `gethostbyname#4'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x978): undefined reference to `htons#4'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0xa18): undefined reference to `connect#12'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0xaac): undefined reference to `accept#12'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0xb58): undefined reference to `getsockname#12'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0xbc6): undefined reference to `getpeername#12'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0xc87): undefined reference to `send#16'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0xd83): undefined reference to `recv#16'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0xe25): undefined reference to `shutdown#8'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0xe96): undefined reference to `ioctlsocket#12'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0xfbb): undefined reference to `select#20'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x1010): undefined reference to `select#20'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x11a1): undefined reference to `select#20'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x11f6): undefined reference to `select#20'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x133f): undefined reference to `getservbyname#8'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x1407): undefined reference to `ntohs#4'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x1526): undefined reference to `WSAStartup#8'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x16cf): undefined reference to `WSACleanup#0'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x17fb): undefined reference to `WSAGetLastError#0'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x180f): undefined reference to `WSASetLastError#4'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x1cfc): undefined reference to `WSARecv#28'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x1d27): undefined reference to `WSAGetLastError#0'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x1f61): undefined reference to `WSAGetOverlappedResult#20'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x1f8c): undefined reference to `WSAGetLastError#0'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x2397): undefined reference to `WSASend#28'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x23c1): undefined reference to `WSAGetLastError#0'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x24cc): undefined reference to `WSAEventSelect#12'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x2587): undefined reference to `WSAEnumNetworkEvents#12'
libcryptopp.a(socketft.cpp.obj):socketft.cpp:(.text+0x2a01): undefined reference to `WSAGetOverlappedResult#20'
collect2.exe: error: ld returned 1 exit status
mingw32-make[2]: *** [cryptest.exe] Error 1
mingw32-make[1]: *** [CMakeFiles/cryptest.dir/all] Error 2
mingw32-make: *** [all] Error 2
I tried adding LDLIBS += -lws2_32 to the very end of the make file but this didn't help. I guess these errors are because the target link libraries are not mentioned in the make file but I am not sure how to do this.
CMakeLists.txt should call
target_link_libraries(cryptopp ws2_32)
after command ADD_LIBRARY to resolve undefined references.
After following Kieth's comments above I figured out that neither LIBS nor LDLIBS are honoured by CMAKE. The variable to use is CXX_STANDARD_LIBRARIES. I did the below change in the CMAKE Advanced options:
I added -lws2_32 at the very end and then generated the "MakeFile" .
This solved the issue.