Failed to install QtCore4 on Ubuntu 16.10, perl version 5.24.1

I am trying to install QtCore4on Ubuntu 16.10, perl version 5.24.1:

sudo apt-get install cmake
sudo apt-get install qt4-designer libqtgui4-perl
cpan -g QtCore4
bunzip2 Qt4-0.99.0.tar.bz2
tar xvf Qt4-0.99.0.tar
cd Qt4-0.99.0
perl Makefile.PL
make VERBOSE=1

Here makecomes out with an error message:

Building CXX object smokeqt/qtdbus/CMakeFiles/smokeqtdbus.dir/x_1.cpp.o

cd /home/hakon/Qt4-0.99.0/smokeqt/qtdbus
/usr/bin/c++   -DSMOKE_BUILDING -Dsmokeqtdbus_EXPORTS \
 -I/usr/include/qt4/QtDesigner \
 -I/usr/include/qt4/QtDeclarative \
 -I/usr/include/qt4/QtScriptTools \
 -I/usr/include/qt4/QtDBus \
 -I/usr/include/qt4/QtXml \
 -I/usr/include/qt4/QtSql \
 -I/usr/include/qt4/QtOpenGL \
 -I/usr/include/qt4/QtNetwork \
 -I/usr/include/qt4/QtXmlPatterns \
 -I/usr/include/qt4/QtHelp \
 -I/usr/include/qt4/QtUiTools \
 -I/usr/include/qt4/QtTest \
 -I/usr/include/qt4/QtScript \
 -I/usr/include/qt4/QtSvg \
 -I/usr/include/qt4/Qt3Support \
 -I/usr/include/qt4/QtGui \
 -I/usr/include/qt4/QtCore \
 -I/usr/share/qt4/mkspecs/default \
 -I/usr/include/qt4 \
 -I/home/hakon/Qt4-0.99.0/src \
 -I/home/hakon/Qt4-0.99.0/smokeqt \
 -I/home/hakon/Qt4-0.99.0/smokegen \
 -I/home/hakon/Qt4-0.99.0/smokeqt/qtdbus \
 -I/home/hakon/Qt4-0.99.0/smoke \
 -I/home/hakon/Qt4-0.99.0/smoke/qtdbus  \
 -O3 -DNDEBUG -fPIC   -o CMakeFiles/smokeqtdbus.dir/x_1.cpp.o \
 -c /home/hakon/Qt4-0.99.0/smokeqt/qtdbus/x_1.cpp

/home/hakon/Qt4-0.99.0/smokeqt/qtdbus/x_1.cpp:1594:7: error: deleted function ‘virtual __smokeqtdbus::x_QDBusConnectionInterface::~x_QDBusConnectionInterface()’
 class x_QDBusConnectionInterface : public QDBusConnectionInterface {
       ^~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/qt4/QtDBus/QtDBus:8:0,
                 from /home/hakon/Qt4-0.99.0/smokeqt/qtdbus/qtdbus_includes.h:2,
                 from /home/hakon/Qt4-0.99.0/smokeqt/qtdbus/x_1.cpp:2:
/usr/include/qt4/QtDBus/qdbusconnectioninterface.h:73:5: error: overriding non-deleted function ‘virtual QDBusConnectionInterface::~QDBusConnectionInterface()’
     ~QDBusConnectionInterface();
     ^
/home/hakon/Qt4-0.99.0/smokeqt/qtdbus/x_1.cpp:1594:7: note: ‘virtual __smokeqtdbus::x_QDBusConnectionInterface::~x_QDBusConnectionInterface()’ is implicitly deleted because the default definition would be ill-formed:
 class x_QDBusConnectionInterface : public QDBusConnectionInterface {
       ^~~~~~~~~~~~~~~~~~~~~~~~~~
/home/hakon/Qt4-0.99.0/smokeqt/qtdbus/x_1.cpp:1594:7: error: ‘virtual QDBusConnectionInterface::~QDBusConnectionInterface()’ is private within this context

These threads can be connected:

0
source share
1 answer

It seems that there was no destructor in the derived class x_QDBusConnectionInterface:

/home/hakon/Qt4-0.99.0/smokeqt/qtdbus/x_1.cpp:1594:7: note: 'virtual __smokeqtdbus:: x_QDBusConnectionInterface:: ~ x_QDBusConnectionInterface() , :

1595 /home/hakon/Qt4-0.99.0/smokeqt/qtdbus/x_1.cpp:

~x_QDBusConnectionInterface();

. , :

  • /home/hakon/Qt4-0.99.0/smokeqt/qtgui/x_3.cpp:4024

  • /home/hakon/Qt4-0.99.0/smokeqt/qtgui/x_13.cpp:3572

  • /home/hakon/Qt4-0.99.0/smokeqt/qthelp/x_1.cpp:873

, , :

/home/hakon/Qt4-0.99.0/qtcore/src/util.cpp: In function ‘void
XS_AUTOLOAD(CV*)’: /home/hakon/Qt4-0.99.0/qtcore/src/util.cpp:2234:59:
error: cannot convert ‘bool’ to ‘void*’ in initialization    
     static smokeperl_object nothis = { 0, 0, 0, false };
                                                       ^

smokeperl_object /home/hakon/Qt4-0.99.0/qtcore/src/smokeperl.h 9:

struct smokeperl_object {
    bool allocated;
    Smoke* smoke;
    int classId;
    void* ptr;
};

false at /home/hakon/Qt4-0.99.0/qtcore/src/util.cpp:2234 a 0 :

static smokeperl_object nothis = { 0, 0, 0, 0 };

, :

/usr/bin/c++  -fPIC -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong \
 -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O3 -DNDEBUG  \
 -shared -Wl,-soname,QtCore4.so -o ../../blib/arch/auto/QtCore4/QtCore4.so \
 CMakeFiles/perlqtcore4.dir/binding.cpp.o \
 CMakeFiles/perlqtcore4.dir/handlers.cpp.o \
 CMakeFiles/perlqtcore4.dir/marshall_types.cpp.o \
 CMakeFiles/perlqtcore4.dir/util.cpp.o \
 CMakeFiles/perlqtcore4.dir/QtCore4.c.o \
 -lQtCore -lQtGui -lQtNetwork \
 /home/hakon/perlbrew/perls/perl-5.24.1/lib/5.24.1/x86_64-linux/CORE/libperl.a \
 ../../smokeqt/qtgui/libsmokeqtgui.so.3.0.0 \
 ../../smokeqt/qtnetwork/libsmokeqtnetwork.so.3.0.0 \
 -lpthread -lnsl -ldl -lm -lcrypt -lutil -lc -lQtGui -lQtNetwork \
 ../../smokeqt/qtcore/libsmokeqtcore.so.3.0.0 -lQtCore \
 ../../smokegen/bin/libsmokebase.so.3.0.0 \
 -Wl,-rpath,/home/hakon/Qt4-0.99.0/smokeqt/qtgui:/home/hakon/Qt4-0.99.0/smokeqt/qtnetwork:/home/hakon/Qt4-0.99.0/smokeqt/qtcore:/home/hakon/Qt4-0.99.0/smokegen/bin: 

/usr/bin/ld: /home/hakon/perlbrew/perls/perl-5.24.1/lib/5.24.1/x86_64-linux/CORE/libperl.a(toke.o): 
  relocation R_X86_64_PC32 against symbol `PL_curcop' can not be used when making
  a shared object; recompile with -fPIC
/usr/bin/ld: final link failed: Bad value
collect2: error: ld returned 1 exit status

, .

0

Source: https://habr.com/ru/post/1673970/


All Articles