[SOLVED] Compile from source

2 replies [Last post]
Gekoncze
User offline. Last seen 12 years 14 weeks ago. Offline
Joined: 2011-08-13
Posts: 6

Hi,
I have problems installing hedgewars 0.9.16 on Linux mint 9. I tried installing it with playdeb (because LM is based on Ubuntu), but when I click install it prints some error:
The repository may no longer be available or could not be contacted because of network problems. If available an older version of the failed index will be used. Otherwise the repository will be ignored. Check your network connection and ensure the repository address in the preferences is correct.
And then it installs old version, which is in repository...
So I tried compiling it from source code, but when I type "cmake ." into terminal, it fails:
cmake .
-- The C compiler identification is GNU
-- The CXX compiler identification is GNU
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Building Release
-- Looking for include files CMAKE_HAVE_PTHREAD_H
-- Looking for include files CMAKE_HAVE_PTHREAD_H - found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Enabling enhanced SDL_Image calls
-- Freepascal version installed: 2.4
-- Looking for Q_WS_X11
-- Looking for Q_WS_X11 - 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 Qt-Version 4.6.2 (using /usr/bin/qmake)
-- Looking for _POSIX_TIMERS
-- Looking for _POSIX_TIMERS - found
-- Looking for /usr/lib/libQtCore.so in optimized
CMake Error at CMakeLists.txt:10 (TARGET_LINK_LIBRARIES):
The "optimized" argument must be followed by a library.

CMake Error: Internal CMake error, TryCompile configure of cmake failed
-- Configuring incomplete, errors occurred!

but I installed all dependences. What is wrong? It prints error just after the libqtcore.so - it is in /usr/lib I also searched FAQ and there is something about qt:
tell cmake a path to Qt manually:

$ export QTDIR=qt dir
or
$ cmake -DQT_QMAKE_EXECUTABLE=path to qmake

tried both but no luck, I also don't know if I typed it in the right place - I typed this in terminal in hw directory:
$ export QTDIR=/usr/share/qt4
$ cmake -DOT_QMAKE_EXECUTABLE=/usr/bin/qmake

but the 2nd one prints the same long error as cmake .

...what should I do?

nemo
nemo's picture
User offline. Last seen 1 week 6 days ago. Offline
Joined: 2009-01-28
Posts: 1861

https://bugs.launchpad.net/getdeb.net/+bug/852629/comments/3

But, that error doesn't sound to me like a mint v ubuntu thing...
You really should doublecheck your repository link.
Perhaps try manually installing the package.

My overall guess is you used the installer package, which tried to identify your Ubuntu version incorrectly, since you are on Mint.
You probably need to specify in the apt line an ubuntu version that roughly corresponds to your Mint version. Such as... natty.
See:
http://hedgewars.org/node/3306#comment-21616

--
Oh, what the heck. 1PLXzL1CBUD1kdEWqMrwNUfGrGiirV1WpH <= tip a hedgewars dev

Gekoncze
User offline. Last seen 12 years 14 weeks ago. Offline
Joined: 2011-08-13
Posts: 6

I checked the sources list and there were 3 sources for getdeb -> 2 for ubuntu lynx (version that is LM 9 based on)and 1 for LM Isadora (9 - my version). Those for ubuntu were unchecked and the one for LM was checked so I unchecked the LM and checked ubuntu and now it can see the newest version Big Grin and it works. thx

User login

Copyright © 2004-2024 Hedgewars Project. All rights reserved. [ contact ]