Allegro.cc - Online Community

Allegro.cc Forums » Installation, Setup & Configuration » Allegro install errors

Credits go to gnolam, Kitty Cat, and Matthew Leverton for helping out!
This thread is locked; no one can reply to it. rss feed Print
Allegro install errors
CursedTyrant
Member #7,080
April 2006
avatar

Finally, after a long time since I formatted my HDD, I'm trying to build allegro, and it doesn't seem to work. I downloaded Allegro 4.2.1 source and the dx70min it requires, and it still does not want to work.

I never had similar problems with allegro, it always compiled just fine.

1gcc -DALLEGRO_SRC -DALLEGRO_LIB_BUILD -Wall -Wno-unused -mtune=i586 -O2 -funroll
2-loops -ffast-math -fomit-frame-pointer -I. -I./include -o obj/mingw32/alleg/gd
3i.o -c src/win/gdi.c
4gcc -DALLEGRO_SRC -DALLEGRO_LIB_BUILD -Wall -Wno-unused -mtune=i586 -O2 -funroll
5-loops -ffast-math -fomit-frame-pointer -I. -I./include -o obj/mingw32/alleg/wd
6daccel.o -c src/win/wddaccel.c
7In file included from src/win/wddaccel.c:25:
8src/win/wddraw.h:33:22: ddraw.h: No such file or directory
9In file included from src/win/wddaccel.c:25:
10src/win/wddraw.h:43: error: syntax error before "LPDIRECTDRAWSURFACE2"
11src/win/wddraw.h:43: warning: no semicolon at end of struct or union
12src/win/wddraw.h:49: error: syntax error before '}' token
13src/win/wddraw.h:49: warning: type defaults to `int' in declaration of `DDRAW_SU
14RFACE'
15src/win/wddraw.h:49: warning: data definition has no type or storage class
16src/win/wddraw.h:63: error: syntax error before "directdraw"
17src/win/wddraw.h:63: warning: type defaults to `int' in declaration of `directdr
18aw'
19src/win/wddraw.h:63: warning: data definition has no type or storage class
20src/win/wddraw.h:64: error: syntax error before "ddclipper"
21src/win/wddraw.h:64: warning: type defaults to `int' in declaration of `ddclippe
22r'
23src/win/wddraw.h:64: warning: data definition has no type or storage class
24src/win/wddraw.h:65: error: syntax error before "ddpalette"
25src/win/wddraw.h:65: warning: type defaults to `int' in declaration of `ddpalett
26e'
27src/win/wddraw.h:65: warning: data definition has no type or storage class
28src/win/wddraw.h:66: error: syntax error before "ddpixel_format"
29src/win/wddraw.h:66: warning: type defaults to `int' in declaration of `ddpixel_
30format'
31src/win/wddraw.h:66: warning: data definition has no type or storage class
32src/win/wddraw.h:67: error: syntax error before "ddcaps"
33src/win/wddraw.h:67: warning: type defaults to `int' in declaration of `ddcaps'
34src/win/wddraw.h:67: warning: data definition has no type or storage class
35src/win/wddraw.h:69: error: syntax error before '*' token
36src/win/wddraw.h:69: warning: type defaults to `int' in declaration of `gfx_dire
37ctx_primary_surface'
38src/win/wddraw.h:69: warning: data definition has no type or storage class
39src/win/wddraw.h:98: error: syntax error before '*' token
40src/win/wddraw.h:115: error: syntax error before '*' token
41src/win/wddraw.h:134: error: syntax error before '*' token
42src/win/wddraw.h:134: error: syntax error before "LPDDPIXELFORMAT"
43src/win/wddraw.h:134: warning: type defaults to `int' in declaration of `gfx_dir
44ectx_create_surface'
45src/win/wddraw.h:134: warning: data definition has no type or storage class
46src/win/wddraw.h:135: error: syntax error before '*' token
47src/win/wddraw.h:136: error: syntax error before '*' token
48src/win/wddraw.h:140: error: syntax error before '*' token
49src/win/wddraw.h:141: error: syntax error before '*' token
50src/win/wddaccel.c: In function `ddraw_blit_to_self':
51src/win/wddaccel.c:72: warning: implicit declaration of function `IDirectDrawSur
52face2_BltFast'
53src/win/wddaccel.c:72: error: syntax error before ')' token
54src/win/wddaccel.c:73: error: syntax error before ')' token
55src/win/wddaccel.c:74: error: `DDBLTFAST_WAIT' undeclared (first use in this fun
56ction)
57src/win/wddaccel.c:74: error: (Each undeclared identifier is reported only once
58src/win/wddaccel.c:74: error: for each function it appears in.)
59src/win/wddaccel.c: In function `ddraw_masked_blit':
60src/win/wddaccel.c:94: error: `DDCOLORKEY' undeclared (first use in this functio
61n)
62src/win/wddaccel.c:94: error: syntax error before "src_key"
63src/win/wddaccel.c:109: error: `src_key' undeclared (first use in this function)
64 
65src/win/wddaccel.c:127: warning: implicit declaration of function `IDirectDrawSu
66rface2_SetColorKey'
67src/win/wddaccel.c:127: error: syntax error before ')' token
68src/win/wddaccel.c:128: error: `DDCKEY_SRCBLT' undeclared (first use in this fun
69ction)
70src/win/wddaccel.c:130: warning: implicit declaration of function `IDirectDrawSu
71rface2_Blt'
72src/win/wddaccel.c:130: error: syntax error before ')' token
73src/win/wddaccel.c:131: error: syntax error before ')' token
74src/win/wddaccel.c:132: error: `DDBLT_KEYSRC' undeclared (first use in this func
75tion)
76src/win/wddaccel.c:132: error: `DDBLT_WAIT' undeclared (first use in this functi
77on)
78src/win/wddaccel.c: In function `ddraw_do_stretch_blit':
79src/win/wddaccel.c:205: error: `DDCOLORKEY' undeclared (first use in this functi
80on)
81src/win/wddaccel.c:205: error: syntax error before "src_key"
82src/win/wddaccel.c:220: error: `src_key' undeclared (first use in this function)
83 
84src/win/wddaccel.c:240: error: syntax error before ')' token
85src/win/wddaccel.c:241: error: `DDCKEY_SRCBLT' undeclared (first use in this fun
86ction)
87src/win/wddaccel.c:243: error: syntax error before ')' token
88src/win/wddaccel.c:244: error: syntax error before ')' token
89src/win/wddaccel.c:245: error: `DDBLT_KEYSRC' undeclared (first use in this func
90tion)
91src/win/wddaccel.c:245: error: `DDBLT_WAIT' undeclared (first use in this functi
92on)
93src/win/wddaccel.c: In function `ddraw_clear_to_color':
94src/win/wddaccel.c:270: error: `DDBLTFX' undeclared (first use in this function)
95
96src/win/wddaccel.c:270: error: syntax error before "blt_fx"
97src/win/wddaccel.c:284: error: `blt_fx' undeclared (first use in this function)
98src/win/wddaccel.c:291: error: syntax error before ')' token
99src/win/wddaccel.c:292: error: `DDBLT_COLORFILL' undeclared (first use in this f
100unction)
101src/win/wddaccel.c:292: error: `DDBLT_WAIT' undeclared (first use in this functi
102on)
103src/win/wddaccel.c: In function `ddraw_rectfill':
104src/win/wddaccel.c:312: error: `DDBLTFX' undeclared (first use in this function)
105 
106src/win/wddaccel.c:312: error: syntax error before "blt_fx"
107src/win/wddaccel.c:363: error: `blt_fx' undeclared (first use in this function)
108src/win/wddaccel.c:370: error: syntax error before ')' token
109src/win/wddaccel.c:371: error: `DDBLT_COLORFILL' undeclared (first use in this f
110unction)
111src/win/wddaccel.c:371: error: `DDBLT_WAIT' undeclared (first use in this functi
112on)
113src/win/wddaccel.c: In function `ddraw_hline':
114src/win/wddaccel.c:391: error: `DDBLTFX' undeclared (first use in this function)
115
116src/win/wddaccel.c:391: error: syntax error before "blt_fx"
117src/win/wddaccel.c:430: error: `blt_fx' undeclared (first use in this function)
118src/win/wddaccel.c:437: error: syntax error before ')' token
119src/win/wddaccel.c:438: error: `DDBLT_COLORFILL' undeclared (first use in this f
120unction)
121src/win/wddaccel.c:438: error: `DDBLT_WAIT' undeclared (first use in this functi
122on)
123src/win/wddaccel.c: In function `ddraw_vline':
124src/win/wddaccel.c:457: error: `DDBLTFX' undeclared (first use in this function)
125 
126src/win/wddaccel.c:457: error: syntax error before "blt_fx"
127src/win/wddaccel.c:496: error: `blt_fx' undeclared (first use in this function)
128src/win/wddaccel.c:503: error: syntax error before ')' token
129src/win/wddaccel.c:504: error: `DDBLT_COLORFILL' undeclared (first use in this f
130unction)
131src/win/wddaccel.c:504: error: `DDBLT_WAIT' undeclared (first use in this functi
132on)
133src/win/wddaccel.c: In function `gfx_directx_enable_acceleration':
134src/win/wddaccel.c:531: error: request for member `dwCaps' in something not a st
135ructure or union
136src/win/wddaccel.c:531: error: `DDCAPS_BLT' undeclared (first use in this functi
137on)
138src/win/wddaccel.c:538: error: request for member `dwCaps' in something not a st
139ructure or union
140src/win/wddaccel.c:538: error: `DDCAPS_BLTSTRETCH' undeclared (first use in this
141 function)
142src/win/wddaccel.c:547: error: request for member `dwCaps' in something not a st
143ructure or union
144src/win/wddaccel.c:547: error: `DDCAPS_BLTCOLORFILL' undeclared (first use in th
145is function)
146src/win/wddaccel.c:557: error: request for member `dwCaps' in something not a st
147ructure or union
148src/win/wddaccel.c:557: error: `DDCAPS_COLORKEY' undeclared (first use in this f
149unction)
150src/win/wddaccel.c:558: error: request for member `dwCKeyCaps' in something not
151a structure or union
152src/win/wddaccel.c:558: error: `DDCKEYCAPS_SRCBLT' undeclared (first use in this
153 function)
154src/win/wddaccel.c:562: error: request for member `dwCaps' in something not a st
155ructure or union
156src/win/wddaccel.c: In function `gfx_directx_enable_triple_buffering':
157src/win/wddaccel.c:584: warning: implicit declaration of function `IDirectDrawSu
158rface2_GetFlipStatus'
159src/win/wddaccel.c:584: error: syntax error before ')' token
160src/win/wddaccel.c:584: error: `DDGFS_ISFLIPDONE' undeclared (first use in this
161function)
162src/win/wddaccel.c:585: error: `DD_OK' undeclared (first use in this function)
163src/win/wddaccel.c:585: error: `DDERR_WASSTILLDRAWING' undeclared (first use in
164this function)
165make: *** [obj/mingw32/alleg/wddaccel.o] Error 1

