Conversion to the cmake building system. #3

Manually merged
SlavekB merged 1 commits from feat/cmakeConv into master 4 years ago
Ghost commented 5 years ago

A man page has been added.

Some differences with the Deb package:

  • 3 protocol files
  • x-ms-wma.desktop in mimelnk audio
  • x-mplayer2.desktop in mimelnk application.

Rem...koffice header...done!
kmplayerpartbase.cpp L141 hard-coded "cp" unix command...done!

A man page has been added. Some differences with the Deb package: - 3 protocol files - x-ms-wma.desktop in mimelnk audio - x-mplayer2.desktop in mimelnk application. Rem...koffice header...done! kmplayerpartbase.cpp L141 hard-coded "cp" unix command...done!
Ghost added the PR/wip label 5 years ago
Ghost added the PR/rfc label 5 years ago
Owner

Added patch to solve FTBFS in KOffice plugin and patch to complete cmake building of KOffice plugin.

Added patch to solve FTBFS in KOffice plugin and patch to complete cmake building of KOffice plugin.
Ghost removed the PR/wip label 4 years ago
Ghost changed title from WIP:Conversion to the cmake building system. to Conversion to the cmake building system. 4 years ago
Ghost commented 4 years ago
Poster

@SlavekB, please, give It a shot.
Your PRs are ok from my side.

Remember that there are additions in comparison to the Deb package (man page, koffice plugin, protocol and mime files).

@SlavekB, please, give It a shot. Your PRs are ok from my side. Remember that there are additions in comparison to the Deb package (man page, koffice plugin, protocol and mime files).
SlavekB added a new dependency 4 years ago
Owner

@cethyel I was doing another test and I have some findings and questions:

  1. I added include CheckIncludeFileCXX, because I probably forgot in – it's necessary for the koffice plugin test.

  2. I didn't find a reasonable reason why the GStreamer test should have two WITH_... options. You can look for example at Juk in tdemultimedia – there are tested three different versions with one condition. Therefore, I modified the test in kmplayer in a similar way.

  3. I looked at the mentioned protocol files. The problem is that such files are already contained in tdelibs. Here are some differences that would be good to unify. In the final, perhaps the only difference could be that in tdelibs files do not refer to any exec, while in kmplayer it refers to itself.

  4. I looked at the mentioned desktop files and this is a similar situation as with the protocol files == they are already contained in tdelibs and there seems to be no reason to be different. And so there's no reason to install them from kmplayer.

  5. While dealing with the double option for WITH_GSTREAMER, I realized that many WITH_... options are probably wrong because they are redundant or directly conflicting with the BUILD_... options.

    For example, BUILD_KGSTPLAYER=ON together with WITH_GSTREAMER=OFF may causes FTBFS to occur. Conversely, WITH_GSTREAMER=ON together with BUILD_KGSTPLAYER=OFF makes the WITH_GSTREAMER option unnecessary.

    Therefore, I propose to review the WITH_... options and decide which ones are not needed, because BUILD_... will be the decisive option for the appropriate tests.

@cethyel I was doing another test and I have some findings and questions: 1. I added include `CheckIncludeFileCXX`, because I probably forgot in – it's necessary for the koffice plugin test. 2. I didn't find a reasonable reason why the GStreamer test should have two `WITH_...` options. You can look for example at [Juk in tdemultimedia](../tdemultimedia/src/branch/master/juk/ConfigureChecks.cmake#L12) – there are tested three different versions with one condition. Therefore, I modified the test in kmplayer in a similar way. 3. I looked at the mentioned protocol files. The problem is that such files are already contained in tdelibs. Here are some differences that would be good to unify. In the final, perhaps the only difference could be that in tdelibs files do not refer to any `exec`, while in kmplayer it refers to itself. 4. I looked at the mentioned desktop files and this is a similar situation as with the protocol files == they are already contained in tdelibs and there seems to be no reason to be different. And so there's no reason to install them from kmplayer. 5. While dealing with the double option for `WITH_GSTREAMER`, I realized that many `WITH_...` options are probably wrong because they are redundant or directly conflicting with the `BUILD_...` options.<br/><br/>For example, `BUILD_KGSTPLAYER=ON` together with `WITH_GSTREAMER=OFF` may causes FTBFS to occur. Conversely, `WITH_GSTREAMER=ON` together with `BUILD_KGSTPLAYER=OFF` makes the `WITH_GSTREAMER` option unnecessary.<br/><br/>Therefore, I propose to review the `WITH_...` options and decide which ones are not needed, because `BUILD_...` will be the decisive option for the appropriate tests.
Ghost commented 4 years ago
Poster

@SlavekB
I have no ideas what the protocole desktop files play, so I included them in hope that you can shed some light upon.

The gstreamer1/0.10 test like in "juk" is nice addition.

Time has passed and I don't remember why I added the "with" and "build" options on the xine and gstreamer backend engines but It was either to mimic as much I could the configure options (since I don't want to deal with the autotools), or/and to make sure that kmplayer can be build with only one backend.
Anyhow I never expected a packager "dumb" to the level that he should pass a build option without the appropriate backend engine.

