Zoxcore / qTox_enhanced

qTox is a chat, voice, video, and file transfer IM client using the encrypted peer-to-peer Tox protocol.
GNU General Public License v3.0
49 stars 5 forks source link

Build errors in toxcoreerrorparser.cpp on Open Build Service #26

Open akontsevich opened 1 day ago

akontsevich commented 1 day ago

Have some errors during latest qTox_enhanced-1.17.6.028.tar.gz version building:

[   31s] In file included from /home/abuild/rpmbuild/BUILD/qTox_enhanced-1.17.6.028/util/src/toxcoreerrorparser.cpp:20:
[   31s] /home/abuild/rpmbuild/BUILD/qTox_enhanced-1.17.6.028/util/include/util/toxcoreerrorparser.h:63:19: error: ‘bool ToxcoreErrorParser::parseErr’ redeclared as different kind of entity
[   31s]    63 |     bool parseErr(Tox_Err_Group_State_Queries error, int line);
[   31s]       |                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~
[   31s] /home/abuild/rpmbuild/BUILD/qTox_enhanced-1.17.6.028/util/include/util/toxcoreerrorparser.h:61:10: note: previous declaration ‘bool ToxcoreErrorParser::parseErr(Tox_Err_Options_New, int)’
[   31s]    61 |     bool parseErr(Tox_Err_Options_New error, int line);
[   31s]       |          ^~~~~~~~
[   31s] [ 17%] Building C object webrtc6/CMakeFiles/webrtc6.dir/webrtc/modules/audio_processing/ns/nsx_core_c.c.o
[   31s] /home/abuild/rpmbuild/BUILD/qTox_enhanced-1.17.6.028/util/include/util/toxcoreerrorparser.h:63:19: error: ‘Tox_Err_Group_State_Queries’ was not declared in this scope; did you mean ‘Tox_Err_Group_State_Query’?
[   31s]    63 |     bool parseErr(Tox_Err_Group_State_Queries error, int line);
[   31s]       |                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~
[   31s]       |                   Tox_Err_Group_State_Query
[   31s] /home/abuild/rpmbuild/BUILD/qTox_enhanced-1.17.6.028/util/include/util/toxcoreerrorparser.h:63:54: error: expected primary-expression before ‘int’
[   31s]    63 |     bool parseErr(Tox_Err_Group_State_Queries error, int line);
[   31s]       |                                                      ^~~
[   31s] /home/abuild/rpmbuild/BUILD/qTox_enhanced-1.17.6.028/util/src/toxcoreerrorparser.cpp:647:35: error: ‘bool ToxcoreErrorParser::parseErr’ redeclared as different kind of entity
[   31s]   647 | bool ToxcoreErrorParser::parseErr(Tox_Err_Group_State_Queries error, int line)
[   31s]       |                                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~
[   31s] /home/abuild/rpmbuild/BUILD/qTox_enhanced-1.17.6.028/util/include/util/toxcoreerrorparser.h:66:10: note: previous declaration ‘bool ToxcoreErrorParser::parseErr(Tox_Err_Group_Send_Message, int)’
[   31s]    66 |     bool parseErr(Tox_Err_Group_Send_Message error, int line);
[   31s]       |          ^~~~~~~~
[   31s] /home/abuild/rpmbuild/BUILD/qTox_enhanced-1.17.6.028/util/src/toxcoreerrorparser.cpp:647:35: error: ‘Tox_Err_Group_State_Queries’ was not declared in this scope; did you mean ‘Tox_Err_Group_State_Query’?
[   31s]   647 | bool ToxcoreErrorParser::parseErr(Tox_Err_Group_State_Queries error, int line)
[   31s]       |                                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~
[   31s]       |                                   Tox_Err_Group_State_Query
[   31s] /home/abuild/rpmbuild/BUILD/qTox_enhanced-1.17.6.028/util/src/toxcoreerrorparser.cpp:647:70: error: expected primary-expression before ‘int’
[   31s]   647 | bool ToxcoreErrorParser::parseErr(Tox_Err_Group_State_Queries error, int line)
[   31s]       |                                                                      ^~~
[   31s] [ 17%] Linking CXX static library libwebrtc6.a
[   31s] make[2]: *** [util/CMakeFiles/util_library.dir/build.make:113: util/CMakeFiles/util_library.dir/src/toxcoreerrorparser.cpp.o] Error 1
[   31s] make[1]: *** [CMakeFiles/Makefile2:1966: util/CMakeFiles/util_library.dir/all] Error 2
[   31s] make[1]: *** Waiting for unfinished jobs....
[   31s] [ 17%] Built target webrtc6
[   31s] [ 18%] Building CXX object translations/CMakeFiles/translations_library.dir/translations_library_autogen/mocs_compilation.cpp.o
[   31s] [ 18%] Building CXX object translations/CMakeFiles/translations_library.dir/translations_library_autogen/EJRQKI7XPS/qrc_translations.cpp.o
[   33s] [ 18%] Linking CXX static library libtranslations_library.a
[   33s] [ 28%] Built target translations_library
[   33s] make: *** [Makefile:146: all] Error 2
[   34s] error: Bad exit status from /var/tmp/rpm-tmp.RL9LhG (%build)
[   34s] 
[   34s] RPM build warnings:
[   34s]     Macro expanded in comment on line 28: %{version}.tar.gz
[   34s] 
[   34s] 
[   34s] RPM build errors:
[   34s]     Bad exit status from /var/tmp/rpm-tmp.RL9LhG (%build)
[   34s] ### VM INTERACTION START ###
[   34s] Powering off.