---------
Signature.
----
[My Website] | [My YouTube Channel]

gnolam
Member #2,030
March 2002
avatar

Recheck that you unpacked the DirectX headers to the right place. If you did, try dx80min instead and see if it makes a difference.

--
Move to the Democratic People's Republic of Vivendi Universal (formerly known as Sweden) - officially democracy- and privacy-free since 2008-06-18!

CursedTyrant
Member #7,080
April 2006
avatar

I copied the include and lib folders to allegro's main folder, and it doesn't work. Neither does dx80_min.

---------
Signature.
----
[My Website] | [My YouTube Channel]

Kitty Cat
Member #2,815
October 2002
avatar

They go in your compiler's directory, not Allegro's.

--
"Do not meddle in the affairs of cats, for they are subtle and will pee on your computer." -- Bruce Graham

CursedTyrant
Member #7,080
April 2006
avatar

Ok, I've copied them to my compiler's directory, but it still doesn't work. Gives the same errors as before.

---------
Signature.
----
[My Website] | [My YouTube Channel]

Matthew Leverton
Supreme Loser
January 1999
avatar

Quote:

src/win/wddraw.h:33:22: ddraw.h: No such file or directory

That means you have not copied the files into the compiler's include folder.

CursedTyrant
Member #7,080
April 2006
avatar