Regarding those options we may turn this the other away around since we already have the "HAVE_XINE" and "HAVE_GSTREAMER" definitions in the source code, meaning we keep the "with" options. This is speculation at this point since I can't test right now, I'll be back to you, on this, next week.

@SlavekB I have no ideas what the protocole desktop files play, so I included them in hope that you can shed some light upon. The gstreamer1/0.10 test like in "juk" is nice addition. Time has passed and I don't remember why I added the "with" and "build" options on the xine and gstreamer backend engines but It was either to mimic as much I could the configure options (since I don't want to deal with the autotools), or/and to make sure that kmplayer can be build with only one backend. Anyhow I never expected a packager "dumb" to the level that he should pass a build option without the appropriate backend engine. Regarding those options we may turn this the other away around since we already have the "HAVE_XINE" and "HAVE_GSTREAMER" definitions in the source code, meaning we keep the "with" options. This is speculation at this point since I can't test right now, I'll be back to you, on this, next week.
Owner

Greg, I did another test and comparison of CMake × Automake and I found that D-Bus and NSPR are required, but only because of KNPPlayer. Therefore, I removed the WITH_NSPR option and checks for D-Bus and NSPR I moved into the condition BUILD_KNPPLAYER.

Greg, I did another test and comparison of CMake × Automake and I found that D-Bus and NSPR are required, but only because of KNPPlayer. Therefore, I removed the `WITH_NSPR` option and checks for D-Bus and NSPR I moved into the condition `BUILD_KNPPLAYER`.
Owner

I test on Debian Bullseye and I get FTBFS during the CMake configuration:

-- Looking for C++ include KoDocument.h
-- Looking for C++ include KoDocument.h - not found
CMake Error at cmake/modules/TDEMacros.cmake:24 (message):
  #################################################

   KOffice plugin is requested but KOffice headers were not found on your system.

  #################################################
Building CXX object CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o
/usr/bin/g++   -I/usr/include/tqt3 -I/usr/include/tqt -I/opt/trinity/include -I/opt/trinity/inc
lude/tde  -g -O2 -fdebug-prefix-map=/root/kmplayer-trinity-14.0.8~pre2=. -fstack-protector-stro
ng -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fvisibility=hidden -fvisib
ility-inlines-hidden -ltqt -ltqt-mt   -o CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o -c "/
root/kmplayer-trinity-14.0.8~pre2/obj-x86_64-linux-gnu/CMakeFiles/CMakeTmp/CheckIncludeFile.cxx"
Linking CXX executable cmTC_6ed75
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_6ed75.dir/link.txt --verbose=1
/usr/bin/g++  -g -O2 -fdebug-prefix-map=/root/kmplayer-trinity-14.0.8~pre2=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fvisibility=hidden -fvisibility-inlines-hidden -ltqt -ltqt-mt    -rdynamic CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o  -o cmTC_6ed75
/usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTI7TQGList[_ZTI7TQGList]+0x10): undefined reference to `typeinfo for TQPtrCollection'
/usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTV7TQGList[_ZTV7TQGList]+0x18): undefined reference to `TQGList::clear()'
/usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTV7TQGList[_ZTV7TQGList]+0x30): undefined reference to `TQPtrCollection::newItem(void*)'
/usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTV7TQGList[_ZTV7TQGList]+0x40): undefined reference to `TQGList::compareItems(void*, void*)'
/usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTV7TQGList[_ZTV7TQGList]+0x48): undefined reference to `TQGList::read(TQDataStream&, void*&)'
/usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTV7TQGList[_ZTV7TQGList]+0x50): undefined reference to `TQGList::write(TQDataStream&, void*) const'
collect2: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/cmTC_6ed75.dir/build.make:87: cmTC_6ed75] Error 1

