Skip to content

Commit

Permalink
add licence to main.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
bill-auger committed Jul 30, 2016
1 parent 95b65b5 commit 05eedf0
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 38 deletions.
35 changes: 18 additions & 17 deletions README-MINGW.md
Original file line number Diff line number Diff line change
@@ -1,32 +1,33 @@

install mingw-get then mingw-develp[er-tools , mingw32-base , mingw32-gcc-g++ packages
add mingw and msys bin dirs to windows %PATH%
install jack for windows
download and extract SDL-mingw , SDL_gfx , SDL_ttf tarballs
* install mingw-get then mingw-develp[er-tools , mingw32-base , mingw32-gcc-g++ packages
* add mingw and msys bin dirs to windows %PATH%
* install jack for windows
* download and extract SDL-mingw , SDL_gfx , SDL_ttf tarballs
e.g. SDL-devel-1.2.15-mingw32.tar.gz
SDL_gfx-2.0.25.tar.gz
SDL_ttf-devel-2.0.11-VC.zip (pre-bult binaries)
compile and install SDL, SDL_gfx, and SDL_ttf libs
workaround if system dirs are borked - e.g.
* /usr/include/ is /c/MinGW/msys/1.0/include
* sdl headers must be in /c/MinGW/msys/1.0/include
* but jack headers must be in /c/MinGW/include
```bash
$ cp -rf /usr/include/* /c/MinGW/include/
$ rm -rf /usr/include/
$ ln -s /c/MinGW/include /usr/include
```
copy any pre-built libs and headers to system dirs
* compile and install SDL, SDL_gfx, and SDL_ttf libs
* copy any pre-built libs and headers to system dirs
```bash
$ cp /c/Program\ Files/Jack/includes/jack /usr/include/
$ cp /c/src/sdl/SDL-1.2.15/include/SDL/SDL.h /usr/include/SDL/
$ cp /c/src/sdl/SDL_gfx-2.0.25/SDL_gfxPrimitives.h /usr/include/SDL/
$ cp /c/src/sdl/SDL_gfx-2.0.25/SDL_rotozoom.h /usr/include/SDL/
$ cp /c/src/sdl/SDL_ttf-2.0.11/include/SDL_ttf.h /usr/include/SDL/
```
copy static libs to system lib dir
* copy static libs to system lib dir
```bash
$ cp /c/Program\ Files/Jack/lib/libjack.lib /usr/lib/
$ cp /c/src/sdl/SDL_gfx-2.0.25/Release/SDL_gfx.lib /usr/lib/
$ cp /c/src/sdl/SDL_ttf-2.0.11/lib/x86/SDL_ttf.lib /usr/lib/
```

workaround if system dirs are borked - e.g. GitBash gets MinGW confused
```bash
### * /usr/include/ is /c/MinGW/msys/1.0/include
### * sdl headers must be in /c/MinGW/msys/1.0/include
### * but jack headers must be in /c/MinGW/include

$ cp -rf /usr/include/* /c/MinGW/include/
$ rm -rf /usr/include/
$ ln -s /c/MinGW/include /usr/include
```
56 changes: 35 additions & 21 deletions src/main.cpp
Original file line number Diff line number Diff line change
@@ -1,19 +1,33 @@
/*
Loopidity MVC classes:
Loopidity - main controller class (== 0 instances)
LoopiditySDL - main view class (== 0 instances)
Scene - scene model class (== NUM_SCENES instances)
SceneSDL - scene view class (== NUM_SCENES instances)
Loop - loop model class (<= NUM_SCENES * N_LOOPS instances)
LoopSDL - loop view class (<= NUM_SCENES * N_LOOPS instances)
JackIO - JACK wrapper class (== 0 instances)
Trace - debug trace class (== 0 instances)
*/


#ifdef _WIN32
# include <fstream>
#endif // _WIN32
/*\ Loopidity - multitrack audio looper designed for live handsfree use
|*| https://github.com/bill-auger/loopidity/issues/
|*| Copyright 2013,2015 Bill Auger - https://bill-auger.github.io/
|*|
|*| This file is part of Loopidity.
|*|
|*| Loopidity is free software: you can redistribute it and/or modify
|*| it under the terms of the GNU General Public License version 3
|*| as published by the Free Software Foundation.
|*|
|*| Loopidity is distributed in the hope that it will be useful,
|*| but WITHOUT ANY WARRANTY; without even the implied warranty of
|*| MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|*| GNU General Public License for more details.
|*|
|*| You should have received a copy of the GNU General Public License
|*| along with Loopidity. If not, see <http://www.gnu.org/licenses/>.
\*/

/*\ Loopidity MVC classes:
|*| Loopidity - main controller class (== 0 instances)
|*| LoopiditySDL - main view class (== 0 instances)
|*| Scene - scene model class (== NUM_SCENES instances)
|*| SceneSDL - scene view class (== NUM_SCENES instances)
|*| Loop - loop model class (<= N_LOOPS * NUM_SCENES instances)
|*| LoopSDL - loop view class (<= N_LOOPS * NUM_SCENES instances)
|*| JackIO - JACK wrapper class (== 0 instances)
|*| Trace - debug trace class (== 0 instances)
\*/


#include "loopidity.h"

Expand All @@ -22,11 +36,11 @@ Trace - debug trace class (== 0 instances)

int main(int argc , char** argv)
{
DEBUG_TRACE_MAIN_IN

int exitStatus = Loopidity::Main(argc , argv) ; Loopidity::Cleanup() ;
int exitStatus = Loopidity::Main(argc , argv) ; Loopidity::Cleanup() ;

DEBUG_TRACE_MAIN_OUT
#if DEBUG_TRACE
if (exitStatus) cout << INIT_FAIL_MSG << endl ;
#endif

return exitStatus ;
return exitStatus ;
}

0 comments on commit 05eedf0

Please sign in to comment.