g ++ - 5.real: erro: opção de linha de comando não reconhecida ‘-pthread-lQtGui’

0

Eu configurei meu rcssmonitor e quando quero fazer o arquivo, ele recebe esse erro Alguém pode me ajudar com isso?

configure log:

./configure --with-boost-libdir=/usr/lib/x86_64-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking for cos in -lm... yes
checking for deflate in -lz... yes
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking for stdbool.h that conforms to C99... yes
checking for _Bool... yes
checking for inline... inline
checking for an ANSI C-conforming const... yes
checking for int16_t... yes
checking for int32_t... yes
checking for size_t... yes
checking whether time.h and sys/time.h may both be included... yes
checking for uint16_t... yes
checking for uint32_t... yes
checking for error_at_line... yes
checking for memset... yes
checking for rint... yes
checking for strtol... yes
checking for pow... yes
checking for sqrt... yes
checking for boostlib >= 1.32.0... yes
checking build system type... x86_64-unknown-linux-gnu
checking whether the Boost::System library is available... yes
checking for exit in -lboost_system... yes
checking whether the Boost::Program_Options library is available... yes
checking for exit in -lboost_program_options... yes
checking for pkg-config... /usr/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
configure: set QT4_REQUIRED_VERSION... 4.3.0
configure: set QT4_REQUIRED_MODULES... QtCore QtGui QtNetwork
checking for pkg-config... /usr/bin/pkg-config
configure: check QtCore >= 4.3.0
checking for Qt4... yes
configure: check QtGui >= 4.3.0
checking for Qt4... yes
configure: check QtNetwork >= 4.3.0
checking for Qt4... yes
configure: set QT4_CXXFLAGS... -DQT_SHARED -I/usr/include/qt4 -I/usr/include/qt4/QtGui -I/usr/include/qt4 -I/usr/include/qt4/QtNetwork -I/usr/include/qt4 -I/usr/include/qt4/QtCore
configure: set QT4_LDFLAGS... -L/usr/X11R6/lib64
configure: set QT4_LDADD... -pthread-lQtGui -lQtCore -lfontconfig -lpthread -laudio -lXt -lgthread-2.0 -lglib-2.0 -lpng -lz -lfreetype -lgobject-2.0 -lglib-2.0 -lSM -lICE -lXi -lXrender -lfontconfig -lfreetype -lXext -lX11 -lm -lQtNetwork -lQtCore -lfontconfig -lpthread -lz -lQtCore -lfontconfig -lpthread -lz -lm -ldl -lgthread-2.0 -lglib-2.0 -lrt
configure: set QT4_MOC... /usr/share/qt4/bin/moc
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating config.h
config.status: executing depfiles commands

cometer erros:

g++-5.real: error: unrecognized command line option ‘-pthread-lQtGui’
Makefile:357: recipe for target 'rcssmonitor' failed
make[2]: *** [rcssmonitor] Error 1
make[2]: Leaving directory '/home/seena/Robocup/rcssmonitor-15.1.1/src'
Makefile:289: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/seena/Robocup/rcssmonitor-15.1.1'
Makefile:229: recipe for target 'all' failed
make: *** [all] Error 2

Estou executando o Ubuntu 16 Alguém por favor pode me ajudar a resolver o meu problema?

    
por Seena Fallah 10.08.2016 / 23:33

2 respostas

2

Você precisa separar as bandeiras -pthread e -lQtGui . Consegui resolver isso usando sed para descobrir onde os sinalizadores estavam juntos e separando depois de fazer o processo de configuração. Faça um make clean then ./configure e tente fazer isso:

sed -i 's/-pthread-lQtGui/-pthread -lQtGui/' config.status*
sed -i 's/-pthread-lQtGui/-pthread -lQtGui/' Makefile*

Depois disso, faça um sudo make install e veja se funciona ...

    
por Pedro Sol 06.10.2016 / 17:53
1

Abra o arquivo configure e localize esta linha:

QT4_LDADD="$($PKG_CONFIG --static --libs-only-other $QT4_REQUIRED_MODULES)$($PKG_CONFIG --static --libs-only-l $QT4_REQUIRED_MODULES)"

Coloque um espaço entre as variáveis $ PKG_CONFIG, então será assim:

QT4_LDADD="$($PKG_CONFIG --static --libs-only-other $QT4_REQUIRED_MODULES) $($PKG_CONFIG --static --libs-only-l $QT4_REQUIRED_MODULES)"
    
por herodrigues 13.03.2017 / 01:32