I did a test on Wheezy and Stretch and everything's fine there. There seems to be a need for further efforts.

I test on Debian Bullseye and I get FTBFS during the CMake configuration: ``` -- Looking for C++ include KoDocument.h -- Looking for C++ include KoDocument.h - not found CMake Error at cmake/modules/TDEMacros.cmake:24 (message): ################################################# KOffice plugin is requested but KOffice headers were not found on your system. ################################################# ``` ``` Building CXX object CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o /usr/bin/g++ -I/usr/include/tqt3 -I/usr/include/tqt -I/opt/trinity/include -I/opt/trinity/inc lude/tde -g -O2 -fdebug-prefix-map=/root/kmplayer-trinity-14.0.8~pre2=. -fstack-protector-stro ng -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fvisibility=hidden -fvisib ility-inlines-hidden -ltqt -ltqt-mt -o CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o -c "/ root/kmplayer-trinity-14.0.8~pre2/obj-x86_64-linux-gnu/CMakeFiles/CMakeTmp/CheckIncludeFile.cxx" Linking CXX executable cmTC_6ed75 /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_6ed75.dir/link.txt --verbose=1 /usr/bin/g++ -g -O2 -fdebug-prefix-map=/root/kmplayer-trinity-14.0.8~pre2=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fvisibility=hidden -fvisibility-inlines-hidden -ltqt -ltqt-mt -rdynamic CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o -o cmTC_6ed75 /usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTI7TQGList[_ZTI7TQGList]+0x10): undefined reference to `typeinfo for TQPtrCollection' /usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTV7TQGList[_ZTV7TQGList]+0x18): undefined reference to `TQGList::clear()' /usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTV7TQGList[_ZTV7TQGList]+0x30): undefined reference to `TQPtrCollection::newItem(void*)' /usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTV7TQGList[_ZTV7TQGList]+0x40): undefined reference to `TQGList::compareItems(void*, void*)' /usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTV7TQGList[_ZTV7TQGList]+0x48): undefined reference to `TQGList::read(TQDataStream&, void*&)' /usr/bin/ld: CMakeFiles/cmTC_6ed75.dir/CheckIncludeFile.cxx.o:(.data.rel.ro._ZTV7TQGList[_ZTV7TQGList]+0x50): undefined reference to `TQGList::write(TQDataStream&, void*) const' collect2: error: ld returned 1 exit status make[2]: *** [CMakeFiles/cmTC_6ed75.dir/build.make:87: cmTC_6ed75] Error 1 ``` I did a test on Wheezy and Stretch and everything's fine there. There seems to be a need for further efforts.
Owner

Changing from a complex check_include_file_cxx to a simple find_path resolved the KOffice detection problem.

Changing from a complex `check_include_file_cxx` to a simple `find_path` resolved the KOffice detection problem.
SlavekB removed the PR/rfc label 4 years ago
SlavekB closed this pull request 4 years ago
SlavekB deleted branch feat/cmakeConv 4 years ago
SlavekB added this to the R14.0.8 release milestone 4 years ago
Owner

@cethyel good work, good cooperation, thank you!

@cethyel good work, good cooperation, thank you!
The pull request has been manually merged as 1144a3b3e7.
Sign in to join this conversation.
No reviewers
No Milestone
No Assignees
2 Participants
Notifications
Due Date

No due date set.

Blocks
Reference: TDE/kmplayer#3
Loading…
There is no content yet.