konsole: awful hack to restore builds on some targets

This commit is contained in:
q66 2020-12-15 02:34:21 +01:00
parent 056c5b2765
commit 9a42c3ecc4

View file

@ -20,6 +20,41 @@ if [ "$CROSS_BUILD" ]; then
configure_args+=" -DDESKTOPTOJSON_EXECUTABLE=/usr/bin/desktoptojson"
fi
post_configure() {
# there is some really awful race in cmake or something
#
# careful inspection of a diff between a working platform and a broken
# one (seemingly every big endian target) reveals that this dependency
# is not added in these specific files and these file only; that results
# in build errors like:
#
# [ 98%] Linking CXX shared library ../bin/libkdeinit5_konsole.so
# /usr/bin/ld: ../ProfileModel.cpp.o: undefined reference to `vtable for Konsole::ProfileModel'
#
# this is obviously a horrible hack, but also debugging this seems pretty
# non-trivial to say the least, and honestly i am not in the mood for
# debugging this either, it's frustrating enough as it is
#
# next release we should try if this still fails, and in case it magically
# gets fixed, remove this and pretend i've never made this change
#
# (git will remember, and it will haunt me forever, that is my punishment)
#
[ -n "$(grep 'konsoleprofile_autogen/mocs_compilation' \
build/src/CMakeFiles/kdeinit_konsole.dir/build.make)" ] && return 0
msg_normal "cursed build system encountered, brace for impact\n"
vsed -i "s,^kdeinit_konsole_EXTERNAL_OBJECTS =,& $(pwd)/build/src/profile/CMakeFiles/konsoleprofile.dir/konsoleprofile_autogen/mocs_compilation.cpp.o," \
build/src/CMakeFiles/kdeinit_konsole.dir/build.make
echo "bin/libkdeinit5_konsole.so: src/profile/CMakeFiles/konsoleprofile.dir/konsoleprofile_autogen/mocs_compilation.cpp.o" \
>> build/src/CMakeFiles/kdeinit_konsole.dir/build.make
vsed -i "s,ProfileShortcutDelegate.cpp.o,& profile/CMakeFiles/konsoleprofile.dir/konsoleprofile_autogen/mocs_compilation.cpp.o," \
build/src/CMakeFiles/kdeinit_konsole.dir/link.txt
}
konsole5_package() {
build_style=meta
short_desc+=" (transitional dummy package)"