Any ideas? Any dependency missed? Thanks!

Full build log attached:

_log.txt

Spec attached as well:

qtox_enhanced.spec.txt

zoff99 commented 1 day ago

how did you build it? what OS? what commands used to build? use these docker scripts to build: https://github.com/Zoxcore/qTox_enhanced/tree/zoxcore/push_notification/.localrun

akontsevich commented 1 day ago

how did you build it?

According to these instructions: https://github.com/qTox/qTox/blob/master/INSTALL.md#compile-extensions

what OS?

openSUSE Tumbleweed

what commands used to build?

They are all mentioned in the attached rpm spec and build log in my first above comment. In particular:

%build
tar -xvzf %{SOURCE1}
tar -xvzf %{SOURCE2}

# qTox uses the toxext library and some of the extensions that go with it.
# https://github.com/qTox/qTox/blob/master/INSTALL.md#compile-extensions
CFLAGS="%{optflags} -Wno-error=parentheses"

pushd toxext-0.0.3
mkdir build
pushd build
# Note: See buildscirpts/download/download_toxext.sh for which version should be checked out
cmake -DCMAKE_C_FLAGS="$CFLAGS" -DCMAKE_INSTALL_PREFIX=%{_prefix} ..
make -j$(nproc) PREFIX=%{_prefix}
make install PREFIX=%{_prefix} DESTDIR=%{buildroot}
popd
popd

export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:%{buildroot}%{_prefix}/lib/cmake/ToxExt"

pushd tox_extension_messages-0.0.3
# Note: See buildscirpts/download/download_toxext_messages.sh for which version should be checked out
mkdir build
pushd build
cmake -DCMAKE_C_FLAGS="$CFLAGS" -DCMAKE_INSTALL_PREFIX=%{_prefix} \
      -DToxExt_DIR="%{buildroot}%{_prefix}/lib/cmake/ToxExt" .. 
make -j$(nproc) PREFIX=%{_prefix}
make install PREFIX=%{_prefix} DESTDIR=%{buildroot}
popd
popd

export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:%{buildroot}%{_prefix}/lib/cmake/ToxExtensionMessages"

mkdir build
pushd build
cmake -DCMAKE_C_FLAGS="$CFLAGS" -DCMAKE_INSTALL_PREFIX=%{_prefix} \
      -DUPDATE_CHECK=False -DDESKTOP_NOTIFICATIONS=True \
      -DToxExt_DIR="%{buildroot}%{_prefix}/lib/cmake/ToxExt" \
      -DToxExtensionMessages_DIR="%{buildroot}%{_prefix}/lib/cmake/ToxExtensionMessages" \
      .. 
make %{?_smp_mflags} PREFIX=%{_prefix}
popd

use these docker scripts to build: https://github.com/Zoxcore/qTox_enhanced/tree/zoxcore/push_notification/.localrun

Could You specify exact chain please: it runs Dockerfile where it builds toxext and toxext_messages then goes to /qtox workdir. What are the next steps?