Random clean ups of the logic, consolidating flags_qtdir and
default_qtdir into just 'qtdir', things like that. Anyway, I reverted
them temporarily and remade the patch and here it is.


On Sat, Jan 24, 2009 at 4:15 PM, Albert Santoni <[email protected]> wrote:
> What are the other changes?
>
> On Sat, 2009-01-24 at 14:10 -0500, Nick Guenther wrote:
>> I've made other changes to SConscript now, though, in preparation for
>> cleaning it up. Should I revert and readd the changes for this patch
>> by hand?
>> /me doesn't know how to use svn
>>
>> -Nick
>>
>> On Sat, Jan 24, 2009 at 12:43 PM, Albert Santoni <[email protected]> wrote:
>> > I forgot to mention, just doublecheck for D_WINDOWS and UNICODE, generate a
>> > new patch, and then I think it should be fine to commit.
>> >
>> > Thanks,
>> > Albert
>> >
>> > On 24-Jan-09, at 9:28 AM, Albert Santoni wrote:
>> >
>> >>
>> >> On 22-Jan-09, at 4:55 PM, Nick Guenther wrote:
>> >>
>> >>> I don't have MSVC so ummm, what should I do? Who usually does the
>> >>> Windows work, anyway? Is it that you want me to fix soundtouch before
>> >>> this get committed?
>> >>
>> >> Nobody really does the Windows work. :) Don't worry about that then.
>> >> (Worst case, I'll try to fix anything that's broken when I build a
>> >> windows release.)
>> >>
>> >>>
>> >>> Hopefully there won't be too much __OpenBSD__ but I haven't tried yet.
>> >>> I'll get to that when I am done cleaning up the OS X build :)
>> >>>
>> >>> Except there is no mention of UNICODE or D_WINDOWS in the source code
>> >>> anywhere, so I took them out. That can't break anything, can it?
>> >>>
>> >>
>> >> Yeah, as long as you checked the entire source tree. (ie. all the
>> >> subdirectories in "libs" too)...
>> >>
>> >> Thanks,
>> >> Albert
>> >>
>> >>
>> >>>>
>> >>>> Probably all of the QT-related symbols that we define are obsolete
>> >>>> because
>> >>>> they are all from the QT3 era, and I just left them in for safety
>> >>>> when we
>> >>>> ported to Qt 4/SCONS. Now that I have a bit more experience with
>> >>>> both, I
>> >>>> think they're safe to remove. :)
>> >>>>
>> >>>> If you really need to add __OPENBSD__, go ahead. We try to rely on
>> >>>> libraries
>> >>>> for as much cross-platform functionality as possible (ie. the
>> >>>> libraries have
>> >>>> all the #ifdef __WIN32__ blocks, etc. in them), but sometimes you
>> >>>> just can't
>> >>>> get around it and still have to throw down a bunch of #ifdef
>> >>>> sandwiches.
>> >>>>
>> >>>> Thanks,
>> >>>> Albert
>> >>>>
>> >>>> On 22-Jan-09, at 12:41 PM, Nick Guenther wrote:
>> >>>>
>> >>>>> The build script -D'd __MACX__ and a bunch of source files used it,
>> >>>>> which is silly when Apple's gcc defines __APPLE__. The patch below
>> >>>>> fixes this.
>> >>>>>
>> >>>>> Also, there's a bunch of places in the code that use __WIN__ and
>> >>>>> there's other places that use __WIN32__. I *think* __WIN32__ is the
>> >>>>> canonical #define. Both are defined by the SConscript, though. I'm
>> >>>>> going to clean these up but I'm not entirely sure which to
>> >>>>> standardize
>> >>>>> on. Also, the sconscript line that makes __WIN__ reads
>> >>>>> env.Append(CXXFLAGS = '-DWIN32 -D__WIN__ -DUNICODE -D_WINDOWS') #for
>> >>>>> soundtouch
>> >>>>> but I don't see where this is important. Also there's Q_WS_WIN
>> >>>>> which I
>> >>>>> am guessing is a Qt #define.
>> >>>>>
>> >>>>> FURTHER some places use __UNIX__ and some places use __LINUX__. I'm
>> >>>>> planning to add __OpenBSD__ too. What should we do about all this?
>> >>>>>
>> >>>>>
>> >>>>> Index: lib/ladspa/SConscript
>> >>>>> ===================================================================
>> >>>>> --- lib/ladspa/SConscript       (revision 2471)
>> >>>>> +++ lib/ladspa/SConscript       (working copy)
>> >>>>> @@ -1,4 +1,6 @@
>> >>>>> #We want to build the LADSPA plugins without any "lib" prefix on
>> >>>>> POSIX platforms.
>> >>>>> +
>> >>>>> +#Import('*') #make these all part of a hierarchical build
>> >>>>> env = Environment(SHLIBPREFIX='')
>> >>>>> env.Append(CPPPATH=['.'], ENV = os.environ)
>> >>>>> SConscript(['caps/SConscript'], exports='env')
>> >>>>> Index: src/soundsourceoggvorbis.cpp
>> >>>>> ===================================================================
>> >>>>> --- src/soundsourceoggvorbis.cpp        (revision 2471)
>> >>>>> +++ src/soundsourceoggvorbis.cpp        (working copy)
>> >>>>> @@ -22,7 +22,7 @@
>> >>>>> #include <fcntl.h>
>> >>>>> #endif
>> >>>>>
>> >>>>> -#ifdef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>> #ifdef __i386
>> >>>>> #define OV_ENDIAN_ARG 0
>> >>>>> #else
>> >>>>> Index: src/configobject.cpp
>> >>>>> ===================================================================
>> >>>>> --- src/configobject.cpp        (revision 2471)
>> >>>>> +++ src/configobject.cpp        (working copy)
>> >>>>> @@ -28,7 +28,7 @@
>> >>>>> #include <windows.h>
>> >>>>> #endif
>> >>>>>
>> >>>>> -#ifdef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>> #include <CoreFoundation/CoreFoundation.h>
>> >>>>> #endif
>> >>>>>
>> >>>>> @@ -683,7 +683,7 @@
>> >>>>>  GetModuleFileName(NULL, (WCHAR *)str, 200);
>> >>>>>  qConfigPath = QFileInfo(str).dirPath();
>> >>>>> #endif
>> >>>>> -#ifdef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>>  // Set the path relative to the bundle directory
>> >>>>>  CFURLRef pluginRef =
>> >>>>> CFBundleCopyBundleURL(CFBundleGetMainBundle());
>> >>>>>  CFStringRef macPath = CFURLCopyFileSystemPath(pluginRef,
>> >>>>> kCFURLPOSIXPathStyle);
>> >>>>> Index: src/SConscript
>> >>>>> ===================================================================
>> >>>>> --- src/SConscript      (revision 2471)
>> >>>>> +++ src/SConscript      (working copy)
>> >>>>> @@ -506,7 +506,7 @@
>> >>>>>     env.Append(CXXFLAGS = '-DTEMPORAL -D__UNIX__ -D__LINUX__
>> >>>>> -DBPMSCHEME_FILE=\\".mixxxbpmscheme.xml\\"
>> >>>>> -DSETTINGS_FILE=\\".mixxx.cfg\\" -DTRACK_FILE=\\".mixxxtrack.xml\
>> >>>>> \"')
>> >>>>>     env.Append(CXXFLAGS = '-DUNIX_SHARE_PATH=\\"' +
>> >>>>> ARGUMENTS.get('prefix', '/usr/local') + '/share/mixxx\\"')
>> >>>>> elif platform == 'osx':
>> >>>>> -       env.Append(CXXFLAGS = '-D__MACX__
>> >>>>> -DBPMSCHEME_FILE=\\".mixxxbpmscheme.xml\\"
>> >>>>> -DSETTINGS_FILE=\\".mixxx.cfg\\" -DTRACK_FILE=\\".mixxxtrack.xml\
>> >>>>> \"')
>> >>>>> +       env.Append(CXXFLAGS = '-DBPMSCHEME_FILE=\
>> >>>>> \".mixxxbpmscheme.xml\\"
>> >>>>> -DSETTINGS_FILE=\\".mixxx.cfg\\" -DTRACK_FILE=\\".mixxxtrack.xml\
>> >>>>> \"')
>> >>>>> elif platform == 'win32':
>> >>>>>     env.Append(CXXFLAGS = '-D__WIN32__
>> >>>>> -DBPMSCHEME_FILE=\\"mixxxbpmschemes.xml\\"
>> >>>>> -DSETTINGS_FILE=\\"mixxx.cfg\\" -DTRACK_FILE=\\"mixxxtrack.xml\\"')
>> >>>>>
>> >>>>> Index: src/enginespectralback.h
>> >>>>> ===================================================================
>> >>>>> --- src/enginespectralback.h    (revision 2471)
>> >>>>> +++ src/enginespectralback.h    (working copy)
>> >>>>> @@ -12,14 +12,13 @@
>> >>>>>
>> >>>>> #include "engineobject.h"
>> >>>>> #include <math.h>
>> >>>>> -#ifndef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>> +#include <fftw.h>
>> >>>>> +#include <rfftw.h>
>> >>>>> +#else
>> >>>>> #include <sfftw.h>
>> >>>>> #include <srfftw.h>
>> >>>>> #endif
>> >>>>> -#ifdef __MACX__
>> >>>>> -#include <fftw.h>
>> >>>>> -#include <rfftw.h>
>> >>>>> -#endif
>> >>>>>
>> >>>>> /**
>> >>>>> * Perfoms an inverse FFT on data in polar coordinates.
>> >>>>> Index: src/old/wvisualwaveform.cpp
>> >>>>> ===================================================================
>> >>>>> --- src/old/wvisualwaveform.cpp (revision 2471)
>> >>>>> +++ src/old/wvisualwaveform.cpp (working copy)
>> >>>>> @@ -34,7 +34,7 @@
>> >>>>>
>> >>>>>  installEventFilter(this);
>> >>>>>
>> >>>>> -#ifdef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>>  // Hack to reduce load in GUI thread. This makes the system behave
>> >>>>>  // "correctly" on MacOS X, where it would otherwise stall the
>> >>>>> system
>> >>>>>  // for some seconds now and then.
>> >>>>> Index: src/old/playerportaudio.cpp
>> >>>>> ===================================================================
>> >>>>> --- src/old/playerportaudio.cpp (revision 2471)
>> >>>>> +++ src/old/playerportaudio.cpp (working copy)
>> >>>>> @@ -740,7 +740,7 @@
>> >>>>>  #ifdef __LINUX__
>> >>>>>    return QStringList("OSS (PA)");
>> >>>>>  #endif
>> >>>>> -     #ifdef __MACX__
>> >>>>> +     #ifdef __APPLE__
>> >>>>>    return QStringList("CoreAudio (PA)");
>> >>>>>  #endif
>> >>>>>  #ifdef __WIN__
>> >>>>> Index: src/rtthread.h
>> >>>>> ===================================================================
>> >>>>> --- src/rtthread.h      (revision 2471)
>> >>>>> +++ src/rtthread.h      (working copy)
>> >>>>> @@ -22,7 +22,7 @@
>> >>>>> #ifndef RTTHREAD_H
>> >>>>> #define RTTHREAD_H
>> >>>>>
>> >>>>> -#ifdef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>> #include <mach/mach_init.h>
>> >>>>> #include <mach/task_policy.h>
>> >>>>> #include <mach/thread_act.h>
>> >>>>> @@ -35,7 +35,7 @@
>> >>>>> #include <sys/resource.h>
>> >>>>> #endif
>> >>>>>
>> >>>>> -#ifdef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>> int get_bus_speed();
>> >>>>> #endif
>> >>>>>
>> >>>>> Index: src/soundmanager.cpp
>> >>>>> ===================================================================
>> >>>>> --- src/soundmanager.cpp        (revision 2471)
>> >>>>> +++ src/soundmanager.cpp        (working copy)
>> >>>>> @@ -335,7 +335,7 @@
>> >>>>> //Do something more advanced one day if you like - Adam
>> >>>>>         setHostAPI(MIXXX_PORTAUDIO_DIRECTSOUND_STRING);
>> >>>>> #endif
>> >>>>> -#ifdef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>>     setHostAPI(MIXXX_PORTAUDIO_COREAUDIO_STRING);
>> >>>>> #endif
>> >>>>>  }
>> >>>>> Index: src/reader.cpp
>> >>>>> ===================================================================
>> >>>>> --- src/reader.cpp      (revision 2471)
>> >>>>> +++ src/reader.cpp      (working copy)
>> >>>>> @@ -238,7 +238,7 @@
>> >>>>> void Reader::run()
>> >>>>> {
>> >>>>>  //qDebug() << "Reader running...";
>> >>>>> -#ifdef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>>  rtThread();
>> >>>>> #endif
>> >>>>>
>> >>>>> Index: src/rtthread.cpp
>> >>>>> ===================================================================
>> >>>>> --- src/rtthread.cpp    (revision 2471)
>> >>>>> +++ src/rtthread.cpp    (working copy)
>> >>>>> @@ -23,7 +23,7 @@
>> >>>>> #include <qobject.h>
>> >>>>> #include <QDebug>
>> >>>>>
>> >>>>> -#ifdef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>> int get_bus_speed()
>> >>>>> {
>> >>>>>  int mib[2];
>> >>>>> @@ -43,7 +43,7 @@
>> >>>>>
>> >>>>> void rtThread()
>> >>>>> {
>> >>>>> -#ifdef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>>  struct thread_time_constraint_policy ttcpolicy;
>> >>>>>  kern_return_t theError;
>> >>>>>  /* This is in AbsoluteTime units, which are equal to
>> >>>>> @@ -64,7 +64,7 @@
>> >>>>>     qDebug() << "Can't do thread_policy_set";
>> >>>>> #endif
>> >>>>> #ifdef __UNIX__
>> >>>>> -#ifndef __MACX__
>> >>>>> +#ifndef __APPLE__
>> >>>>>  // Try to set realtime priority on the current executing thread.
>> >>>>> This should be used in time-critical
>> >>>>>  // producer threads.
>> >>>>>  struct sched_param schp;
>> >>>>> Index: src/ladspaloader.cpp
>> >>>>> ===================================================================
>> >>>>> --- src/ladspaloader.cpp        (revision 2471)
>> >>>>> +++ src/ladspaloader.cpp        (working copy)
>> >>>>> @@ -32,7 +32,7 @@
>> >>>>> #ifdef __LINUX__
>> >>>>>     paths.push_back ("/usr/lib/ladspa/");
>> >>>>>     paths.push_back ("/usr/lib64/ladspa/");
>> >>>>> -#elif __MACX__
>> >>>>> +#elif __APPLE__
>> >>>>>     paths.push_back ("/Library/Audio/Plug-ins/LADSPA");
>> >>>>>     paths.push_back ("../../ladspa_plugins"); //ladspa_plugins
>> >>>>> directory in Mixxx.app bundle
>> >>>>>     paths.push_back ("Mixxx.app/ladspa_plugins");
>> >>>>> //ladspa_plugins directory in Mixxx.app bundle
>> >>>>> Index: src/mixxx.cpp
>> >>>>> ===================================================================
>> >>>>> --- src/mixxx.cpp       (revision 2471)
>> >>>>> +++ src/mixxx.cpp       (working copy)
>> >>>>> @@ -86,12 +86,7 @@
>> >>>>>
>> >>>>>  qDebug() << "Mixxx" << VERSION << buildRevision << "is
>> >>>>> starting...";
>> >>>>>  setWindowTitle(tr("Mixxx " VERSION));
>> >>>>> -#ifdef __MACX__
>> >>>>>  setWindowIcon(QIcon(":icon.svg"));
>> >>>>> -#else
>> >>>>> -    setWindowIcon(QIcon(":icon.svg"));
>> >>>>> -    //setWindowIcon(QIcon(":iconsmall.png")); //This is a smaller
>> >>>>> 16x16 icon, looks cleaner...
>> >>>>> -#endif
>> >>>>>
>> >>>>>  //Reset pointer to players
>> >>>>>  soundmanager = 0;
>> >>>>> Index: src/main.cpp
>> >>>>> ===================================================================
>> >>>>> --- src/main.cpp        (revision 2471)
>> >>>>> +++ src/main.cpp        (working copy)
>> >>>>> @@ -153,7 +153,7 @@
>> >>>>>
>> >>>>> //Hack to make QT4 find the plugins when packaging in the Mixxx.app
>> >>>>> bundle on OS X.
>> >>>>> //See http://doc.trolltech.com/4.3/deployment-mac.html for details.
>> >>>>> -#ifdef __MACX__
>> >>>>> +#ifdef __APPLE__
>> >>>>>  QDir dir(QApplication::applicationDirPath());
>> >>>>>  dir.cdUp();
>> >>>>>  dir.cd("plugins");
>> >>>>>
>> >>>>>
>> >>>>>
>> >>>>> ------------------------------------------------------------------------------
>> >>>>> This SF.net email is sponsored by:
>> >>>>> SourcForge Community
>> >>>>> SourceForge wants to tell your story.
>> >>>>> http://p.sf.net/sfu/sf-spreadtheword
>> >>>>> _______________________________________________
>> >>>>> Mixxx-devel mailing list
>> >>>>> [email protected]
>> >>>>> https://lists.sourceforge.net/lists/listinfo/mixxx-devel
>> >>>>
>> >>>>
>> >>
>> >>
>> >>
>> >> ------------------------------------------------------------------------------
>> >> This SF.net email is sponsored by:
>> >> SourcForge Community
>> >> SourceForge wants to tell your story.
>> >> http://p.sf.net/sfu/sf-spreadtheword
>> >> _______________________________________________
>> >> Mixxx-devel mailing list
>> >> [email protected]
>> >> https://lists.sourceforge.net/lists/listinfo/mixxx-devel
>> >
>> >
>
>
Index: lib/ladspa/SConscript
===================================================================
--- lib/ladspa/SConscript	(revision 2488)
+++ lib/ladspa/SConscript	(working copy)
@@ -1,4 +1,6 @@
 #We want to build the LADSPA plugins without any "lib" prefix on POSIX platforms.
+
+#Import('*') #make these all part of a hierarchical build
 env = Environment(SHLIBPREFIX='')
 env.Append(CPPPATH=['.'], ENV = os.environ)
 SConscript(['caps/SConscript'], exports='env')
Index: lib/libsamplerate/config.h
===================================================================
--- lib/libsamplerate/config.h	(revision 2488)
+++ lib/libsamplerate/config.h	(working copy)
@@ -3,7 +3,7 @@
 
 // Merges between win32 and linux version by Tue
 
-#ifdef __WIN__
+#ifdef __WIN32__
 
 #pragma warning(disable: 4305)
 
Index: src/mididevicehandler.cpp
===================================================================
--- src/mididevicehandler.cpp	(revision 2488)
+++ src/mididevicehandler.cpp	(working copy)
@@ -35,7 +35,7 @@
 #ifdef __LINUX__
 #include "powermatelinux.h"
 #endif
-#ifdef __WIN__
+#ifdef __WIN32__
 #include "powermatewin.h"
 #endif
 
Index: src/dlgprefmidi.cpp
===================================================================
--- src/dlgprefmidi.cpp	(revision 2488)
+++ src/dlgprefmidi.cpp	(working copy)
@@ -69,7 +69,7 @@
 #ifdef __LINUX__
 #include "powermatelinux.h"
 #endif
-#ifdef __WIN__
+#ifdef __WIN32__
 #include "powermatewin.h"
 #endif
 
@@ -178,7 +178,7 @@
     m_pPowerMate1 = new PowerMateLinux();
     m_pPowerMate2 = new PowerMateLinux();
 #endif
-#ifdef __WIN__
+#ifdef __WIN32__
 //    m_pPowerMate1 = new PowerMateWin();
 //    m_pPowerMate2 = new PowerMateWin();
 #endif
@@ -430,7 +430,7 @@
 
     // Close MIDI
 #ifndef __LINUX__
-#ifndef __WIN__
+#ifndef __WIN32__
     // Deadly hack attack
     m_pMidi->devClose();
 #endif
Index: src/soundsourceoggvorbis.cpp
===================================================================
--- src/soundsourceoggvorbis.cpp	(revision 2488)
+++ src/soundsourceoggvorbis.cpp	(working copy)
@@ -17,12 +17,12 @@
 #include "trackinfoobject.h"
 #include "soundsourceoggvorbis.h"
 #include <QtDebug>
-#ifdef __WIN__
+#ifdef __WIN32__
 #include <io.h>
 #include <fcntl.h>
 #endif
 
-#ifdef __MACX__
+#ifdef __APPLE__
 #ifdef __i386
 #define OV_ENDIAN_ARG 0
 #else
@@ -52,7 +52,7 @@
 {
     QByteArray qBAFilename = qFilename.toUtf8();
 
-#ifdef __WIN__
+#ifdef __WIN32__
     if(ov_fopen(qBAFilename.data(), &vf) < 0) {
         qDebug() << "oggvorbis: Input does not appear to be an Ogg bitstream.";
         filelength = 0;
@@ -190,7 +190,7 @@
     vorbis_comment *comment = NULL;
     OggVorbis_File vf;
 
-#ifdef __WIN__
+#ifdef __WIN32__
     if (ov_fopen(qBAFilename.data(), &vf) < 0) {
         qDebug() << "oggvorbis: Input does not appear to be an Ogg bitstream.";        
         return ERR;
Index: src/mixxx.vcproj
===================================================================
--- src/mixxx.vcproj	(revision 2488)
+++ src/mixxx.vcproj	(working copy)
@@ -45,7 +45,7 @@
 				AdditionalOptions="-Zm200 -GX -EHsc -EHsc -w34100 -w34189"
 				Optimization="2"
 				AdditionalIncludeDirectories="..\lib\vbrheadersdk,..\lib\kissfft,..\lib\soundtouch,..\lib\soundtouch,..\..\mixxx-winlib,..\lib,.,$(QTDIR)\include,.,D:\qt\mkspecs\win32-msvc2005"
-				PreprocessorDefinitions="_WINDOWS,UNICODE,WIN32,__PORTAUDIO__,__WINMIDI__,__SNDFILE__,__WIN__,TEMPORAL,SETTINGS_FILE=\&quot;mixxx.cfg\&quot;,TRACK_FILE=\&quot;mixxxtrack.xml\&quot;,__NO_INTTYPES__,T_MSVC,QT_THREAD_SUPPORT,NDEBUG,QT_NO_DEBUG"
+				PreprocessorDefinitions="WIN32,__PORTAUDIO__,__WINMIDI__,__SNDFILE__,__WIN32__,TEMPORAL,SETTINGS_FILE=\&quot;mixxx.cfg\&quot;,TRACK_FILE=\&quot;mixxxtrack.xml\&quot;,__NO_INTTYPES__,T_MSVC,QT_THREAD_SUPPORT,NDEBUG,QT_NO_DEBUG"
 				GeneratePreprocessedFile="0"
 				MinimalRebuild="true"
 				ExceptionHandling="1"
@@ -141,7 +141,7 @@
 				AdditionalOptions="-Zm200 -GX -EHsc -EHsc -w34100 -w34189"
 				Optimization="4"
 				AdditionalIncludeDirectories="..\lib\vbrheadersdk,..\lib\kissfft,..\lib\soundtouch,..\lib\soundtouch,..\..\mixxx-winlib,..\lib,.,$(QTDIR)\include,.,D:\qt\mkspecs\win32-msvc2005"
-				PreprocessorDefinitions="_WINDOWS,UNICODE,WIN32,__PORTAUDIO__,__WINMIDI__,__SNDFILE__,__WIN__,TEMPORAL,SETTINGS_FILE=\&quot;mixxx.cfg\&quot;,TRACK_FILE=\&quot;mixxxtrack.xml\&quot;,__NO_INTTYPES__,T_MSVC,QT_THREAD_SUPPORT"
+				PreprocessorDefinitions="WIN32,__PORTAUDIO__,__WINMIDI__,__SNDFILE__,__WIN32__,TEMPORAL,SETTINGS_FILE=\&quot;mixxx.cfg\&quot;,TRACK_FILE=\&quot;mixxxtrack.xml\&quot;,__NO_INTTYPES__,T_MSVC,QT_THREAD_SUPPORT"
 				GeneratePreprocessedFile="0"
 				MinimalRebuild="true"
 				ExceptionHandling="1"
Index: src/configobject.cpp
===================================================================
--- src/configobject.cpp	(revision 2488)
+++ src/configobject.cpp	(working copy)
@@ -24,11 +24,11 @@
 #include "cmetrics.h"
 #endif
 
-#ifdef __WIN__
+#ifdef __WIN32__
 #include <windows.h>
 #endif
 
-#ifdef __MACX__
+#ifdef __APPLE__
 #include <CoreFoundation/CoreFoundation.h>
 #endif
 
@@ -677,13 +677,13 @@
         qConfigPath = UNIX_SHARE_PATH;
     }
 #endif
-#ifdef __WIN__
+#ifdef __WIN32__
     // On Windows, set the config dir relative to the application dir
     char * str = new char[200];
     GetModuleFileName(NULL, (WCHAR *)str, 200);
     qConfigPath = QFileInfo(str).dirPath();
 #endif
-#ifdef __MACX__
+#ifdef __APPLE__
     // Set the path relative to the bundle directory
     CFURLRef pluginRef = CFBundleCopyBundleURL(CFBundleGetMainBundle());
     CFStringRef macPath = CFURLCopyFileSystemPath(pluginRef, kCFURLPOSIXPathStyle);
Index: src/SConscript
===================================================================
--- src/SConscript	(revision 2488)
+++ src/SConscript	(working copy)
@@ -639,7 +639,7 @@
 	env.Append(CXXFLAGS = '-DTEMPORAL -D__UNIX__ -D__LINUX__ -DBPMSCHEME_FILE=\\".mixxxbpmscheme.xml\\" -DSETTINGS_FILE=\\".mixxx.cfg\\" -DTRACK_FILE=\\".mixxxtrack.xml\\"')
 	env.Append(CXXFLAGS = '-DUNIX_SHARE_PATH=\\"' + ARGUMENTS.get('prefix', '/usr/local') + '/share/mixxx\\"')
 elif platform == 'osx':
-	env.Append(CXXFLAGS = '-D__MACX__ -DBPMSCHEME_FILE=\\".mixxxbpmscheme.xml\\" -DSETTINGS_FILE=\\".mixxx.cfg\\" -DTRACK_FILE=\\".mixxxtrack.xml\\"')
+	env.Append(CXXFLAGS = '-DBPMSCHEME_FILE=\\".mixxxbpmscheme.xml\\" -DSETTINGS_FILE=\\".mixxx.cfg\\" -DTRACK_FILE=\\".mixxxtrack.xml\\"')
 elif platform == 'win32':
 	env.Append(CXXFLAGS = '-D__WIN32__ -DBPMSCHEME_FILE=\\"mixxxbpmschemes.xml\\" -DSETTINGS_FILE=\\"mixxx.cfg\\" -DTRACK_FILE=\\"mixxxtrack.xml\\"')
 
@@ -682,8 +682,8 @@
 	env.Append(CCFLAGS = Split(""" -pipe -Wall -W -g -D_REENTRANT """)) # omghax
 	env.Append(LINKFLAGS = Split(""" -pipe -Wall -W -g -Wl,-rpath,$QTDIR/lib"""))
 if platform == 'win32':
-	env.Append(CXXFLAGS = '-DWIN32 -D__WIN__ -DUNICODE -D_WINDOWS') #for soundtouch
-	env.Append(CCFLAGS  = '-DWIN32 -D__WIN__ -DUNICODE -D_WINDOWS') #for soundtouch
+	env.Append(CXXFLAGS = '-DWIN32') #for soundtouch
+	env.Append(CCFLAGS  = '-DWIN32') #for soundtouch
 
 #Uic these guys (they're moc'd automatically after this) - Generates the code for the QT UI forms
 env.Uic4('dlgpreferencesdlg.ui')
Index: src/old/wvisualwaveform.cpp
===================================================================
--- src/old/wvisualwaveform.cpp	(revision 2488)
+++ src/old/wvisualwaveform.cpp	(working copy)
@@ -34,7 +34,7 @@
 
     installEventFilter(this);
 
-#ifdef __MACX__
+#ifdef __APPLE__
     // Hack to reduce load in GUI thread. This makes the system behave
     // "correctly" on MacOS X, where it would otherwise stall the system
     // for some seconds now and then.
@@ -44,7 +44,7 @@
     //I'm going to experiment a bit with the timings - Albert:
     m_iTimerID = startTimer(30);
 #endif
-#ifdef __WIN__
+#ifdef __WIN32__
     m_iTimerID = startTimer(30);
 #endif
 #ifdef __LINUX__
Index: src/old/playerportaudio.cpp
===================================================================
--- src/old/playerportaudio.cpp	(revision 2488)
+++ src/old/playerportaudio.cpp	(working copy)
@@ -740,10 +740,10 @@
      #ifdef __LINUX__
        return QStringList("OSS (PA)");
      #endif
-     #ifdef __MACX__
+     #ifdef __APPLE__
        return QStringList("CoreAudio (PA)");
      #endif
-     #ifdef __WIN__
+     #ifdef __WIN32__
        return QStringList("WMME (PA)");
      #endif
      */
Index: src/old/playerrtaudio.cpp
===================================================================
--- src/old/playerrtaudio.cpp	(revision 2488)
+++ src/old/playerrtaudio.cpp	(working copy)
@@ -343,7 +343,7 @@
 
 QString PlayerRtAudio::getSoundApi()
 {
-#ifdef __WIN__
+#ifdef __WIN32__
     return QString("DirectSound");
 #endif
 #ifdef __LINUX__
Index: src/rtthread.h
===================================================================
--- src/rtthread.h	(revision 2488)
+++ src/rtthread.h	(working copy)
@@ -22,7 +22,7 @@
 #ifndef RTTHREAD_H
 #define RTTHREAD_H
 
-#ifdef __MACX__
+#ifdef __APPLE__
   #include <mach/mach_init.h>
   #include <mach/task_policy.h>
   #include <mach/thread_act.h>
@@ -35,7 +35,7 @@
   #include <sys/resource.h>
 #endif
 
-#ifdef __MACX__
+#ifdef __APPLE__
   int get_bus_speed();
 #endif
 
Index: src/soundmanager.cpp
===================================================================
--- src/soundmanager.cpp	(revision 2488)
+++ src/soundmanager.cpp	(working copy)
@@ -335,7 +335,7 @@
 //Do something more advanced one day if you like - Adam
             setHostAPI(MIXXX_PORTAUDIO_DIRECTSOUND_STRING);
 #endif
-#ifdef __MACX__
+#ifdef __APPLE__
         setHostAPI(MIXXX_PORTAUDIO_COREAUDIO_STRING);
 #endif
     }
Index: src/soundsourceffmpeg.cpp
===================================================================
--- src/soundsourceffmpeg.cpp	(revision 2488)
+++ src/soundsourceffmpeg.cpp	(working copy)
@@ -17,7 +17,7 @@
 
 #include "trackinfoobject.h"
 #include "soundsourceffmpeg.h"
-//#ifdef __WIN__
+//#ifdef __WIN32__
 //#include <io.h>
 //#include <fcntl.h>
 //#endif
Index: src/mixxxview.cpp
===================================================================
--- src/mixxxview.cpp	(revision 2488)
+++ src/mixxxview.cpp	(working copy)
@@ -71,7 +71,7 @@
     // Try to open the file pointed to by qSkinPath
     QDomElement docElem = openSkin(qSkinPath);
 
-#ifdef __WIN__
+#ifdef __WIN32__
 #ifndef QT3_SUPPORT
     // QPixmap fix needed on Windows 9x
     QPixmap::setDefaultOptimization(QPixmap::MemoryOptim);
@@ -104,7 +104,7 @@
     // Load all widgets defined in the XML file
     createAllWidgets(docElem, parent, pConfig);
 
-#ifdef __WIN__
+#ifdef __WIN32__
 #ifndef QT3_SUPPORT
     // QPixmap fix needed on Windows 9x
     QPixmap::setDefaultOptimization(QPixmap::NormalOptim);
Index: src/mathstuff.cpp
===================================================================
--- src/mathstuff.cpp	(revision 2488)
+++ src/mathstuff.cpp	(working copy)
@@ -109,7 +109,7 @@
     return(r);
 }
 
-#ifdef __WIN__
+#ifdef __WIN32__
 // Rounds a CSAMPLE to nearest integer, and returns as int
 int round(CSAMPLE x)
 {
Index: src/reader.cpp
===================================================================
--- src/reader.cpp	(revision 2488)
+++ src/reader.cpp	(working copy)
@@ -238,7 +238,7 @@
 void Reader::run()
 {
     //qDebug() << "Reader running...";
-#ifdef __MACX__
+#ifdef __APPLE__
     rtThread();
 #endif
 
Index: src/dlgprefplaylist.cpp
===================================================================
--- src/dlgprefplaylist.cpp	(revision 2488)
+++ src/dlgprefplaylist.cpp	(working copy)
@@ -64,7 +64,7 @@
 {
 QString iPodMountPoint;
 QFileInfoList mountpoints;
-#ifdef __WINDOWS__
+#ifdef __WIN32__
   // Windows iPod Detection
   mountpoints = QDir::drives();
 #elif __LINUX__
Index: src/rtthread.cpp
===================================================================
--- src/rtthread.cpp	(revision 2488)
+++ src/rtthread.cpp	(working copy)
@@ -16,14 +16,14 @@
 
 #include "rtthread.h"
 
-#ifdef __WIN__
+#ifdef __WIN32__
   #include "windows.h"
 #endif
 #include <string.h>
 #include <qobject.h>
 #include <QDebug>
 
-#ifdef __MACX__
+#ifdef __APPLE__
 int get_bus_speed()
 {
     int mib[2];
@@ -43,7 +43,7 @@
 
 void rtThread()
 {
-#ifdef __MACX__
+#ifdef __APPLE__
     struct thread_time_constraint_policy ttcpolicy;
     kern_return_t theError;
     /* This is in AbsoluteTime units, which are equal to
@@ -64,7 +64,7 @@
         qDebug() << "Can't do thread_policy_set";
 #endif
 #ifdef __UNIX__
-#ifndef __MACX__
+#ifndef __APPLE__
     // Try to set realtime priority on the current executing thread. This should be used in time-critical
     // producer threads.
     struct sched_param schp;
@@ -80,7 +80,7 @@
         qDebug() << "Not possible to give audio producer thread high prioriy.";
 #endif
 #endif
-#ifdef __WIN__
+#ifdef __WIN32__
 //    HANDLE h = GetCurrentThread();
 //    SetThreadPriority(h,THREAD_PRIORITY_BELOW_NORMAL);
 #endif
Index: src/powermate.h
===================================================================
--- src/powermate.h	(revision 2488)
+++ src/powermate.h	(working copy)
@@ -18,7 +18,7 @@
 #ifndef POWERMATE_H
 #define POWERMATE_H
 
-#ifdef __WIN__
+#ifdef __WIN32__
 #ifndef _MSC_VER
 /* Not MSVC, one of these:
    __MINGW32__
Index: src/tonal/CircularPeaksToPCP.hxx
===================================================================
--- src/tonal/CircularPeaksToPCP.hxx	(revision 2488)
+++ src/tonal/CircularPeaksToPCP.hxx	(working copy)
@@ -25,7 +25,7 @@
 #include <vector>
 #include <cmath>
 
-#ifdef __WIN__
+#ifdef __WIN32__
 #define _USE_MATH_DEFINES
 #include <math.h>
 #endif
Index: src/tonal/ConstantQTransform.hxx
===================================================================
--- src/tonal/ConstantQTransform.hxx	(revision 2488)
+++ src/tonal/ConstantQTransform.hxx	(working copy)
@@ -25,7 +25,7 @@
 #include <vector>
 #include <cmath>
 
-#ifdef __WIN__
+#ifdef __WIN32__
 #define _USE_MATH_DEFINES
 #include <math.h>
 #endif
Index: src/track.cpp
===================================================================
--- src/track.cpp	(revision 2488)
+++ src/track.cpp	(working copy)
@@ -10,7 +10,7 @@
 //
 //
 
-#ifdef __WIN__
+#ifdef __WIN32__
 #include <windows.h> // for Sleep()  on Windows
 #endif
 
@@ -1450,7 +1450,7 @@
     while (m_pBpmDetector->queueCount()) {
       // TODO: convert the qDebug statement to a status dialog box.
       qDebug() << "---- waiting for BPM detection queue to empty... " << m_pBpmDetector->queueCount() << " to go.";
-#ifdef __WIN__
+#ifdef __WIN32__
       Sleep(3000);
 #else
       sleep(3);
Index: src/hercules.h
===================================================================
--- src/hercules.h	(revision 2488)
+++ src/hercules.h	(working copy)
@@ -18,7 +18,7 @@
 #ifndef HERCULES_H
 #define HERCULES_H
 
-#ifdef __WIN__
+#ifdef __WIN32__
 #ifndef _MSC_VER
 /* Not MSVC, one of these:
    __MINGW32__
Index: src/mathstuff.h
===================================================================
--- src/mathstuff.h	(revision 2488)
+++ src/mathstuff.h	(working copy)
@@ -28,7 +28,7 @@
 int invmatrix(CSAMPLE *);
 void polcoe(CSAMPLE x[], CSAMPLE y[], int n, CSAMPLE cof[]);
 CSAMPLE mod2pi(CSAMPLE);
-#ifdef __WIN__
+#ifdef __WIN32__
 int round(CSAMPLE x);
 #endif
 CSAMPLE arctan2(CSAMPLE y, CSAMPLE x);
Index: src/mixxx.cpp
===================================================================
--- src/mixxx.cpp	(revision 2488)
+++ src/mixxx.cpp	(working copy)
@@ -86,12 +86,7 @@
 
     qDebug() << "Mixxx" << VERSION << buildRevision << "is starting...";
     setWindowTitle(tr("Mixxx " VERSION));
-#ifdef __MACX__
     setWindowIcon(QIcon(":icon.svg"));
-#else
-    setWindowIcon(QIcon(":icon.svg"));
-    //setWindowIcon(QIcon(":iconsmall.png")); //This is a smaller 16x16 icon, looks cleaner...
-#endif
 
     //Reset pointer to players
     soundmanager = 0;
@@ -332,7 +327,7 @@
 #endif
 
     // Set up socket interface
-//#ifndef __WIN__
+//#ifndef __WIN32__
 //    new MixxxSocketServer(m_pTrack);
 //#endif
 
@@ -442,7 +437,7 @@
     qDebug() << "delete config, " << qTime.elapsed();
     delete config;
 
-#ifdef __WIN__
+#ifdef __WIN32__
     _exit(0);
 #endif
 }
Index: src/soundsourcem4a.cpp
===================================================================
--- src/soundsourcem4a.cpp	(revision 2488)
+++ src/soundsourcem4a.cpp	(working copy)
@@ -19,7 +19,7 @@
 #include <QtDebug>
 #include "neaacdec.h"
 
-#ifdef __WIN__
+#ifdef __WIN32__
 #include <io.h>
 #include <fcntl.h>
 #endif
Index: src/main.cpp
===================================================================
--- src/main.cpp	(revision 2488)
+++ src/main.cpp	(working copy)
@@ -153,7 +153,7 @@
 
 //Hack to make QT4 find the plugins when packaging in the Mixxx.app bundle on OS X.
 //See http://doc.trolltech.com/4.3/deployment-mac.html for details.
-#ifdef __MACX__
+#ifdef __APPLE__
     QDir dir(QApplication::applicationDirPath());
     dir.cdUp();
     dir.cd("plugins");
------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
_______________________________________________
Mixxx-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mixxx-devel

Reply via email to