I have. It produces a lot of errors anyway.

1C:\Documents and Settings\Lechu\Pulpit\allegro-4.2-dev-2006-06-21>make
2Compiling Allegro for MinGW32, optimised. Please wait...
3gcc -DALLEGRO_SRC -DALLEGRO_LIB_BUILD -Wall -Wno-unused -mtune=i586 -O2 -funroll
4-loops -ffast-math -fomit-frame-pointer -I. -I./include -o obj/mingw32/alleg/wd
5sinput.o -c src/win/wdsinput.c
6In file included from src/win/wdsinput.c:33:
7d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/mmsystem.h:1570: error
8: syntax error before "LPCWAVEFORMATEX"
9d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/mmsystem.h:1591: error
10: syntax error before "LPCWAVEFORMATEX"
11In file included from src/win/wdsinput.c:34:
12d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:128: error: s
13yntax error before "LPWAVEFORMATEX"
14d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:134: error: s
15yntax error before '*' token
16d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:142: error: s
17yntax error before "LPWAVEFORMATEX"
18d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:145: error: s
19yntax error before '*' token
20d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:193: error: s
21yntax error before "LPWAVEFORMATEX"
22d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:196: error: s
23yntax error before '*' token
24d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:284: error: s
25yntax error before "LPCDSBUFFERDESC"
26d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:337: error: s
27yntax error before "LPWAVEFORMATEX"
28d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:342: error: s
29yntax error before "LPCDSBUFFERDESC"
30d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:346: error: s
31yntax error before "LPCWAVEFORMATEX"
32d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:569: error: s
33yntax error before "LPCDSCBUFFERDESC"
34d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:607: error: s
35yntax error before "LPWAVEFORMATEX"
36d:/mingw/bin/../lib/gcc/mingw32/3.4.2/../../../../include/dsound.h:609: error: s
37yntax error before "LPCDSCBUFFERDESC"
38src/win/wdsinput.c:54: error: syntax error before "dsc_buf_wfx"
39src/win/wdsinput.c:54: warning: type defaults to `int' in declaration of `dsc_bu
40f_wfx'
41src/win/wdsinput.c:54: warning: data definition has no type or storage class
42src/win/wdsinput.c:120: error: syntax error before '*' token
43src/win/wdsinput.c: In function `create_test_capture_buffer':
44src/win/wdsinput.c:123: error: syntax error before "dsc_trybuf_desc"
45src/win/wdsinput.c:127: error: `dsc_trybuf_desc' undeclared (first use in this f
46unction)
47src/win/wdsinput.c:127: error: (Each undeclared identifier is reported only once
48 
49src/win/wdsinput.c:127: error: for each function it appears in.)
50src/win/wdsinput.c:132: error: `wfx' undeclared (first use in this function)
51src/win/wdsinput.c: At top level:
52src/win/wdsinput.c:150: error: syntax error before "WAVEFORMATEX"
53src/win/wdsinput.c: In function `get_capture_format_support':
54src/win/wdsinput.c:155: error: `WAVEFORMATEX' undeclared (first use in this func
55tion)
56src/win/wdsinput.c:155: error: `test_wfx' undeclared (first use in this function
57)
58src/win/wdsinput.c:190: error: `autodetect' undeclared (first use in this functi
59on)
60src/win/wdsinput.c:194: error: `bits' undeclared (first use in this function)
61src/win/wdsinput.c:194: error: request for member `wBitsPerSample' in something
62not a structure or union
63src/win/wdsinput.c:195: error: `stereo' undeclared (first use in this function)
64src/win/wdsinput.c:195: error: request for member `nChannels' in something not a
65 structure or union
66src/win/wdsinput.c:196: error: request for member `nChannels' in something not a
67 structure or union
68src/win/wdsinput.c:197: error: `rate' undeclared (first use in this function)
69src/win/wdsinput.c:197: error: request for member `nSamplesPerSec' in something
70not a structure or union
71src/win/wdsinput.c:202: error: `wfx' undeclared (first use in this function)
72src/win/wdsinput.c: In function `digi_directsound_capture_init':
73src/win/wdsinput.c:269: error: `WAVEFORMATEX' undeclared (first use in this func
74tion)
75src/win/wdsinput.c:269: error: syntax error before "wfx"
76src/win/wdsinput.c:311: error: `wfx' undeclared (first use in this function)
77src/win/wdsinput.c: In function `digi_directsound_rec_cap_rate':
78src/win/wdsinput.c:401: error: `WAVEFORMATEX' undeclared (first use in this func
79tion)
80src/win/wdsinput.c:401: error: syntax error before "wfx"
81src/win/wdsinput.c:403: error: `wfx' undeclared (first use in this function)
82src/win/wdsinput.c: In function `digi_directsound_rec_start':
83src/win/wdsinput.c:452: error: syntax error before "dscBufDesc"
84src/win/wdsinput.c:465: error: request for member `wBitsPerSample' in something
85not a structure or union
86src/win/wdsinput.c:466: error: request for member `nChannels' in something not a
87 structure or union
88src/win/wdsinput.c:469: error: `dscBufDesc' undeclared (first use in this functi
89on)
90src/win/wdsinput.c:472: error: request for member `nAvgBytesPerSec' in something
91 not a structure or union
92make: *** [obj/mingw32/alleg/wdsinput.o] Error 1

---------
Signature.
----
[My Website] | [My YouTube Channel]

gnolam
Member #2,030
March 2002
avatar

It's a known problem between Allegro 4.2.1 and the latest MinGW WinAPI package.

Edit allegro/include/allegro/platform/almngw32.h and remove the following lines:

#ifndef _LPCWAVEFORMATEX_DEFINED
   #define _LPCWAVEFORMATEX_DEFINED
#endif

It's fixed in SVN, so 4.2.2 should work out of the box when it's released*.

* in a couple of years. ;)

--
Move to the Democratic People's Republic of Vivendi Universal (formerly known as Sweden) - officially democracy- and privacy-free since 2008-06-18!

CursedTyrant
Member #7,080
April 2006
avatar

Thanks a lot, it works now :)

---------
Signature.
----
[My Website] | [My YouTube Channel]

Go to: