-
Notifications
You must be signed in to change notification settings - Fork 486
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why do we have a dependency on msvcr90 if compiling with MINGW? #291
Comments
in my opinion this is a mistake, I use MSYS2 clang 15.0.5 and MINGW is True
then: |
The pull request #234 states:
|
It is used there: Line 4338 in dc8b8c7
Maybe MinGW didn't implements this before? Or it behaves differently? Clearly it seems to compile fine for you. |
I'm programming in C++ very little, I'm not an expert(I've used Delphi all my life) , but MinGW is broad concept.
In MSYS2-mingw64 and MSYS2-clang64 _set_abort_behavior exists and msvcr90 is unnecessary |
As far as I understand In our case the problem is that I don't see why it's necessary to hardcode a specific redistributable dependency. The same should be obtained by finding whatever is available on the system. As far as I know there's no import library for debug MSVC libraries, so I would suggest to change I can provide a PR for that if you see the point. |
AFAIK import libraries exist but the target EXE is dynamically linked to |
I see the missing --- a/BackwardConfig.cmake
+++ b/BackwardConfig.cmake
@@ -215,10 +215,9 @@ if(WIN32)
if(SUPPORT_WINDOWS_DEBUG_INFO)
set(CMAKE_EXE_LINKER_FLAGS "-Wl,--pdb= ")
add_compile_options(-gcodeview)
- else()
- set(MINGW_MSVCR_LIBRARY "msvcr90$<$<CONFIG:DEBUG>:d>" CACHE STRING "Mingw MSVC runtime import library")
- list(APPEND _BACKWARD_LIBRARIES ${MINGW_MSVCR_LIBRARY})
endif()
+ set(MINGW_MSVCR_LIBRARY "msvcr90$<$<CONFIG:DEBUG>:d>" CACHE STRING "Mingw MSVC runtime import library")
+ list(APPEND _BACKWARD_LIBRARIES ${MINGW_MSVCR_LIBRARY})
endif()
endif()
|
@madebr
could you send link to your mingw compiler, version and CMakeCache.txt from build ? on my msys2 when I turn on I will look at the problem globally |
When I build with Here's my CMakeCache.txt, configured on top of current main (without any patch applied). I'm using a mingw toolchain, provided by my Linux distribution (Fedora 38).
It might be interesting to link with MSVC using |
In my opinion better solution,
|
Or do a Also, the |
Please note also #307 regarding the usage of fixed |
As of 51f0700 there are no unresolved symbols when building with ninja/-DBACKWARD_SHARED=YES/gcc 12.2 |
_set_abort_behavior sets if we want to show a windows error report message or print some text (on the console if any I guess). I don't understand why we should use |
@cowo78 various compilers are included in the word "mingw" (on Windows and Linux) , I am using msys2 and clang , and only CodeView format enable |
I am using GCC 12.2.0/mingw64/msys2; didn't know that CodeView provided better looking traces. |
In my opinion backward-cpp doesn't work in
msys2:mingw64
msys2:clang64
|
@cowo78 in my opinion
|
I see from 146e2ed that
msvcr90
is brought in as a dependency when compiling with MINGW.Could it be clarified what are the dependencies that we have from msvcr?
Why is
msvcr90
(Visual Studio 2008) hardcoded? Shouldn't we link to whatever is available on the system?The text was updated successfully, but these errors were encountered: