[vlc-devel] gcc 4.0 compile problem and fix

Arwed von Merkatz v.merkatz at gmx.net
Sun May 15 19:21:14 CEST 2005


Hi,

latest svn vlc fails to compile with gcc 4.0 here:
if g++ -DHAVE_CONFIG_H -I. -I. -I../../..   -DSYS_LINUX
-I../../../include `top_builddir="../../.." ../../../vlc-config
--cxxflags plugin wxwindows` -Wsign-compare -Wsign-compare -Wall  -pipe
-MT libwxwindows_plugin_a-playlist.o -MD -MP -MF
".deps/libwxwindows_plugin_a-playlist.Tpo" -c -o
libwxwindows_plugin_a-playlist.o `test -f 'playlist.cpp' || echo
'./'`playlist.cpp; \
then mv -f ".deps/libwxwindows_plugin_a-playlist.Tpo"
".deps/libwxwindows_plugin_a-playlist.Po"; else rm -f
".deps/libwxwindows_plugin_a-playlist.Tpo"; exit 1; fi
`-mcpu=' is deprecated. Use `-mtune=' or '-march=' instead.
playlist.cpp:193: error: ‘Playlist’ has not been declared
playlist.cpp:193: warning: ISO C++ forbids declaration of ‘Playlist’
with no type
[...]

Playlist is declared in namespace wxvlc but that namespace isn't in
playlist.cpp, patch attached.

-- 
Arwed v. Merkatz                              Source Mage GNU/Linux developer
                                                    http://www.sourcemage.org
-------------- next part --------------
Index: modules/gui/wxwindows/playlist.cpp
===================================================================
--- modules/gui/wxwindows/playlist.cpp	(revision 11019)
+++ modules/gui/wxwindows/playlist.cpp	(working copy)
@@ -52,6 +52,7 @@
 #define HELP_LOOP N_( "Repeat All" )
 #define HELP_REPEAT N_( "Repeat One" )
 
+namespace wxvlc {
 /* Callback prototype */
 static int PlaylistChanged( vlc_object_t *, const char *,
                             vlc_value_t, vlc_value_t, void * );
@@ -1517,3 +1518,4 @@
 
     return VLC_SUCCESS;
 }
+}


More information about the vlc-devel mailing list