problem with alsa

Trying to build your own version of Vega Strike and having problems? Unix users, paste your config.log here (stderr output alone is not helpful).
Post Reply
lee
Confed Special Operative
Confed Special Operative
Posts: 322
Joined: Sat Aug 21, 2004 2:17 pm

problem with alsa

Post by lee »

Code: Select all

make[1]: Entering directory `/home/lee/Games/vs/vegastrike'
depbase=`echo src/aldrv/al_sound.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
	g++ -DHAVE_CONFIG_H -I.   -DBOOST_PYTHON_NO_PY_SIGNATURES -DBOOST_PYTHON_STATIC_LIB -I./boost/1_35   -DHAVE_SDL=1 -DSDL_WINDOWING=1      -I/usr/local/include  -I/usr/include/python2.5 -DHAVE_PYTHON=1    -I./src   -pipe  -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT -pthread -MT src/aldrv/al_sound.o -MD -MP -MF $depbase.Tpo -c -o src/aldrv/al_sound.o src/aldrv/al_sound.cpp &&\
	mv -f $depbase.Tpo $depbase.Po
src/aldrv/al_sound.cpp: In function ‘bool AUDLoadSoundFile(const char*, AUDSoundProperties*, bool)’:
src/aldrv/al_sound.cpp:448: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:466: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:467: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:479: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:480: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:481: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:483: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:494: error: ‘ConvertFormat’ was not declared in this scope
src/aldrv/al_sound.cpp:505: error: ‘ALbyte’ was not declared in this scope
src/aldrv/al_sound.cpp:505: error: expected primary-expression before ‘)’ token
src/aldrv/al_sound.cpp:505: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:505: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:505: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:505: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:505: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:505: error: ‘blutLoadWAVMemory’ was not declared in this scope
src/aldrv/al_sound.cpp:507: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:510: error: invalid use of incomplete type ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘struct AUDSoundProperties’
src/aldrv/al_sound.cpp: In function ‘int AUDBufferSound(const AUDSoundProperties*, bool)’:
src/aldrv/al_sound.cpp:515: error: ‘ALuint’ was not declared in this scope
src/aldrv/al_sound.cpp:515: error: expected `;' before ‘wavbuf’
src/aldrv/al_sound.cpp:516: error: ‘wavbuf’ was not declared in this scope
src/aldrv/al_sound.cpp:516: error: ‘alGenBuffers’ was not declared in this scope
src/aldrv/al_sound.cpp:517: error: ‘alGetError’ was not declared in this scope
src/aldrv/al_sound.cpp:518: error: invalid use of incomplete type ‘const struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘const struct AUDSoundProperties’
src/aldrv/al_sound.cpp:518: error: invalid use of incomplete type ‘const struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘const struct AUDSoundProperties’
src/aldrv/al_sound.cpp:518: error: invalid use of incomplete type ‘const struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘const struct AUDSoundProperties’
src/aldrv/al_sound.cpp:518: error: invalid use of incomplete type ‘const struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘const struct AUDSoundProperties’
src/aldrv/al_sound.cpp:518: error: ‘alBufferData’ was not declared in this scope
src/aldrv/al_sound.cpp:519: error: invalid use of incomplete type ‘const struct AUDSoundProperties’
src/aldrv/al_sound.cpp:447: error: forward declaration of ‘const struct AUDSoundProperties’
src/aldrv/al_sound.cpp:519: error: ‘LoadSound’ was not declared in this scope
src/aldrv/al_sound.cpp: In function ‘float AUDGetCurrentPosition(int)’:
src/aldrv/al_sound.cpp:908: error: ‘ALfloat’ was not declared in this scope
src/aldrv/al_sound.cpp:908: error: expected `;' before ‘rv’
src/aldrv/al_sound.cpp:909: error: ‘rv’ was not declared in this scope
src/aldrv/al_sound.cpp:909: error: ‘alGetSourcef’ was not declared in this scope
make[1]: *** [src/aldrv/al_sound.o] Error 1
make[1]: Leaving directory `/home/lee/Games/vs/vegastrike'
make: *** [all] Error 2
lee@cat:~/Games/vs/vegastrike$ 

Do I need another version of alsa? libasound2-dev is version 1.0.16-2.
Debian testing
NVIDIA-Linux-x86-173.08-pkg1.run
loki1950
The Shepherd
Posts: 5841
Joined: Fri May 13, 2005 8:37 pm
Location: Ottawa
Contact:

Post by loki1950 »

Do you have the dev package for that lib if not tiring to compile with out it will just not work you need the dev pgks for every lib that VS is built against not just the lib's themselves.

Enjoy the Choice :)
my box::HP Envy i5-6400 @2Q70GHzx4 8 Gb ram/1 Tb(Win10 64)/3 Tb Mint 19.2/GTX745 4Gb acer S243HL K222HQL
Q8200/Asus P5QDLX/8 Gb ram/WD 2Tb 2-500 G HD/GF GT640 2Gb Mint 17.3 64 bit Win 10 32 bit acer and Lenovo ideapad 320-15ARB Win 10/Mint 19.2
lee
Confed Special Operative
Confed Special Operative
Posts: 322
Joined: Sat Aug 21, 2004 2:17 pm

Post by lee »

Wow, that was fast :)

Using the search feature, I found the solution here: http://vegastrike.sourceforge.net/forum ... properties.

What was missing was libopenal-dev. It's compiled now --- and it works :)


Do you know where the autopilot is coded?
Debian testing
NVIDIA-Linux-x86-173.08-pkg1.run
ace123
Lead Network Developer
Lead Network Developer
Posts: 2560
Joined: Sun Jan 12, 2003 9:13 am
Location: Palo Alto CA
Contact:

Post by ace123 »

I believe SPEC code is in src/cmd/unit_generic.cpp (search for 'InWarp' or 'WarpMultiplier' I think are a few of the variables).

As for ASAP and Autopilot code, I think it probably all shares AI code with things like Flying to a target.

Look in the src/cmd/ai folder for a lot of the AI scripts. "flykeyboard.cpp" probably has the code that turns on the ASAP/Autopilot, and you might be able to follow it from there
lee
Confed Special Operative
Confed Special Operative
Posts: 322
Joined: Sat Aug 21, 2004 2:17 pm

Post by lee »

Hmm, I found it in src/cmd/ai/navigation.cpp. I can get it not to go faster than the set speed, but I can't get it to go faster than max afterburner speed. I also can get it not to turn off too early.

There must be a speed cap somewhere that becomes active once you turn on the autopilot. Any idea where that might be?


What I'm trying to get is an autopilot that goes by the speed set by the player and doesn't turn off by itself, at least not unless the "significant distance" from the target is <= 0.

The idea is to be able to travel faster on longer trips, like when going through some jump points, while still being able to go slow to safely approach a target, like a mining base I want to dock at at the end of the trip. --- All I'd have to do is set reasonable speeds for that while flying, like a better autopilot would do by itself.

So far, it works pretty well because SPEC is directional and thus can be used to a good extend against overshooting. The only thing that's missing is having the autopilot go faster than max_ab_speed.
As for ASAP and Autopilot code, I think it probably all shares AI code with things like Flying to a target.
Gah, I was afraid of that. If NPCs use it, I'll probably break it for them :( They might approach a station on autopilot but only "wake up" shortly before they crash into it and find themselves unable to prevent the crash because their programming doesn't tell them how to do that or how to use the modified autopilot.

This might be much easier if there were more comments in the source ... This way, I'm only messing with it without getting anywhere.

How could I find out what the NPCs are doing? Hanging around a station waiting for an NPC to come around and try to dock is probably not a good way, though it might be fun to watch it crash ;)
Debian testing
NVIDIA-Linux-x86-173.08-pkg1.run
loki1950
The Shepherd
Posts: 5841
Joined: Fri May 13, 2005 8:37 pm
Location: Ottawa
Contact:

Post by loki1950 »

Actually the NPC will just go through the station the AI can not dock ATM so collisions with stations is turned off.that speed cap is hard coded if i remember as the max combat speed with overdrive and is not part of the auto-pilot code but for all ships all the time not just when if SPEC mode.

Enjoy the Choice :)
my box::HP Envy i5-6400 @2Q70GHzx4 8 Gb ram/1 Tb(Win10 64)/3 Tb Mint 19.2/GTX745 4Gb acer S243HL K222HQL
Q8200/Asus P5QDLX/8 Gb ram/WD 2Tb 2-500 G HD/GF GT640 2Gb Mint 17.3 64 bit Win 10 32 bit acer and Lenovo ideapad 320-15ARB Win 10/Mint 19.2
lee
Confed Special Operative
Confed Special Operative
Posts: 322
Joined: Sat Aug 21, 2004 2:17 pm

Post by lee »

loki1950 wrote:Actually the NPC will just go through the station the AI can not dock ATM so collisions with stations is turned off.
Ouch ... They'd run out of fuel after some time flying. What do they do all the time? They can't trade or anything ...
that speed cap is hard coded if i remember as the max combat speed with overdrive and is not part of the auto-pilot code but for all ships all the time not just when if SPEC mode.
Yeah, the autopilot uses max combat speed, too. It must be somewhere since I can go faster in travel mode, but the autopilot goes slower once turned on.
Debian testing
NVIDIA-Linux-x86-173.08-pkg1.run
Miramor
ISO Party Member
ISO Party Member
Posts: 410
Joined: Tue Jun 26, 2007 7:15 pm

Post by Miramor »

I'm getting this openal problem all the sudden, even though I have openal dev stuff installed (SVN 12377). What's going on?
ace123
Lead Network Developer
Lead Network Developer
Posts: 2560
Joined: Sun Jan 12, 2003 9:13 am
Location: Palo Alto CA
Contact:

Post by ace123 »

Are you using CMake or Autoconf build systems?

Can you attach your config.log, since it sounds like you are missing a #define

As to why missing OpenAL causes errors, that's a different problem altogether, one that should be fixed, but isn't really high priority since I have yet to find a computer that can use OpenGL but yet does not have OpenAL.
lee
Confed Special Operative
Confed Special Operative
Posts: 322
Joined: Sat Aug 21, 2004 2:17 pm

Post by lee »

Miramor wrote:I'm getting this openal problem all the sudden, even though I have openal dev stuff installed (SVN 12377). What's going on?
Maybe you updated some software and need to run configure again?

Do you have libopenal-dev installed?
Debian testing
NVIDIA-Linux-x86-173.08-pkg1.run
Miramor
ISO Party Member
ISO Party Member
Posts: 410
Joined: Tue Jun 26, 2007 7:15 pm

Post by Miramor »

Ah... Forgot to run ./configure again. Thanks.
Post Reply