Reply to topic

Some problems when I cmake and make the application

vonte
Registered Member
Posts
6
Karma
0
Hi,everybody
I have tried to run the application on my 64-bit centOS6.5 OS.I download the code with git. And then I install the QT v4.8.4 and cmake. When I use cmake command .It reports some problem-all kinds of "not found".
-- Looking for Q_WS_WIN
-- Looking for Q_WS_WIN - not found
-- Looking for Q_WS_QWS
-- Looking for Q_WS_QWS - not found
-- Looking for Q_WS_MAC
-- Looking for Q_WS_MAC - not found
-- Found Qt4: /usr/local/Trolltech/Qt-4.8.4/bin/qmake (found version "4.8.4")
-- Found Phonon: /usr/include
-- Looking for cfmakeraw
-- Looking for cfmakeraw - found
-- Looking for include file sys/filio.h
-- Looking for include file sys/filio.h - not found
-- Could NOT find libshp (missing: LIBSHP_INCLUDE_DIR LIBSHP_LIBRARIES)
-- Could NOT find libgps (missing: LIBGPS_INCLUDE_DIR LIBGPS_LIBRARIES)
-- Not building with gpsd position provider
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.23")
-- checking for module 'liblocation>=0.102'
-- package 'liblocation>=0.102' not found
-- checking for module 'QtLocation>=1.0.1'
-- package 'QtLocation>=1.0.1' not found
-- Could NOT find QtMobility (missing: QTMOBILITY_INCLUDE_DIR)
-- Could NOT find QtLocation (missing: QTLOCATION_INCLUDE_DIR QTLOCATION_LIBRARIES)
-- Configuring done
-- Generating done
-- Build files have been written to: /home/zhangbo/workspace/marble/build

Anyway, building complete.
Then the make command :
[ 70%] Building CXX object src/plugins/render/routing/CMakeFiles/RoutingPlugin.dir/AudioOutput.o
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:18:30: error: phonon/MediaObject: No such file or directory
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:19:30: error: phonon/MediaSource: No such file or directory
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:20:30: error: phonon/AudioOutput: No such file or directory
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:30: error: ‘Phonon’ has not been declared
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:30: error: ISO C++ forbids declaration of ‘MediaObject’ with no type
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:30: error: expected ‘;’ before ‘*’ token
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp: In constructor ‘Marble::AudioOutputPrivate::AudioOutputPrivate(Marble::AudioOutput*)’:
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:48: error: class ‘Marble::AudioOutputPrivate’ does not have any field named ‘m_output’
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp: In member function ‘void Marble::AudioOutputPrivate::audioOutputFinished()’:
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:56: error: ‘m_output’ was not declared in this scope
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp: In member function ‘void Marble::AudioOutputPrivate::setupAudio()’:
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:62: error: ‘m_output’ was not declared in this scope
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:63: error: expected type-specifier before ‘Phonon’
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:63: error: expected ‘;’ before ‘Phonon’
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:64: error: ‘Phonon’ has not been declared
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:64: error: ‘audioOutput’ was not declared in this scope
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:64: error: expected type-specifier before ‘Phonon’
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:64: error: expected ‘;’ before ‘Phonon’
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:65: error: ‘Phonon’ has not been declared
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp: In member function ‘void Marble::AudioOutputPrivate::reset()’:
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:73: error: ‘m_output’ was not declared in this scope
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp: In member function ‘void Marble::AudioOutputPrivate::playInstructions()’:
/home/zhangbo/workspace/marble/sources/src/plugins/render/routing/AudioOutput.cpp:85: error: ‘m_output’ was not declared in this scope
make[2]: *** [src/plugins/render/routing/CMakeFiles/RoutingPlugin.dir/AudioOutput.o] Error 1
make[1]: *** [src/plugins/render/routing/CMakeFiles/RoutingPlugin.dir/all] Error 2
make: *** [all] Error 2

Is someone have a suggestion about these problems.
vonte
Registered Member
Posts
6
Karma
0
In the marble/sources/src/plugins/render/routing/CMakeLists.txt.How do I confirm whether the PHONON related environment paths have been set? Should I set them in the /etc/profile ?
Code: Select all
PROJECT(RoutingPlugin)

FIND_PACKAGE(Phonon)

INCLUDE_DIRECTORIES(
 ${CMAKE_CURRENT_SOURCE_DIR}/src/plugins/render/routing
 ${CMAKE_BINARY_DIR}/src/plugins/render/routing
 ${QT_INCLUDE_DIR}
 ${PHONON_INCLUDES}
)
INCLUDE(${QT_USE_FILE})

