This topic contains 21 replies, has 0 voices, and was last updated by  Irishbandit 10 years, 5 months ago.

  • Author
    Posts
  • #5005

    LeeT
    Participant

    I am trying to install scorched 3d on linux. The type of linux I’m running is like slackware. When I try to do the command ./configure it comes out with an error at the bottom:

    checking for OpenAL compilation… *** Compiled but failed to link using the OpenAL library.
    *** LIBS = -L/usr/lib -Wl,-rpath,/usr/lib -lSDL -lpthread -lSDL_net -lGL -lGLU -lpthread -L/usr/local/lib -lopenal
    *** Check the OpenAL library is on the LD_LIBRARY_PATH
    configure: error: *** Check the OpenAL library is correctly installed.

    I know OpenAL is installed properly because I’ve reinstalled it twice and it is the newest version.

    What do you think is the problem?

    #35768

    cbx550f
    Participant

    First thing to try is to run “ldconfig” …

    Failing that, run:
    ./configure –disable-openaltest

    then:
    LIBS=”-lalut” make

    This is acommon problem with OpenAL (I have the same problem). Usually, it stems from having more than one openal install at the same time (for me, anyway).

    cbx

    #35769

    LeeT
    Participant

    Thanks for the help, but at the end of the make I was met by another error.

    collect2: ld returned 1 exit status
    make[2]: *** [scorched3d] Error 1
    make[2]: Leaving directory `/root/Desktop/scorched/src/scorched’
    make[1]: *** [install-recursive] Error 1
    make[1]: Leaving directory `/root/Desktop/scorched/src’
    make: *** [install-recursive] Error 1

    #35770

    DeVice
    Participant

    @leet wrote:

    Thanks for the help, but at the end of the make I was met by another error.

    collect2: ld returned 1 exit status
    make[2]: *** [scorched3d] Error 1
    make[2]: Leaving directory `/root/Desktop/scorched/src/scorched’
    make[1]: *** [install-recursive] Error 1
    make[1]: Leaving directory `/root/Desktop/scorched/src’
    make: *** [install-recursive] Error 1

    Mmm, the actual error that we need to read to help you is above those lines.

    #35771

    LeeT
    Participant

    Ok, sorry about that.
    I believe this is what you need:

    /usr/lib/gcc-lib/i486-slackware-linux/3.3.5/../../../../i486-slackware-linux/bin/ld: warning: libstdc++.so.6, needed by /usr/X11R6/lib/libGLU.so, may conflict with libstdc++.so.5
    SoundBufferStaticWav.o(.text+0x1e0): In function `SoundBufferStaticWav::SoundBufferStaticWav[not-in-charge](char const*)’:
    ../sound/SoundBufferStaticWav.cpp:80: undefined reference to `alutLoadWAVFile’
    SoundBufferStaticWav.o(.text+0x229):../sound/SoundBufferStaticWav.cpp:96: undefined reference to `alutUnloadWAV’
    SoundBufferStaticWav.o(.text+0x2c0): In function `SoundBufferStaticWav::SoundBufferStaticWav[in-charge](char const*)’:
    ../sound/SoundBufferStaticWav.cpp:80: undefined reference to `alutLoadWAVFile’
    SoundBufferStaticWav.o(.text+0x309):../sound/SoundBufferStaticWav.cpp:96: undefined reference to `alutUnloadWAV’
    collect2: ld returned 1 exit status
    make[2]: *** [scorched3d] Error 1
    make[2]: Leaving directory `/root/Desktop/scorched/src/scorched’
    make[1]: *** [install-recursive] Error 1
    make[1]: Leaving directory `/root/Desktop/scorched/src’
    make: *** [install-recursive] Error 1

    #35772

    DeVice
    Participant

    Strange, the cbx commands should have done it.

    Do you have a “freealut-config” command on your system ?

    If so show us what “freealut-config –version” says, and try to replace the make command by “LIBS=`freealut-config –libs` make”.

    #35773

    cbx550f
    Participant

    Please also post the output from “openal-config –libs” and “freealut-config –libs”

    cbx

    #35774

    LeeT
    Participant

    freealut-config –version:
    1.1.0

    when i try to replace make with LIBS=`freealut-config –libs` make it comes out with the same error.

    openal-config –libs:
    -L/usr/local/lib -lopenal

    freealut-config –libs:
    -L/usr/local/lib -lalut

    #35775

    DeVice
    Participant

    Mmmm that perhaps means the LIBS env is wiped by make before use.

    Try to apply the following patch, then redo all including the configure step.


    --- configure.ac.orig Tue Oct 31 17:42:00 2006
    +++ configure.ac Tue Oct 31 17:54:47 2006
    @@ -133,6 +133,12 @@
    echo "*** environment variable to the full path to openal-config."
    else

    + if test x"$use_static_openal" = x"yes"; then
    + LIBS="$LIBS /usr/local/lib/libalut.a"
    + else
    + LIBS="$LIBS `$FREEALUT_CONFIG --libs`"
    + fi
    +
    CFLAGS="$CFLAGS `$FREEALUT_CONFIG --cflags`"
    CXXFLAGS="$CXXFLAGS `$FREEALUT_CONFIG --cflags`"

    In case you don’t know about applying patches :
    – Save the text above in a file called “configure.ac.patch”.
    – Go into your scorched3d sources top directory (where “configure.ac” is).
    – type command “patch -p0 < /path/to/the/file/configure.ac.patch”. (replacing of course the red part with the actual path you saved the patch file in).
    – watch the output, verifying it says that the patch apllied cleanly.

    PS anybody with scorched CVS commit rights, would be nice to include that patch in sources if not done yet.

    #35776

    LeeT
    Participant

    When I try to patch I get this error:

    patching file configure.ac
    Hunk #1 FAILED at 133.
    1 out of 1 hunk FAILED — saving rejects to file configure.ac.rej

    #35777

    DeVice
    Participant

    Ah yup dumb me, this patch was made to be apllied on a different file.

    Sorry.

    Your best move, as the patch is quite simple, would be to hand edit your “configure.ac” : all you need to do is add the lines that starts with a “+” (but without that leading “+”). You can figure where to add those by the surroundings lines (those whitout a leading “+”).

    #35778

    LeeT
    Participant

    I applied the patch, but then when I tried to do make I get this:

    /usr/lib/gcc-lib/i486-slackware-linux/3.3.5/../../../../i486-slackware-linux/bin/ld: warning: libstdc++.so.6, needed by /usr/X11R6/lib/libGLU.so, may conflict with libstdc++.so.5
    make[2]: Leaving directory `/root/Desktop/scorched/src/scorched’
    make[2]: Entering directory `/root/Desktop/scorched/src’
    make[2]: Nothing to be done for `all-am’.
    make[2]: Leaving directory `/root/Desktop/scorched/src’
    make[1]: Leaving directory `/root/Desktop/scorched/src’
    make[1]: Entering directory `/root/Desktop/scorched’
    make[1]: Nothing to be done for `all-am’.
    make[1]: Leaving directory `/root/Desktop/scorched’

    I’m not exactly sure how to fix that.

    #35779

    DeVice
    Participant

    It was just a warning I think. It looks look you successfully built scorched3d, congrats !

    You should be able to “make install” now 🙂

    #35780

    LeeT
    Participant

    Yes. Thanks for all the help. I also have one more question. I like to start my programs from command line, I forget how to add a program to start on a command. Or is there one already that I am missing?

    #35781

    Brain Damage
    Participant

    get the superuser privileges (root) by typing:
    su
    and enter your root password

    then use the command (inside scorched’s directory)
    make install

    then you can leave the superuser mode by typing
    exit

Viewing 15 posts - 1 through 15 (of 23 total)

You must be logged in to reply to this topic.