From cd988786b9baddac25fc973e2ea00b2b5df429d3 Mon Sep 17 00:00:00 2001 From: Sam Hocevar Date: Tue, 2 Sep 2014 18:12:05 +0000 Subject: [PATCH] build: reorganise includes so that we can use precompiled headers later. --- demos/test/benchmark/half.cpp | 4 +-- demos/test/benchmark/real.cpp | 4 +-- demos/test/benchmark/trig.cpp | 2 +- demos/test/benchmark/vector.cpp | 4 +-- demos/test/benchsuite.cpp | 4 +-- demos/test/btphystest.cpp | 4 +-- demos/test/generated/scenesetup-parser.cpp | 4 +-- demos/test/generated/scenesetup-scanner.cpp | 4 +-- demos/test/math/pi.cpp | 4 +-- demos/test/math/poly.cpp | 4 +-- demos/test/meshviewer.cpp | 4 +-- demos/test/nacl_phystest.cpp | 4 +-- demos/test/physicobject.h | 2 +- .../physics/bulletcharactercontroller.cpp | 4 +-- .../test/physics/bulletcharactercontroller.h | 2 +- .../test/physics/easycharactercontroller.cpp | 2 +- demos/test/physics/easycharactercontroller.h | 2 +- demos/test/physics/easyconstraint.cpp | 2 +- demos/test/physics/easyconstraint.h | 2 +- demos/test/physics/easyphysics.cpp | 2 +- demos/test/physics/easyphysics.h | 2 +- demos/test/sandbox/sample.cpp | 4 +-- demos/test/scenesetup-compiler.cpp | 4 +-- demos/test/scenesetup.cpp | 4 +-- demos/tutorial/01_triangle.cpp | 4 +-- demos/tutorial/02_cube.cpp | 4 +-- demos/tutorial/03_noise.cpp | 4 +-- demos/tutorial/04_texture.cpp | 4 +-- demos/tutorial/05_easymesh.cpp | 4 +-- demos/tutorial/06_sprite.cpp | 4 +-- demos/tutorial/07_input.cpp | 4 +-- demos/tutorial/08_fbo.cpp | 4 +-- demos/tutorial/11_fractal.cpp | 4 +-- demos/tutorial/12_voronoi.cpp | 4 +-- src/Makefile.am | 3 +- src/application/application.cpp | 6 +--- src/audio.cpp | 6 +--- src/base/assert.cpp | 6 +--- src/base/enum.cpp | 6 +--- src/base/hash.cpp | 6 +--- src/base/log.cpp | 6 +--- src/base/string.cpp | 6 +--- src/camera.cpp | 6 +--- src/debug/fps.cpp | 5 +--- src/debug/lines.cpp | 6 +--- src/debug/record.cpp | 5 +--- src/debug/stats.cpp | 5 +--- src/dict.cpp | 6 +--- src/easymesh/csgbsp.cpp | 7 +---- src/easymesh/easymesh-compiler.cpp | 5 +--- src/easymesh/easymesh.cpp | 5 +--- src/easymesh/easymeshbuild.cpp | 6 +--- src/easymesh/easymeshrender.cpp | 6 +--- src/eglapp.cpp | 5 +--- src/emitter.cpp | 6 +--- src/entity.cpp | 6 +--- src/font.cpp | 6 +--- src/forge.cpp | 6 +--- src/generated/easymesh-parser.cpp | 5 +--- src/generated/easymesh-scanner.cpp | 5 +--- src/generated/lolfx-parser.cpp | 6 +--- src/generated/lolfx-scanner.cpp | 5 +--- src/gpu/framebuffer.cpp | 5 +--- src/gpu/indexbuffer.cpp | 5 +--- src/gpu/lolfx-compiler.cpp | 5 +--- src/gpu/lolfx.cpp | 5 +--- src/gpu/rendercontext.cpp | 6 +--- src/gpu/renderer.cpp | 5 +--- src/gpu/shader.cpp | 5 +--- src/gpu/texture.cpp | 5 +--- src/gpu/vertexbuffer.cpp | 5 +--- src/gradient.cpp | 6 +--- src/image/codec/android-image.cpp | 5 +--- src/image/codec/dummy-image.cpp | 5 +--- src/image/codec/gdiplus-image.cpp | 5 +--- src/image/codec/imlib2-image.cpp | 5 +--- src/image/codec/ios-image.cpp | 5 +--- src/image/codec/oric-image.cpp | 5 +--- src/image/codec/ps3-image.cpp | 5 +--- src/image/codec/sdl-image.cpp | 5 +--- src/image/codec/zed-image.cpp | 5 +--- src/image/codec/zed-palette-image.cpp | 5 +--- src/image/color/cie1931.cpp | 6 +--- src/image/color/color.cpp | 6 +--- src/image/combine.cpp | 6 +--- src/image/crop.cpp | 5 +--- src/image/dither/dbs.cpp | 6 +--- src/image/dither/ediff.cpp | 6 +--- src/image/dither/ordered.cpp | 6 +--- src/image/dither/ostromoukhov.cpp | 6 +--- src/image/dither/random.cpp | 6 +--- src/image/filter/color.cpp | 6 +--- src/image/filter/convolution.cpp | 6 +--- src/image/filter/dilate.cpp | 6 +--- src/image/filter/median.cpp | 6 +--- src/image/filter/yuv.cpp | 6 +--- src/image/image.cpp | 5 +--- src/image/kernel.cpp | 6 +--- src/image/noise.cpp | 6 +--- src/image/pixel.cpp | 5 +--- src/image/resample.cpp | 6 +--- src/input/controller.cpp | 6 +--- src/input/controller.h | 2 -- src/input/input.cpp | 6 +--- src/input/input.h | 2 -- src/input/input_internal.h | 2 -- src/light.cpp | 6 +--- src/lol/{main.h => engine-internal.h} | 7 ++++- src/lol/engine.h | 27 +++++++++++------- src/lol/public.h | 28 +++++++++++++++++++ src/lolcore.vcxproj | 3 +- src/lolcore.vcxproj.filters | 5 +++- src/math/constants.cpp | 6 +--- src/math/geometry.cpp | 6 +--- src/math/half.cpp | 6 +--- src/math/matrix.cpp | 6 +--- src/math/real.cpp | 6 +--- src/math/transform.cpp | 6 +--- src/math/trig.cpp | 6 +--- src/math/vector.cpp | 6 +--- src/mesh/mesh.cpp | 6 +--- src/mesh/primitive.cpp | 6 +--- src/messageservice.cpp | 6 +--- src/platform.cpp | 6 +--- src/platform/android/androidapp.cpp | 5 +--- src/platform/d3d9/d3d9input.cpp | 5 +--- src/platform/nacl/nacl-app.cpp | 6 +--- src/platform/nacl/nacl-instance.cpp | 6 +--- src/platform/nacl/nacl-module.cpp | 5 +--- src/platform/nacl/opengl_context.cpp | 6 +--- src/platform/ps3/ps3app.cpp | 5 +--- src/platform/ps3/ps3input.cpp | 5 +--- src/platform/sdl/sdlapp.cpp | 5 +--- src/platform/sdl/sdlinput.cpp | 5 +--- src/platform/xbox/xboxapp.cpp | 5 +--- src/platform/xbox/xboxinput.cpp | 5 +--- src/profiler.cpp | 6 +--- src/sample.cpp | 6 +--- src/sampler.cpp | 6 +--- src/scene.cpp | 5 +--- src/sprite.cpp | 6 +--- src/sys/file.cpp | 6 +--- src/sys/init.cpp | 6 +--- src/sys/thread.cpp | 6 +--- src/sys/timer.cpp | 6 +--- src/t/base/array.cpp | 5 +--- src/t/base/enum.cpp | 5 +--- src/t/base/map.cpp | 5 +--- src/t/base/string.cpp | 5 +--- src/t/base/types.cpp | 5 +--- src/t/entity/camera.cpp | 5 +--- src/t/image/color.cpp | 5 +--- src/t/image/image.cpp | 5 +--- src/t/math/array2d.cpp | 5 +--- src/t/math/array3d.cpp | 5 +--- src/t/math/arraynd.cpp | 5 +--- src/t/math/box.cpp | 5 +--- src/t/math/cmplx.cpp | 5 +--- src/t/math/half.cpp | 5 +--- src/t/math/interp.cpp | 5 +--- src/t/math/matrix.cpp | 5 +--- src/t/math/quat.cpp | 5 +--- src/t/math/rand.cpp | 5 +--- src/t/math/real.cpp | 5 +--- src/t/math/rotation.cpp | 5 +--- src/t/math/trig.cpp | 5 +--- src/t/math/vector.cpp | 5 +--- src/t/sys/thread.cpp | 5 +--- src/t/test-common.cpp | 6 +--- src/text.cpp | 6 +--- src/ticker.cpp | 6 +--- src/tiler.cpp | 6 +--- src/tileset.cpp | 6 +--- src/video.cpp | 5 +--- src/world.cpp | 6 +--- src/worldentity.cpp | 6 +--- tools/lolremez/lolremez.cpp | 4 +-- tools/lolremez/solver.cpp | 4 +-- tools/make-font.cpp | 2 +- 179 files changed, 256 insertions(+), 686 deletions(-) rename src/lol/{main.h => engine-internal.h} (87%) create mode 100644 src/lol/public.h diff --git a/demos/test/benchmark/half.cpp b/demos/test/benchmark/half.cpp index 6f6b360d..13e816a0 100644 --- a/demos/test/benchmark/half.cpp +++ b/demos/test/benchmark/half.cpp @@ -8,13 +8,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif #include -#include +#include using namespace lol; diff --git a/demos/test/benchmark/real.cpp b/demos/test/benchmark/real.cpp index 8623796c..1e6b4924 100644 --- a/demos/test/benchmark/real.cpp +++ b/demos/test/benchmark/real.cpp @@ -8,13 +8,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif #include -#include +#include using namespace lol; diff --git a/demos/test/benchmark/trig.cpp b/demos/test/benchmark/trig.cpp index 538f14bc..0d08b0c3 100644 --- a/demos/test/benchmark/trig.cpp +++ b/demos/test/benchmark/trig.cpp @@ -18,7 +18,7 @@ # include #endif -#include +#include using namespace lol; diff --git a/demos/test/benchmark/vector.cpp b/demos/test/benchmark/vector.cpp index ac194073..2669184b 100644 --- a/demos/test/benchmark/vector.cpp +++ b/demos/test/benchmark/vector.cpp @@ -8,13 +8,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif #include -#include +#include using namespace lol; diff --git a/demos/test/benchsuite.cpp b/demos/test/benchsuite.cpp index 48ffb8a8..1087555f 100644 --- a/demos/test/benchsuite.cpp +++ b/demos/test/benchsuite.cpp @@ -8,13 +8,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif #include -#include +#include using namespace lol; diff --git a/demos/test/btphystest.cpp b/demos/test/btphystest.cpp index 2baf1bfd..51af0c6f 100644 --- a/demos/test/btphystest.cpp +++ b/demos/test/btphystest.cpp @@ -5,11 +5,11 @@ // (c) 2012-2013 Sam Hocevar // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include "loldebug.h" using namespace lol; diff --git a/demos/test/generated/scenesetup-parser.cpp b/demos/test/generated/scenesetup-parser.cpp index e301e0fc..6c87b243 100644 --- a/demos/test/generated/scenesetup-parser.cpp +++ b/demos/test/generated/scenesetup-parser.cpp @@ -49,11 +49,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include "../scenesetup.h" diff --git a/demos/test/generated/scenesetup-scanner.cpp b/demos/test/generated/scenesetup-scanner.cpp index 991d79fc..5c60c681 100644 --- a/demos/test/generated/scenesetup-scanner.cpp +++ b/demos/test/generated/scenesetup-scanner.cpp @@ -494,7 +494,7 @@ static yyconst flex_int16_t yy_chk[180] = // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif @@ -504,7 +504,7 @@ using std::malloc; using std::realloc; using std::free; -#include +#include #include "../scenesetup.h" #include "../scenesetup-compiler.h" diff --git a/demos/test/math/pi.cpp b/demos/test/math/pi.cpp index 49e5df0c..e3ec6070 100644 --- a/demos/test/math/pi.cpp +++ b/demos/test/math/pi.cpp @@ -8,13 +8,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif #include -#include +#include using std::printf; using std::sqrt; diff --git a/demos/test/math/poly.cpp b/demos/test/math/poly.cpp index 38b9501f..111b8b4f 100644 --- a/demos/test/math/poly.cpp +++ b/demos/test/math/poly.cpp @@ -8,13 +8,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif #include -#include +#include using namespace lol; diff --git a/demos/test/meshviewer.cpp b/demos/test/meshviewer.cpp index 90afc778..6ecb5b7b 100644 --- a/demos/test/meshviewer.cpp +++ b/demos/test/meshviewer.cpp @@ -10,13 +10,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif #include /* for FLT_MAX */ -#include +#include #include "scenesetup.h" using namespace lol; diff --git a/demos/test/nacl_phystest.cpp b/demos/test/nacl_phystest.cpp index b9f77d9a..fd30bec8 100644 --- a/demos/test/nacl_phystest.cpp +++ b/demos/test/nacl_phystest.cpp @@ -5,11 +5,11 @@ // (c) 2012-2013 Sam Hocevar // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include "loldebug.h" using namespace lol; diff --git a/demos/test/physicobject.h b/demos/test/physicobject.h index 99c2c926..fc9f06d0 100644 --- a/demos/test/physicobject.h +++ b/demos/test/physicobject.h @@ -11,7 +11,7 @@ #if !defined __PHYSICOBJECT_H__ #define __PHYSICOBJECT_H__ -#include +#include #include "easymesh/easymesh.h" #include "physics/easyphysics.h" #include "physics/easycharactercontroller.h" diff --git a/demos/test/physics/bulletcharactercontroller.cpp b/demos/test/physics/bulletcharactercontroller.cpp index 5fa978dd..e5673a76 100644 --- a/demos/test/physics/bulletcharactercontroller.cpp +++ b/demos/test/physics/bulletcharactercontroller.cpp @@ -10,13 +10,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif #define USE_LOL_CTRLR_CHARAC -#include +#include #include #include "lolbtphysicsintegration.h" #include "lolphysics.h" diff --git a/demos/test/physics/bulletcharactercontroller.h b/demos/test/physics/bulletcharactercontroller.h index 8b89c5a3..9bced33d 100644 --- a/demos/test/physics/bulletcharactercontroller.h +++ b/demos/test/physics/bulletcharactercontroller.h @@ -18,7 +18,7 @@ #if !defined __BULLETCHARACTERCONTROLLER_BULLETCHARACTERCONTROLLER_H__ #define __BULLETCHARACTERCONTROLLER_BULLETCHARACTERCONTROLLER_H__ -#include +#include #include "easyphysics.h" //#include "BulletDynamics\Character\btCharacterControllerInterface.h" diff --git a/demos/test/physics/easycharactercontroller.cpp b/demos/test/physics/easycharactercontroller.cpp index 7d389c07..6b2600f3 100644 --- a/demos/test/physics/easycharactercontroller.cpp +++ b/demos/test/physics/easycharactercontroller.cpp @@ -10,7 +10,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif diff --git a/demos/test/physics/easycharactercontroller.h b/demos/test/physics/easycharactercontroller.h index bb080e7c..bcee71da 100644 --- a/demos/test/physics/easycharactercontroller.h +++ b/demos/test/physics/easycharactercontroller.h @@ -20,7 +20,7 @@ #if !defined __EASYCHARACTERCONTROLLER_EASYCHARACTERCONTROLLER_H__ #define __EASYCHARACTERCONTROLLER_EASYCHARACTERCONTROLLER_H__ -#include +#include #include "easyphysics.h" #include "bulletcharactercontroller.h" #include diff --git a/demos/test/physics/easyconstraint.cpp b/demos/test/physics/easyconstraint.cpp index e90ebf89..1d8ca76a 100644 --- a/demos/test/physics/easyconstraint.cpp +++ b/demos/test/physics/easyconstraint.cpp @@ -1,5 +1,5 @@ -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif diff --git a/demos/test/physics/easyconstraint.h b/demos/test/physics/easyconstraint.h index 80379b49..871d5bfb 100644 --- a/demos/test/physics/easyconstraint.h +++ b/demos/test/physics/easyconstraint.h @@ -17,7 +17,7 @@ #if !defined __EASYCONSTRAINT_EASYCONSTRAINT_H__ #define __EASYCONSTRAINT_EASYCONSTRAINT_H__ -#include +#include #include "easyphysics.h" namespace lol diff --git a/demos/test/physics/easyphysics.cpp b/demos/test/physics/easyphysics.cpp index 99ca411a..eedb9dc2 100644 --- a/demos/test/physics/easyphysics.cpp +++ b/demos/test/physics/easyphysics.cpp @@ -10,7 +10,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif diff --git a/demos/test/physics/easyphysics.h b/demos/test/physics/easyphysics.h index 7099df2f..fb980899 100644 --- a/demos/test/physics/easyphysics.h +++ b/demos/test/physics/easyphysics.h @@ -17,7 +17,7 @@ #if !defined __EASYPHYSICS_EASYPHYSICS_H__ #define __EASYPHYSICS_EASYPHYSICS_H__ -#include +#include #include #include #include diff --git a/demos/test/sandbox/sample.cpp b/demos/test/sandbox/sample.cpp index 68d536a1..9bb159f7 100644 --- a/demos/test/sandbox/sample.cpp +++ b/demos/test/sandbox/sample.cpp @@ -8,11 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include using namespace lol; diff --git a/demos/test/scenesetup-compiler.cpp b/demos/test/scenesetup-compiler.cpp index 3232d0f0..d72b8caf 100644 --- a/demos/test/scenesetup-compiler.cpp +++ b/demos/test/scenesetup-compiler.cpp @@ -9,13 +9,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif #include -#include +#include #include "scenesetup.h" #include "scenesetup-compiler.h" diff --git a/demos/test/scenesetup.cpp b/demos/test/scenesetup.cpp index 33562793..8acdcbae 100644 --- a/demos/test/scenesetup.cpp +++ b/demos/test/scenesetup.cpp @@ -9,11 +9,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include "scenesetup.h" #include "scenesetup-compiler.h" diff --git a/demos/tutorial/01_triangle.cpp b/demos/tutorial/01_triangle.cpp index c767e0ad..2cc5d872 100644 --- a/demos/tutorial/01_triangle.cpp +++ b/demos/tutorial/01_triangle.cpp @@ -8,11 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include "loldebug.h" using namespace lol; diff --git a/demos/tutorial/02_cube.cpp b/demos/tutorial/02_cube.cpp index 9a615de5..38f9db56 100644 --- a/demos/tutorial/02_cube.cpp +++ b/demos/tutorial/02_cube.cpp @@ -8,11 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include "loldebug.h" using namespace lol; diff --git a/demos/tutorial/03_noise.cpp b/demos/tutorial/03_noise.cpp index 41ae0ea1..bc105d78 100644 --- a/demos/tutorial/03_noise.cpp +++ b/demos/tutorial/03_noise.cpp @@ -8,11 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include "loldebug.h" using namespace lol; diff --git a/demos/tutorial/04_texture.cpp b/demos/tutorial/04_texture.cpp index b6a1eab7..4595058a 100644 --- a/demos/tutorial/04_texture.cpp +++ b/demos/tutorial/04_texture.cpp @@ -8,11 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include "loldebug.h" using namespace lol; diff --git a/demos/tutorial/05_easymesh.cpp b/demos/tutorial/05_easymesh.cpp index 36ce418b..c1b4987a 100644 --- a/demos/tutorial/05_easymesh.cpp +++ b/demos/tutorial/05_easymesh.cpp @@ -9,11 +9,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include using namespace lol; diff --git a/demos/tutorial/06_sprite.cpp b/demos/tutorial/06_sprite.cpp index 1f3306fb..7ef0f354 100644 --- a/demos/tutorial/06_sprite.cpp +++ b/demos/tutorial/06_sprite.cpp @@ -9,11 +9,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include using namespace lol; diff --git a/demos/tutorial/07_input.cpp b/demos/tutorial/07_input.cpp index 147cd5e2..17e52017 100644 --- a/demos/tutorial/07_input.cpp +++ b/demos/tutorial/07_input.cpp @@ -8,11 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include "loldebug.h" using namespace lol; diff --git a/demos/tutorial/08_fbo.cpp b/demos/tutorial/08_fbo.cpp index 1fc76bd1..64e127e6 100644 --- a/demos/tutorial/08_fbo.cpp +++ b/demos/tutorial/08_fbo.cpp @@ -8,11 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include "loldebug.h" using namespace lol; diff --git a/demos/tutorial/11_fractal.cpp b/demos/tutorial/11_fractal.cpp index 6a94ff1a..272a0f6a 100644 --- a/demos/tutorial/11_fractal.cpp +++ b/demos/tutorial/11_fractal.cpp @@ -8,14 +8,14 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif #include #include -#include +#include #include "loldebug.h" using namespace lol; diff --git a/demos/tutorial/12_voronoi.cpp b/demos/tutorial/12_voronoi.cpp index 051de2ca..f01b5164 100644 --- a/demos/tutorial/12_voronoi.cpp +++ b/demos/tutorial/12_voronoi.cpp @@ -9,11 +9,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include "loldebug.h" using namespace lol; diff --git a/src/Makefile.am b/src/Makefile.am index 4775e474..54f07269 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -26,13 +26,14 @@ liblolcore_a_SOURCES = \ $(sdl_sources) \ $(d3d9_sources) \ $(android_sources) +#liblolcore_a_CPPFLAGS = -include-pch $(srcdir)/lol/engine-internal.h.pch $(AM_CPPFLAGS) -I$(srcdir)/bullet -I$(srcdir)/lua liblolcore_a_CPPFLAGS = $(AM_CPPFLAGS) -I$(srcdir)/bullet -I$(srcdir)/lua EXTRA_DIST += easymesh/easymesh-scanner.l easymesh/easymesh-parser.y \ gpu/lolfx-scanner.l gpu/lolfx-parser.y liblolcore_headers = \ - lol/main.h lol/engine.h lol/extras.h \ + lol/engine-internal.h lol/engine.h lol/public.h lol/extras.h \ \ lol/base/all.h \ lol/base/features.h lol/base/tuple.h lol/base/types.h lol/base/array.h \ diff --git a/src/application/application.cpp b/src/application/application.cpp index 853d308a..b95d5478 100644 --- a/src/application/application.cpp +++ b/src/application/application.cpp @@ -8,16 +8,12 @@ // http://www.wtfpl.net/ for more details. // -#if HAVE_CONFIG_H -# include "config.h" -#endif +#include #if HAVE_EMSCRIPTEN_H # include #endif -#include - #include "lolgl.h" #if __CELLOS_LV2__ diff --git a/src/audio.cpp b/src/audio.cpp index 07acd10f..7af02e24 100644 --- a/src/audio.cpp +++ b/src/audio.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined USE_SDL_MIXER # if defined HAVE_SDL_SDL_H @@ -25,8 +23,6 @@ # endif #endif -#include - namespace lol { diff --git a/src/base/assert.cpp b/src/base/assert.cpp index aad0c0da..6a5790dc 100644 --- a/src/base/assert.cpp +++ b/src/base/assert.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if HAVE_CONFIG_H -# include "config.h" -#endif +#include #if HAVE_CXXABI_H # include @@ -23,8 +21,6 @@ # include #endif -#include - namespace lol { diff --git a/src/base/enum.cpp b/src/base/enum.cpp index f47d3d87..2277516f 100644 --- a/src/base/enum.cpp +++ b/src/base/enum.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/base/hash.cpp b/src/base/hash.cpp index e6809278..122ab4af 100644 --- a/src/base/hash.cpp +++ b/src/base/hash.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/base/log.cpp b/src/base/log.cpp index 2eecb2f8..69a04d08 100644 --- a/src/base/log.cpp +++ b/src/base/log.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined(HAVE_CONFIG_H) -# include "config.h" -#endif +#include #include @@ -26,8 +24,6 @@ # include #endif -#include - namespace lol { diff --git a/src/base/string.cpp b/src/base/string.cpp index f0bc6625..fd0b7ee5 100644 --- a/src/base/string.cpp +++ b/src/base/string.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if HAVE_CONFIG_H -# include "config.h" -#endif +#include #include @@ -21,8 +19,6 @@ #include -#include - namespace lol { diff --git a/src/camera.cpp b/src/camera.cpp index 8d895fe8..9be3d593 100644 --- a/src/camera.cpp +++ b/src/camera.cpp @@ -9,15 +9,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include -#include - #if defined _WIN32 || defined _XBOX # define strcasecmp _stricmp # undef near diff --git a/src/debug/fps.cpp b/src/debug/fps.cpp index e3ebb96d..1f91bc3b 100644 --- a/src/debug/fps.cpp +++ b/src/debug/fps.cpp @@ -8,13 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include #include "loldebug.h" namespace lol diff --git a/src/debug/lines.cpp b/src/debug/lines.cpp index 958def94..7176b0ae 100644 --- a/src/debug/lines.cpp +++ b/src/debug/lines.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/debug/record.cpp b/src/debug/record.cpp index da8ef9f9..add3fca9 100644 --- a/src/debug/record.cpp +++ b/src/debug/record.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include @@ -18,7 +16,6 @@ # include #endif -#include #include "loldebug.h" namespace lol diff --git a/src/debug/stats.cpp b/src/debug/stats.cpp index 4dbb1b14..258f8103 100644 --- a/src/debug/stats.cpp +++ b/src/debug/stats.cpp @@ -8,13 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include #include "loldebug.h" namespace lol diff --git a/src/dict.cpp b/src/dict.cpp index d88be7ac..e456831f 100644 --- a/src/dict.cpp +++ b/src/dict.cpp @@ -8,15 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include -#include - #if defined _WIN32 || defined _XBOX # define strcasecmp _stricmp #endif diff --git a/src/easymesh/csgbsp.cpp b/src/easymesh/csgbsp.cpp index 1ef14f17..4d2df04e 100644 --- a/src/easymesh/csgbsp.cpp +++ b/src/easymesh/csgbsp.cpp @@ -14,12 +14,7 @@ // ------------------ // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include -#include +#include namespace lol { diff --git a/src/easymesh/easymesh-compiler.cpp b/src/easymesh/easymesh-compiler.cpp index 5eff8549..8cde04d3 100644 --- a/src/easymesh/easymesh-compiler.cpp +++ b/src/easymesh/easymesh-compiler.cpp @@ -10,13 +10,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include #include "easymesh/easymesh-compiler.h" namespace lol diff --git a/src/easymesh/easymesh.cpp b/src/easymesh/easymesh.cpp index d2569903..63dcb8c2 100644 --- a/src/easymesh/easymesh.cpp +++ b/src/easymesh/easymesh.cpp @@ -15,11 +15,8 @@ // ------------------ // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "easymesh/easymesh-compiler.h" LOLFX_RESOURCE_DECLARE(shiny); diff --git a/src/easymesh/easymeshbuild.cpp b/src/easymesh/easymeshbuild.cpp index 8056a112..fe284d71 100644 --- a/src/easymesh/easymeshbuild.cpp +++ b/src/easymesh/easymeshbuild.cpp @@ -15,11 +15,7 @@ // ------------------ // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/easymesh/easymeshrender.cpp b/src/easymesh/easymeshrender.cpp index 8b330c46..26351aad 100644 --- a/src/easymesh/easymeshrender.cpp +++ b/src/easymesh/easymeshrender.cpp @@ -15,11 +15,7 @@ // ------------------ // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/eglapp.cpp b/src/eglapp.cpp index 11e7227a..cf5664f1 100644 --- a/src/eglapp.cpp +++ b/src/eglapp.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined USE_EGL && !defined __ANDROID__ # if defined HAVE_BCM_HOST_H @@ -32,7 +30,6 @@ # endif #endif -#include #include "lolgl.h" #include "eglapp.h" #if defined USE_SDL diff --git a/src/emitter.cpp b/src/emitter.cpp index 2b3a8ab0..4976efef 100644 --- a/src/emitter.cpp +++ b/src/emitter.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/entity.cpp b/src/entity.cpp index 714220c6..0c7627a6 100644 --- a/src/entity.cpp +++ b/src/entity.cpp @@ -8,14 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include - namespace lol { diff --git a/src/font.cpp b/src/font.cpp index e565fae8..708d5ffd 100644 --- a/src/font.cpp +++ b/src/font.cpp @@ -9,15 +9,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include -#include - namespace lol { diff --git a/src/forge.cpp b/src/forge.cpp index 023e1b61..0fc8d202 100644 --- a/src/forge.cpp +++ b/src/forge.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/generated/easymesh-parser.cpp b/src/generated/easymesh-parser.cpp index c8147853..1e9a984d 100644 --- a/src/generated/easymesh-parser.cpp +++ b/src/generated/easymesh-parser.cpp @@ -50,11 +50,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "easymesh/easymesh.h" #include diff --git a/src/generated/easymesh-scanner.cpp b/src/generated/easymesh-scanner.cpp index 1955469b..34f8af95 100644 --- a/src/generated/easymesh-scanner.cpp +++ b/src/generated/easymesh-scanner.cpp @@ -658,9 +658,7 @@ static yyconst flex_int16_t yy_chk[502] = // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include using std::exit; @@ -668,7 +666,6 @@ using std::malloc; using std::realloc; using std::free; -#include #include "easymesh/easymesh-compiler.h" typedef lol::EasyMeshParser::token token; diff --git a/src/generated/lolfx-parser.cpp b/src/generated/lolfx-parser.cpp index 942a30c7..1bb4e847 100644 --- a/src/generated/lolfx-parser.cpp +++ b/src/generated/lolfx-parser.cpp @@ -48,11 +48,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include #include diff --git a/src/generated/lolfx-scanner.cpp b/src/generated/lolfx-scanner.cpp index 35938cc8..9f9e1ce9 100644 --- a/src/generated/lolfx-scanner.cpp +++ b/src/generated/lolfx-scanner.cpp @@ -1661,9 +1661,7 @@ static yyconst flex_int16_t yy_chk[3114] = // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include using std::exit; @@ -1672,7 +1670,6 @@ using std::realloc; using std::free; #include -#include #include "gpu/lolfx-compiler.h" typedef lol::LolFxParser::token token; diff --git a/src/gpu/framebuffer.cpp b/src/gpu/framebuffer.cpp index 251ac618..3d61a98c 100644 --- a/src/gpu/framebuffer.cpp +++ b/src/gpu/framebuffer.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "lolgl.h" #if defined _WIN32 && defined USE_D3D9 diff --git a/src/gpu/indexbuffer.cpp b/src/gpu/indexbuffer.cpp index d69b3c7b..287fea38 100644 --- a/src/gpu/indexbuffer.cpp +++ b/src/gpu/indexbuffer.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "lolgl.h" #if defined _WIN32 && defined USE_D3D9 diff --git a/src/gpu/lolfx-compiler.cpp b/src/gpu/lolfx-compiler.cpp index 57c2ab28..98d6bc2b 100644 --- a/src/gpu/lolfx-compiler.cpp +++ b/src/gpu/lolfx-compiler.cpp @@ -8,13 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include #include "gpu/lolfx-compiler.h" namespace lol diff --git a/src/gpu/lolfx.cpp b/src/gpu/lolfx.cpp index 881369a8..daa8bde7 100644 --- a/src/gpu/lolfx.cpp +++ b/src/gpu/lolfx.cpp @@ -13,11 +13,8 @@ // --------------- // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "gpu/lolfx-compiler.h" namespace lol diff --git a/src/gpu/rendercontext.cpp b/src/gpu/rendercontext.cpp index 8ecf2fc7..224ef423 100644 --- a/src/gpu/rendercontext.cpp +++ b/src/gpu/rendercontext.cpp @@ -8,14 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include - namespace lol { diff --git a/src/gpu/renderer.cpp b/src/gpu/renderer.cpp index d2e36a4a..9fb16309 100644 --- a/src/gpu/renderer.cpp +++ b/src/gpu/renderer.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include @@ -28,7 +26,6 @@ # undef far /* Fuck Microsoft again */ #endif -#include #include "lolgl.h" /* FIXME: find a way to pass g_hwnd from the windowing system */ diff --git a/src/gpu/shader.cpp b/src/gpu/shader.cpp index deed9b30..7d696791 100644 --- a/src/gpu/shader.cpp +++ b/src/gpu/shader.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include @@ -31,7 +29,6 @@ # undef far /* Fuck Microsoft again */ #endif -#include #include "lolgl.h" namespace lol diff --git a/src/gpu/texture.cpp b/src/gpu/texture.cpp index 24d215db..a4a7c21f 100644 --- a/src/gpu/texture.cpp +++ b/src/gpu/texture.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "lolgl.h" #if defined _WIN32 && defined USE_D3D9 diff --git a/src/gpu/vertexbuffer.cpp b/src/gpu/vertexbuffer.cpp index 3ccef66d..9d256ec5 100644 --- a/src/gpu/vertexbuffer.cpp +++ b/src/gpu/vertexbuffer.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "lolgl.h" #if defined _WIN32 && defined USE_D3D9 diff --git a/src/gradient.cpp b/src/gradient.cpp index 98c08ff8..25aabb14 100644 --- a/src/gradient.cpp +++ b/src/gradient.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include LOLFX_RESOURCE_DECLARE(gradient); diff --git a/src/image/codec/android-image.cpp b/src/image/codec/android-image.cpp index c5f9d068..9b1c2ea0 100644 --- a/src/image/codec/android-image.cpp +++ b/src/image/codec/android-image.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined __ANDROID__ @@ -21,7 +19,6 @@ extern "C" { #include } -#include #include "../../image/image-private.h" namespace lol diff --git a/src/image/codec/dummy-image.cpp b/src/image/codec/dummy-image.cpp index a107ee3e..16ac8049 100644 --- a/src/image/codec/dummy-image.cpp +++ b/src/image/codec/dummy-image.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "../../image/image-private.h" namespace lol diff --git a/src/image/codec/gdiplus-image.cpp b/src/image/codec/gdiplus-image.cpp index 9248ecb2..d9092256 100644 --- a/src/image/codec/gdiplus-image.cpp +++ b/src/image/codec/gdiplus-image.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined USE_GDIPLUS @@ -21,7 +19,6 @@ using std::max; #include #include -#include #include "../../image/image-private.h" namespace lol diff --git a/src/image/codec/imlib2-image.cpp b/src/image/codec/imlib2-image.cpp index 771bcd67..8a0201db 100644 --- a/src/image/codec/imlib2-image.cpp +++ b/src/image/codec/imlib2-image.cpp @@ -8,15 +8,12 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined USE_IMLIB2 #include -#include #include "../../image/image-private.h" namespace lol diff --git a/src/image/codec/ios-image.cpp b/src/image/codec/ios-image.cpp index 1c594343..c9e158a8 100644 --- a/src/image/codec/ios-image.cpp +++ b/src/image/codec/ios-image.cpp @@ -8,15 +8,12 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined __APPLE__ && defined __MACH__ && defined __arm__ #import -#include #include "../../image/image-private.h" namespace lol diff --git a/src/image/codec/oric-image.cpp b/src/image/codec/oric-image.cpp index e6f09fb9..df5a60c5 100644 --- a/src/image/codec/oric-image.cpp +++ b/src/image/codec/oric-image.cpp @@ -8,13 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include #include "../../image/image-private.h" namespace lol diff --git a/src/image/codec/ps3-image.cpp b/src/image/codec/ps3-image.cpp index 142c5002..1fcb97af 100644 --- a/src/image/codec/ps3-image.cpp +++ b/src/image/codec/ps3-image.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined __CELLOS_LV2__ @@ -18,7 +16,6 @@ #include #include -#include #include "../../image/image-private.h" namespace lol diff --git a/src/image/codec/sdl-image.cpp b/src/image/codec/sdl-image.cpp index eafcf82b..a20ca0a7 100644 --- a/src/image/codec/sdl-image.cpp +++ b/src/image/codec/sdl-image.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined USE_SDL_IMAGE @@ -25,7 +23,6 @@ # include #endif -#include #include "../../image/image-private.h" namespace lol diff --git a/src/image/codec/zed-image.cpp b/src/image/codec/zed-image.cpp index ba12b826..2e48d889 100644 --- a/src/image/codec/zed-image.cpp +++ b/src/image/codec/zed-image.cpp @@ -9,11 +9,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "../../image/image-private.h" namespace lol diff --git a/src/image/codec/zed-palette-image.cpp b/src/image/codec/zed-palette-image.cpp index f79637b2..882a52b7 100644 --- a/src/image/codec/zed-palette-image.cpp +++ b/src/image/codec/zed-palette-image.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "../../image/image-private.h" namespace lol diff --git a/src/image/color/cie1931.cpp b/src/image/color/cie1931.cpp index dbc6e5ab..423203c2 100644 --- a/src/image/color/cie1931.cpp +++ b/src/image/color/cie1931.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * This file contains code and data related to various CIE standards. diff --git a/src/image/color/color.cpp b/src/image/color/color.cpp index 2c2c4e21..e3e726aa 100644 --- a/src/image/color/color.cpp +++ b/src/image/color/color.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/image/combine.cpp b/src/image/combine.cpp index f6e7bffd..8fff377c 100644 --- a/src/image/combine.cpp +++ b/src/image/combine.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Image merge operations: merge, min/max, overlay, screen, multiply, diff --git a/src/image/crop.cpp b/src/image/crop.cpp index 312ff71f..ab3afeed 100644 --- a/src/image/crop.cpp +++ b/src/image/crop.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "image-private.h" /* diff --git a/src/image/dither/dbs.cpp b/src/image/dither/dbs.cpp index 6125b338..ffc1d0e9 100644 --- a/src/image/dither/dbs.cpp +++ b/src/image/dither/dbs.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Direct Binary Search dithering diff --git a/src/image/dither/ediff.cpp b/src/image/dither/ediff.cpp index bc411fe0..40e80398 100644 --- a/src/image/dither/ediff.cpp +++ b/src/image/dither/ediff.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Generic error diffusion functions diff --git a/src/image/dither/ordered.cpp b/src/image/dither/ordered.cpp index f8c960d0..85f1e04e 100644 --- a/src/image/dither/ordered.cpp +++ b/src/image/dither/ordered.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Bayer ordered dithering functions diff --git a/src/image/dither/ostromoukhov.cpp b/src/image/dither/ostromoukhov.cpp index 9f886e7d..613be14e 100644 --- a/src/image/dither/ostromoukhov.cpp +++ b/src/image/dither/ostromoukhov.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Ostromoukhov dithering functions diff --git a/src/image/dither/random.cpp b/src/image/dither/random.cpp index 3d6e7be4..967d408a 100644 --- a/src/image/dither/random.cpp +++ b/src/image/dither/random.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Random dithering diff --git a/src/image/filter/color.cpp b/src/image/filter/color.cpp index 0f36cbbf..78088248 100644 --- a/src/image/filter/color.cpp +++ b/src/image/filter/color.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Colour manipulation functions diff --git a/src/image/filter/convolution.cpp b/src/image/filter/convolution.cpp index ba3cb72d..3b0298d2 100644 --- a/src/image/filter/convolution.cpp +++ b/src/image/filter/convolution.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Generic convolution functions diff --git a/src/image/filter/dilate.cpp b/src/image/filter/dilate.cpp index 2991bd1a..3c4cd040 100644 --- a/src/image/filter/dilate.cpp +++ b/src/image/filter/dilate.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Dilate and erode functions diff --git a/src/image/filter/median.cpp b/src/image/filter/median.cpp index bdd83dea..263aa67b 100644 --- a/src/image/filter/median.cpp +++ b/src/image/filter/median.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Median filter functions diff --git a/src/image/filter/yuv.cpp b/src/image/filter/yuv.cpp index 0df2a56f..063dc8d3 100644 --- a/src/image/filter/yuv.cpp +++ b/src/image/filter/yuv.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * YUV conversion functions diff --git a/src/image/image.cpp b/src/image/image.cpp index 6350dc9e..381755cd 100644 --- a/src/image/image.cpp +++ b/src/image/image.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "image-private.h" #include /* for std::swap */ diff --git a/src/image/kernel.cpp b/src/image/kernel.cpp index d6773950..fa9635fc 100644 --- a/src/image/kernel.cpp +++ b/src/image/kernel.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Stock kernels diff --git a/src/image/noise.cpp b/src/image/noise.cpp index d2572feb..0f6dc8b4 100644 --- a/src/image/noise.cpp +++ b/src/image/noise.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Noise rendering functions diff --git a/src/image/pixel.cpp b/src/image/pixel.cpp index 7eb3cf0c..409527b6 100644 --- a/src/image/pixel.cpp +++ b/src/image/pixel.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include "image-private.h" namespace lol diff --git a/src/image/resample.cpp b/src/image/resample.cpp index 6b594ad2..9aef4225 100644 --- a/src/image/resample.cpp +++ b/src/image/resample.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include /* * Image resizing functions diff --git a/src/input/controller.cpp b/src/input/controller.cpp index ef0ec821..913c1432 100644 --- a/src/input/controller.cpp +++ b/src/input/controller.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/input/controller.h b/src/input/controller.h index 21c0dea4..8d8ebccc 100644 --- a/src/input/controller.h +++ b/src/input/controller.h @@ -11,8 +11,6 @@ #if !defined __LOL_INPUT_CONTROLLER_H__ #define __LOL_INPUT_CONTROLLER_H__ -#include - namespace lol { diff --git a/src/input/input.cpp b/src/input/input.cpp index c34fe9f3..30acfa5d 100644 --- a/src/input/input.cpp +++ b/src/input/input.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include #include "input/input_internal.h" diff --git a/src/input/input.h b/src/input/input.h index 4a8fbeb2..da977890 100644 --- a/src/input/input.h +++ b/src/input/input.h @@ -11,8 +11,6 @@ #if !defined __LOL_INPUT_H__ #define __LOL_INPUT_H__ -#include - namespace lol { diff --git a/src/input/input_internal.h b/src/input/input_internal.h index 4a32cd3d..c67c01fb 100644 --- a/src/input/input_internal.h +++ b/src/input/input_internal.h @@ -11,8 +11,6 @@ #if !defined __LOL_INPUT_DEVICE_INTERNAL_H__ #define __LOL_INPUT_DEVICE_H__ -#include - namespace lol { diff --git a/src/light.cpp b/src/light.cpp index 003c2389..db1d3446 100644 --- a/src/light.cpp +++ b/src/light.cpp @@ -8,15 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include -#include - namespace lol { diff --git a/src/lol/main.h b/src/lol/engine-internal.h similarity index 87% rename from src/lol/main.h rename to src/lol/engine-internal.h index b8dd22a9..a6ccdcbe 100644 --- a/src/lol/main.h +++ b/src/lol/engine-internal.h @@ -16,6 +16,11 @@ #if !defined __LOL_MAIN_H__ #define __LOL_MAIN_H__ +/* Include this as early as possible */ +#if defined HAVE_CONFIG_H +# include "config.h" +#endif + /* If using NaCl or Android, override main() with our version */ #if defined __native_client__ # define main lol_nacl_main @@ -28,7 +33,7 @@ # include #endif -#include +#include #include #endif // __LOL_MAIN_H__ diff --git a/src/lol/engine.h b/src/lol/engine.h index 2c12bb37..2c662e91 100644 --- a/src/lol/engine.h +++ b/src/lol/engine.h @@ -13,16 +13,23 @@ // --------------- // -#if !defined __LOL_ENGINE_H__ -#define __LOL_ENGINE_H__ +#if !defined __LOL_MAIN_H__ +#define __LOL_MAIN_H__ -#include -#include -#include -#include -#include -#include -#include +/* If using NaCl or Android, override main() with our version */ +#if defined __native_client__ +# define main lol_nacl_main +#elif defined __ANDROID__ +# define main lol_android_main +#endif -#endif // __LOL_ENGINE_H__ +/* If using SDL on Windows or OS X, let it override main() */ +#if defined USE_SDL && (defined _WIN32 || defined __APPLE__) +# include +#endif + +#include +#include + +#endif // __LOL_MAIN_H__ diff --git a/src/lol/public.h b/src/lol/public.h new file mode 100644 index 00000000..2c12bb37 --- /dev/null +++ b/src/lol/public.h @@ -0,0 +1,28 @@ +// +// Lol Engine +// +// Copyright: (c) 2010-2014 Sam Hocevar +// This program is free software; you can redistribute it and/or +// modify it under the terms of the Do What The Fuck You Want To +// Public License, Version 2, as published by Sam Hocevar. See +// http://www.wtfpl.net/ for more details. +// + +// +// The main header +// --------------- +// + +#if !defined __LOL_ENGINE_H__ +#define __LOL_ENGINE_H__ + +#include +#include +#include +#include +#include +#include +#include + +#endif // __LOL_ENGINE_H__ + diff --git a/src/lolcore.vcxproj b/src/lolcore.vcxproj index 89eef19e..b4c5710a 100644 --- a/src/lolcore.vcxproj +++ b/src/lolcore.vcxproj @@ -306,6 +306,7 @@ + @@ -320,7 +321,6 @@ - @@ -336,6 +336,7 @@ + diff --git a/src/lolcore.vcxproj.filters b/src/lolcore.vcxproj.filters index 99c97166..b56b56e5 100644 --- a/src/lolcore.vcxproj.filters +++ b/src/lolcore.vcxproj.filters @@ -468,10 +468,13 @@ lol + + lol + lol - + lol diff --git a/src/math/constants.cpp b/src/math/constants.cpp index 02927ec1..7caf8266 100644 --- a/src/math/constants.cpp +++ b/src/math/constants.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/math/geometry.cpp b/src/math/geometry.cpp index 8cc4ffb2..69dde6f9 100644 --- a/src/math/geometry.cpp +++ b/src/math/geometry.cpp @@ -9,17 +9,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include /* free() */ #include /* strdup() */ #include /* std::ostream */ -#include - namespace lol { //Test epsilon stuff diff --git a/src/math/half.cpp b/src/math/half.cpp index ab7f1af8..54b27bac 100644 --- a/src/math/half.cpp +++ b/src/math/half.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined __CELLOS_LV2__ # if defined __SNC__ @@ -20,8 +18,6 @@ # endif #endif -#include - namespace lol { diff --git a/src/math/matrix.cpp b/src/math/matrix.cpp index 4730f108..03549ff8 100644 --- a/src/math/matrix.cpp +++ b/src/math/matrix.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/math/real.cpp b/src/math/real.cpp index ebf653a0..6670b651 100644 --- a/src/math/real.cpp +++ b/src/math/real.cpp @@ -8,17 +8,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include #include #include -#include - namespace lol { diff --git a/src/math/transform.cpp b/src/math/transform.cpp index e2c5e209..af050fc9 100644 --- a/src/math/transform.cpp +++ b/src/math/transform.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/math/trig.cpp b/src/math/trig.cpp index eaf1c93a..4edff11a 100644 --- a/src/math/trig.cpp +++ b/src/math/trig.cpp @@ -8,16 +8,12 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined HAVE_FASTMATH_H # include #endif -#include - // Optimisation helpers #if defined __GNUC__ # define __likely(x) __builtin_expect(!!(x), 1) diff --git a/src/math/vector.cpp b/src/math/vector.cpp index 3a31d95f..32d7a0a6 100644 --- a/src/math/vector.cpp +++ b/src/math/vector.cpp @@ -8,14 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include /* std::ostream */ -#include - namespace lol { diff --git a/src/mesh/mesh.cpp b/src/mesh/mesh.cpp index 7e1e8707..5e26f2d0 100644 --- a/src/mesh/mesh.cpp +++ b/src/mesh/mesh.cpp @@ -8,15 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include -#include - namespace lol { diff --git a/src/mesh/primitive.cpp b/src/mesh/primitive.cpp index 2162e196..12aed880 100644 --- a/src/mesh/primitive.cpp +++ b/src/mesh/primitive.cpp @@ -8,15 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include -#include - namespace lol { diff --git a/src/messageservice.cpp b/src/messageservice.cpp index f1f0328f..0682eef1 100644 --- a/src/messageservice.cpp +++ b/src/messageservice.cpp @@ -9,16 +9,12 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include #include -#include - namespace lol { diff --git a/src/platform.cpp b/src/platform.cpp index 62e36cb7..536cb7fa 100644 --- a/src/platform.cpp +++ b/src/platform.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/platform/android/androidapp.cpp b/src/platform/android/androidapp.cpp index 68af5a72..9c7873e9 100644 --- a/src/platform/android/androidapp.cpp +++ b/src/platform/android/androidapp.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if HAVE_CONFIG_H -# include "config.h" -#endif +#include #if __ANDROID__ @@ -27,7 +25,6 @@ extern "C" { #include } -#include #include "androidapp.h" #include "input/input_internal.h" diff --git a/src/platform/d3d9/d3d9input.cpp b/src/platform/d3d9/d3d9input.cpp index c4ac2e63..71266057 100644 --- a/src/platform/d3d9/d3d9input.cpp +++ b/src/platform/d3d9/d3d9input.cpp @@ -8,16 +8,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined USE_XINPUT # include # include #endif -#include #include "d3d9input.h" #include "input/input_internal.h" diff --git a/src/platform/nacl/nacl-app.cpp b/src/platform/nacl/nacl-app.cpp index 2c5451b7..eec0bfb0 100644 --- a/src/platform/nacl/nacl-app.cpp +++ b/src/platform/nacl/nacl-app.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include #include "nacl-app.h" #include "nacl-instance.h" diff --git a/src/platform/nacl/nacl-instance.cpp b/src/platform/nacl/nacl-instance.cpp index 93b526af..210c5ec7 100644 --- a/src/platform/nacl/nacl-instance.cpp +++ b/src/platform/nacl/nacl-instance.cpp @@ -2,9 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include @@ -17,8 +15,6 @@ #include #include -#include - #include "platform/nacl/nacl-instance.h" #include "platform/nacl/opengl_context.h" diff --git a/src/platform/nacl/nacl-module.cpp b/src/platform/nacl/nacl-module.cpp index fab8a63b..d0fb5a99 100644 --- a/src/platform/nacl/nacl-module.cpp +++ b/src/platform/nacl/nacl-module.cpp @@ -2,15 +2,12 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include #include -#include #include "lolgl.h" /* needed for GL_TRUE */ #include "platform/nacl/nacl-instance.h" diff --git a/src/platform/nacl/opengl_context.cpp b/src/platform/nacl/opengl_context.cpp index ac347e0b..88c23277 100644 --- a/src/platform/nacl/opengl_context.cpp +++ b/src/platform/nacl/opengl_context.cpp @@ -2,16 +2,12 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include #include -#include - #include "platform/nacl/opengl_context.h" namespace { diff --git a/src/platform/ps3/ps3app.cpp b/src/platform/ps3/ps3app.cpp index cbd9f749..21278bc0 100644 --- a/src/platform/ps3/ps3app.cpp +++ b/src/platform/ps3/ps3app.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined __CELLOS_LV2__ # include /* sys_ppu_thread_get_stack_information */ @@ -26,7 +24,6 @@ # include #endif -#include #include "lolgl.h" #include "ps3app.h" #include "ps3input.h" diff --git a/src/platform/ps3/ps3input.cpp b/src/platform/ps3/ps3input.cpp index 53829a57..921fcd5a 100644 --- a/src/platform/ps3/ps3input.cpp +++ b/src/platform/ps3/ps3input.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include @@ -20,7 +18,6 @@ # include #endif -#include #include "ps3input.h" namespace lol diff --git a/src/platform/sdl/sdlapp.cpp b/src/platform/sdl/sdlapp.cpp index 3fde1acf..6cfc5aa4 100644 --- a/src/platform/sdl/sdlapp.cpp +++ b/src/platform/sdl/sdlapp.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined USE_SDL # if defined HAVE_SDL_SDL_H @@ -24,7 +22,6 @@ # endif #endif -#include #include "lolgl.h" #include "platform/sdl/sdlapp.h" #include "platform/sdl/sdlinput.h" diff --git a/src/platform/sdl/sdlinput.cpp b/src/platform/sdl/sdlinput.cpp index b3b51c7e..42b00eaa 100644 --- a/src/platform/sdl/sdlinput.cpp +++ b/src/platform/sdl/sdlinput.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if HAVE_CONFIG_H -# include "config.h" -#endif +#include #if USE_SDL # if HAVE_SDL_SDL_H @@ -20,7 +18,6 @@ # endif #endif -#include #include "sdlinput.h" #include "input/input_internal.h" diff --git a/src/platform/xbox/xboxapp.cpp b/src/platform/xbox/xboxapp.cpp index 3f9afe5f..d9b6e818 100644 --- a/src/platform/xbox/xboxapp.cpp +++ b/src/platform/xbox/xboxapp.cpp @@ -8,15 +8,12 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined _XBOX # include #endif -#include #include "xboxapp.h" #include "xboxinput.h" diff --git a/src/platform/xbox/xboxinput.cpp b/src/platform/xbox/xboxinput.cpp index 3e2aafff..f5c08a7e 100644 --- a/src/platform/xbox/xboxinput.cpp +++ b/src/platform/xbox/xboxinput.cpp @@ -8,16 +8,13 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined _XBOX # include # include #endif -#include #include "xboxinput.h" namespace lol diff --git a/src/profiler.cpp b/src/profiler.cpp index 2d419b61..8c52347d 100644 --- a/src/profiler.cpp +++ b/src/profiler.cpp @@ -8,15 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include -#include - namespace lol { diff --git a/src/sample.cpp b/src/sample.cpp index 8b0a67b0..4a60be50 100644 --- a/src/sample.cpp +++ b/src/sample.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include @@ -31,8 +29,6 @@ # endif #endif -#include - namespace lol { diff --git a/src/sampler.cpp b/src/sampler.cpp index b98ae66b..d1efebc2 100644 --- a/src/sampler.cpp +++ b/src/sampler.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/scene.cpp b/src/scene.cpp index 6ac81d77..69eaa74e 100644 --- a/src/scene.cpp +++ b/src/scene.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if HAVE_CONFIG_H -# include "config.h" -#endif +#include #include @@ -19,7 +17,6 @@ # include #endif -#include #include "lolgl.h" LOLFX_RESOURCE_DECLARE(tile); diff --git a/src/sprite.cpp b/src/sprite.cpp index 6f24d750..2a6e7f99 100644 --- a/src/sprite.cpp +++ b/src/sprite.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/sys/file.cpp b/src/sys/file.cpp index 5774dcc9..5793c315 100644 --- a/src/sys/file.cpp +++ b/src/sys/file.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if HAVE_CONFIG_H -# include "config.h" -#endif +#include #if __CELLOS_LV2__ # include @@ -30,8 +28,6 @@ #include #include -#include - namespace lol { diff --git a/src/sys/init.cpp b/src/sys/init.cpp index faf5f45a..3f8036f3 100644 --- a/src/sys/init.cpp +++ b/src/sys/init.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if HAVE_CONFIG_H -# include "config.h" -#endif +#include #include @@ -23,8 +21,6 @@ # include #endif -#include - namespace lol { diff --git a/src/sys/thread.cpp b/src/sys/thread.cpp index 1a105d53..652713a4 100644 --- a/src/sys/thread.cpp +++ b/src/sys/thread.cpp @@ -9,11 +9,7 @@ // http://www.wtfpl.net/ for more details. // -#if HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/sys/timer.cpp b/src/sys/timer.cpp index f9eb9f66..5e8f16db 100644 --- a/src/sys/timer.cpp +++ b/src/sys/timer.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include @@ -37,8 +35,6 @@ # include #endif -#include - namespace lol { diff --git a/src/t/base/array.cpp b/src/t/base/array.cpp index f2617efb..47c21174 100644 --- a/src/t/base/array.cpp +++ b/src/t/base/array.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/base/enum.cpp b/src/t/base/enum.cpp index 4a16c4b4..ca43a7d0 100644 --- a/src/t/base/enum.cpp +++ b/src/t/base/enum.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/base/map.cpp b/src/t/base/map.cpp index 3730e03f..9dd13df3 100644 --- a/src/t/base/map.cpp +++ b/src/t/base/map.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/base/string.cpp b/src/t/base/string.cpp index f6b03b6c..caa58f42 100644 --- a/src/t/base/string.cpp +++ b/src/t/base/string.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/base/types.cpp b/src/t/base/types.cpp index 307fbedd..6a04647b 100644 --- a/src/t/base/types.cpp +++ b/src/t/base/types.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/entity/camera.cpp b/src/t/entity/camera.cpp index 724009ac..afc39cdc 100644 --- a/src/t/entity/camera.cpp +++ b/src/t/entity/camera.cpp @@ -9,11 +9,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/image/color.cpp b/src/t/image/color.cpp index 14fcf382..2e2bdb7f 100644 --- a/src/t/image/color.cpp +++ b/src/t/image/color.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/image/image.cpp b/src/t/image/image.cpp index 73b93aaf..f3b4e14f 100644 --- a/src/t/image/image.cpp +++ b/src/t/image/image.cpp @@ -8,13 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include #include namespace lol diff --git a/src/t/math/array2d.cpp b/src/t/math/array2d.cpp index 7a72b7b9..04da5830 100644 --- a/src/t/math/array2d.cpp +++ b/src/t/math/array2d.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/math/array3d.cpp b/src/t/math/array3d.cpp index 1e086a1e..419fcb16 100644 --- a/src/t/math/array3d.cpp +++ b/src/t/math/array3d.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/math/arraynd.cpp b/src/t/math/arraynd.cpp index 53cb7014..1b61d4b0 100644 --- a/src/t/math/arraynd.cpp +++ b/src/t/math/arraynd.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include #include diff --git a/src/t/math/box.cpp b/src/t/math/box.cpp index 23d69acd..4711ee2e 100644 --- a/src/t/math/box.cpp +++ b/src/t/math/box.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/math/cmplx.cpp b/src/t/math/cmplx.cpp index 9cd8b330..40c46588 100644 --- a/src/t/math/cmplx.cpp +++ b/src/t/math/cmplx.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/math/half.cpp b/src/t/math/half.cpp index e69ae58e..482adb20 100644 --- a/src/t/math/half.cpp +++ b/src/t/math/half.cpp @@ -8,13 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include #include namespace lol diff --git a/src/t/math/interp.cpp b/src/t/math/interp.cpp index b69a621f..6f7379fe 100644 --- a/src/t/math/interp.cpp +++ b/src/t/math/interp.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/math/matrix.cpp b/src/t/math/matrix.cpp index 3acbba80..3733da16 100644 --- a/src/t/math/matrix.cpp +++ b/src/t/math/matrix.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/math/quat.cpp b/src/t/math/quat.cpp index f9d5c805..3be5c4be 100644 --- a/src/t/math/quat.cpp +++ b/src/t/math/quat.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/math/rand.cpp b/src/t/math/rand.cpp index 66027f2b..efb820fe 100644 --- a/src/t/math/rand.cpp +++ b/src/t/math/rand.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/math/real.cpp b/src/t/math/real.cpp index aafc43f8..a3d7103a 100644 --- a/src/t/math/real.cpp +++ b/src/t/math/real.cpp @@ -8,13 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include #include namespace lol diff --git a/src/t/math/rotation.cpp b/src/t/math/rotation.cpp index c33ec85b..eb93f23d 100644 --- a/src/t/math/rotation.cpp +++ b/src/t/math/rotation.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/math/trig.cpp b/src/t/math/trig.cpp index 44145954..cc4fb66e 100644 --- a/src/t/math/trig.cpp +++ b/src/t/math/trig.cpp @@ -8,13 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include #include namespace lol diff --git a/src/t/math/vector.cpp b/src/t/math/vector.cpp index d94d3ee1..579e629f 100644 --- a/src/t/math/vector.cpp +++ b/src/t/math/vector.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/sys/thread.cpp b/src/t/sys/thread.cpp index 3c1b172b..48746431 100644 --- a/src/t/sys/thread.cpp +++ b/src/t/sys/thread.cpp @@ -8,11 +8,8 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include -#include #include namespace lol diff --git a/src/t/test-common.cpp b/src/t/test-common.cpp index 91b64abf..9ba57783 100644 --- a/src/t/test-common.cpp +++ b/src/t/test-common.cpp @@ -8,15 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include -#include - #include int main(int argc, char **argv) diff --git a/src/text.cpp b/src/text.cpp index 117dae84..baf853c4 100644 --- a/src/text.cpp +++ b/src/text.cpp @@ -8,16 +8,12 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include /* free() */ #include /* strdup() */ -#include - namespace lol { diff --git a/src/ticker.cpp b/src/ticker.cpp index e9b59b91..91fcfa12 100644 --- a/src/ticker.cpp +++ b/src/ticker.cpp @@ -8,15 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include -#include - namespace lol { diff --git a/src/tiler.cpp b/src/tiler.cpp index 9273414a..3cd649cf 100644 --- a/src/tiler.cpp +++ b/src/tiler.cpp @@ -8,11 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif - -#include +#include namespace lol { diff --git a/src/tileset.cpp b/src/tileset.cpp index 00511450..e1f10ef1 100644 --- a/src/tileset.cpp +++ b/src/tileset.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include @@ -26,8 +24,6 @@ # endif #endif -#include - namespace lol { diff --git a/src/video.cpp b/src/video.cpp index 7235ce0f..cf8f008e 100644 --- a/src/video.cpp +++ b/src/video.cpp @@ -8,9 +8,7 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #if defined _XBOX # include @@ -26,7 +24,6 @@ # undef far /* Fuck Microsoft again */ #endif -#include #include "lolgl.h" namespace lol diff --git a/src/world.cpp b/src/world.cpp index 65380dc0..aff6206f 100644 --- a/src/world.cpp +++ b/src/world.cpp @@ -8,16 +8,12 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include #include #include -#include - #include "lua/lua.hpp" namespace lol diff --git a/src/worldentity.cpp b/src/worldentity.cpp index 51290df7..f6544875 100644 --- a/src/worldentity.cpp +++ b/src/worldentity.cpp @@ -8,14 +8,10 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H -# include "config.h" -#endif +#include #include -#include - namespace lol { diff --git a/tools/lolremez/lolremez.cpp b/tools/lolremez/lolremez.cpp index d841caf6..536342ac 100644 --- a/tools/lolremez/lolremez.cpp +++ b/tools/lolremez/lolremez.cpp @@ -8,11 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include diff --git a/tools/lolremez/solver.cpp b/tools/lolremez/solver.cpp index 7875a178..e58038ee 100644 --- a/tools/lolremez/solver.cpp +++ b/tools/lolremez/solver.cpp @@ -8,11 +8,11 @@ // http://www.wtfpl.net/ for more details. // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif -#include +#include #include diff --git a/tools/make-font.cpp b/tools/make-font.cpp index bd0760f4..29159701 100644 --- a/tools/make-font.cpp +++ b/tools/make-font.cpp @@ -3,7 +3,7 @@ // Copyright (c) 2010 Sam Hocevar // -#if defined HAVE_CONFIG_H +#if HAVE_CONFIG_H # include "config.h" #endif