IF( PHONON_FOUND )
  set( routing_SRCS RoutingPlugin.cpp AudioOutput.cpp )
ELSE()
  set( routing_SRCS RoutingPlugin.cpp NullAudioOutput.cpp )
ENDIF()
set( routing_UI RoutingPlugin.ui RoutingConfigDialog.ui )
qt4_wrap_ui( routing_SRCS ${routing_UI} )
qt4_add_resources(routing_SRCS routing.qrc)

marble_add_plugin( RoutingPlugin ${routing_SRCS} )
target_link_libraries(RoutingPlugin ${PHONON_LIBS})
User avatar tackat
KDE Developer
Posts
67
Karma
0
OS
The variables used in the quoted code aren't environment variables. You need to install phonon dev- and library files so that the Find Phonon cmake script can find Phonon.
vonte
Registered Member
Posts
6
Karma
0
tackat wrote:The variables used in the quoted code aren't environment variables. You need to install phonon dev- and library files so that the Find Phonon cmake script can find Phonon.

Thanks for your reply. I'm new with linux.I find the MediaObject in the directory "/usr/include/phonon/Phonon".Is that what it needs?I excluded the files in the directory "/marble/sources/src/plugins/render/routing" and run the application.Is that ok if I won't do some develop concerning with the audio part.
User avatar bcooksley
Administrator
Posts
18607
Karma
83
OS
Please post the output of "ls /usr/include/phonon/"


System Settings and Device Actions KCM maintainer
Image
vonte
Registered Member
Posts
6
Karma
0
bcooksley wrote:Please post the output of "ls /usr/include/phonon/"

The output of "ls /usr/include/phonon/" is
Code: Select all
abstractaudiooutput.h   effectwidget.h            phonon_export.h
abstractmediastream.h   mediacontroller.h         phononnamespace.h
abstractvideooutput.h   medianode.h               platformplugin.h
addoninterface.h        mediaobject.h             seekslider.h
audiooutput.h           mediaobjectinterface.h    streaminterface.h
audiooutputinterface.h  mediasource.h             videoplayer.h
backendcapabilities.h   objectdescription.h       videowidget.h
backendinterface.h      objectdescriptionmodel.h  videowidgetinterface.h
effect.h                path.h                    volumefadereffect.h
effectinterface.h       Phonon                    volumefaderinterface.h
effectparameter.h       phonondefs.h              volumeslider.h

The output of "ls /usr/include/phonon/Phonon" is
Code: Select all
AbstractAudioOutput           Global
AbstractMediaStream           MediaController
AbstractVideoOutput           MediaNode
AddonInterface                MediaObject
AudioCaptureDevice            MediaObjectInterface
AudioCaptureDeviceModel       MediaSource
AudioChannelDescription       ObjectDescription
AudioChannelDescriptionModel  ObjectDescriptionData
AudioOutput                   ObjectDescriptionModel
AudioOutputDevice             ObjectDescriptionModelData
AudioOutputDeviceModel        Path
AudioOutputInterface          PlatformPlugin
AudioOutputInterface40        SeekSlider
AudioOutputInterface42        StreamInterface
BackendCapabilities           SubtitleDescription
BackendInterface              SubtitleDescriptionModel
Effect                        VideoPlayer
EffectDescription             VideoWidget
EffectDescriptionModel        VideoWidgetInterface
EffectInterface               VolumeFaderEffect
EffectParameter               VolumeFaderInterface
EffectWidget                  VolumeSlider
User avatar bcooksley
Administrator
Posts
18607
Karma
83
OS
Ah - the problem here is that you are using the Qt Phonon rather than the KDE Phonon, and therefore have run into the "Phonon/phonon" case-sensitivity issue.

As an interim measure, cd to /usr/include/phonon and run:
Code: Select all
ln -s phonon Phonon

You will need to run this as root - but it should solve the problem.


System Settings and Device Actions KCM maintainer
Image

 
Reply to topic

Bookmarks



Who is online

Registered users: Baidu [Spider], Bing [Bot], Dimitrios, Exabot [Bot], Google [Bot], hagabaka, Hans, koriun, La Ninje, Majestic-12 [Bot], mohali, msdobrescu, Steve Guilford, vascobasque, whatthefunk, Yahoo [Bot]