Bug 423280 - rust-qt-binding-generator templates fail to build with mingw64
Summary: rust-qt-binding-generator templates fail to build with mingw64
Status: RESOLVED UNMAINTAINED
Alias: None
Product: rust-qt-binding-generator
Classification: Unmaintained
Component: general (show other bugs)
Version: unspecified
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Jos van den Oever
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-06-20 16:37 UTC by mhavrlent
Modified: 2024-09-22 20:07 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description mhavrlent 2020-06-20 16:37:34 UTC
SUMMARY
rust-qt-binding-generator templates fail to build with mingw64

STEPS TO REPRODUCE
1. git clone https://github.com/KDE/rust-qt-binding-generator.git
2. cd rust-qt-binding-generator/templates/qt_widgets
3. mkdir build
4. cd build
5. cmake ..
6. make

OBSERVED RESULT
$ make
[ 11%] Generating ../rust/target/release/librust.a
warning: unnecessary parentheses around type
   --> src\interface.rs:108:42
    |
108 |     let s: *const c_char = v.as_ptr() as (*const c_char);
    |                                          ^^^^^^^^^^^^^^^ help: remove these parentheses
    |
    = note: `#[warn(unused_parens)]` on by default

    Finished release [optimized] target(s) in 0.01s
[ 22%] Built target rust_target
[ 33%] Automatic MOC and UIC for target MyExe

AutoMoc subprocess error
------------------------
The content generation command for "SRC:/build/MyExe_autogen/moc_predefs.h" failed.

Command
-------
/mingw64/bin/CC.exe -dM -E -c /usr/share/cmake-3.17.3/Modules/CMakeCXXCompilerABI.cpp -DQT_CORE_LIB -DQT_GUI_LIB -DQT_NO_DEBUG -DQT_WIDGETS_LIB -I/mingw64/include -I/mingw64/include/QtWidgets -I/mingw64/include/QtGui -I/mingw64/include/QtCore -I/mingw64/share/qt5/mkspecs/win32-g++

Output
------


make[2]: *** [CMakeFiles/MyExe_autogen.dir/build.make:79: CMakeFiles/MyExe_autogen] Error 1
make[1]: *** [CMakeFiles/Makefile2:153: CMakeFiles/MyExe_autogen.dir/all] Error 2
make: *** [Makefile:104: all] Error 2


EXPECTED RESULT
successful build


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 mhavrlent 2020-06-20 16:40:22 UTC
$ make --version
GNU Make 4.3
Built for x86_64-pc-msys
Copyright (C) 1988-2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
$ cmake --version
cmake version 3.17.3

CMake suite maintained and supported by Kitware (kitware.com/cmake).
$ gcc --version
gcc.exe (Rev2, Built by MSYS2 project) 10.1.0
Copyright (C) 2020 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Comment 2 Jos van den Oever 2020-07-06 18:15:54 UTC
If you have a patch, I can consider it. I do not have a windows system to test on.
Comment 3 Christoph Cullmann 2024-09-22 20:07:54 UTC
rust-qt-binding-generator is no longer maintained, please try more recent alternatives like

https://github.com/KDAB/cxx-qt/