Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8056


Ignore:
Timestamp:
Mar 10, 2011, 5:52:31 PM (13 years ago)
Author:
rgrieder
Message:

Fiddled around with ALUT and OpenAL headers.
The hack in PackageConfigOSX.cmake is just a guess so it really needs testing.

All ALUT and OpenAL headers should now be included with <alut.h> or <al.h> respectively because FindOpenAL.cmake defines the include directories this way.
There is still a hack in LibraryConfig.cmake for non MSVC/Apple systems because alut.h includes al.h with AL/al.h on most systems.

Location:
code/branches/mac_osx
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • code/branches/mac_osx/cmake/PackageConfigOSX.cmake

    r7682 r8056  
    5151SET(ENV{OGRE_PLUGIN_DIR}       ${DEP_BINARY_DIR})
    5252
     53# For OS X 10.5 we have to ship modified headers to make it compile
     54# on gcc >= 4.2 (binaries stay the same)
     55# Sets the library path for the FIND_LIBRARY
     56IF(CMAKE_SYSTEM_VERSION STREQUAL "10.5")
     57  SET(ENV{OPENALDIR} ${DEP_INCLUDE_DIR}/openal)
     58ENDIF()
     59
    5360# Xcode won't be able to run the toluabind code generation if we're using the dependency package
    5461#IF(DEPENDENCY_PACKAGE_ENABLE)
  • code/branches/mac_osx/cmake/tools/FindALUT.cmake

    r7782 r8056  
    1 # Find ALUT includes and library
    2 #
    3 # This module defines
    4 #  ALUT_INCLUDE_DIR
    5 #  ALUT_LIBRARY, the library to link against to use ALUT.
    6 #  ALUT_FOUND, If false, do not try to use ALUT
    7 #
    8 # Copyright © 2007, Matt Williams
    9 # Modified by Nicolas Schlumberger to make it work on the Tardis-Infrastucture
    10 # of the ETH Zurich (removed later on)
    11 #
    12 # Redistribution and use is allowed according to the terms of the BSD license.
    13 #
    14 # Several changes and additions by Fabian 'x3n' Landau
    15 # Lots of simplifications by Adrian Friedli
    16 # Version checking by Reto Grieder
    17 # Adaption of the OGRE find script to ALUT by Kevin Young
    18 #                 > www.orxonox.net <
     1 #
     2 #             ORXONOX - the hottest 3D action shooter ever to exist
     3 #                             > www.orxonox.net <
     4 #
     5 #        This program is free software; you can redistribute it and/or
     6 #         modify it under the terms of the GNU General Public License
     7 #        as published by the Free Software Foundation; either version 2
     8 #            of the License, or (at your option) any later version.
     9 #
     10 #       This program is distributed in the hope that it will be useful,
     11 #        but WITHOUT ANY WARRANTY; without even the implied warranty of
     12 #        MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     13 #                 GNU General Public License for more details.
     14 #
     15 #   You should have received a copy of the GNU General Public License along
     16 #      with this program; if not, write to the Free Software Foundation,
     17 #     Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
     18 #
     19 #
     20 #  Author:
     21 #    Kevin Young
     22 #  Description:
     23 #    Variables defined:
     24 #      ALUT_FOUND
     25 #      ALUT_INCLUDE_DIR
     26 #      ALUT_LIBRARY
     27 #
    1928
    20 INCLUDE(FindPackageHandleAdvancedArgs)
     29INCLUDE(FindPackageHandleStandardArgs)
    2130INCLUDE(HandleLibraryTypes)
    2231
    2332FIND_PATH(ALUT_INCLUDE_DIR alut.h
    2433  PATHS $ENV{ALUTDIR}
    25   PATH_SUFFIXES include include/AL ALUT
     34  PATH_SUFFIXES include include/AL Headers Headers/AL
    2635)
    2736FIND_LIBRARY(ALUT_LIBRARY_OPTIMIZED
    28   NAMES ALUT alut
     37  NAMES alut ALUT
    2938  PATHS $ENV{ALUTDIR}
    3039  PATH_SUFFIXES lib bin/Release bin/release Release release ALUT
    3140)
    3241FIND_LIBRARY(ALUT_LIBRARY_DEBUG
    33   NAMES ALUTD alutd alut_d alutD alut_D
     42  NAMES alutd alut_d alutD alut_D ALUTd ALUT_d ALUTD ALUT_D
    3443  PATHS $ENV{ALUTDIR}
    3544  PATH_SUFFIXES lib bin/Debug bin/debug Debug debug ALUT
     
    3746
    3847# Handle the REQUIRED argument and set ALUT_FOUND
    39 # Also check the version requirements
    40 FIND_PACKAGE_HANDLE_ADVANCED_ARGS(ALUT DEFAULT_MSG
     48FIND_PACKAGE_HANDLE_STANDARD_ARGS(ALUT DEFAULT_MSG
    4149  ALUT_LIBRARY_OPTIMIZED
    4250  ALUT_INCLUDE_DIR
  • code/branches/mac_osx/src/orxonox/sound/BaseSound.cc

    r7664 r8056  
    3131#include <cassert>
    3232#include <vector>
    33 
    34 #ifdef ORXONOX_PLATFORM_APPLE
    35 #include "openal/al.h"
    36 #else
    3733#include <al.h>
    38 #endif
    3934
    4035#include "util/Math.h"
  • code/branches/mac_osx/src/orxonox/sound/SoundBuffer.cc

    r7664 r8056  
    3030#include "SoundBuffer.h"
    3131
    32 #if defined(ORXONOX_PLATFORM_APPLE)
    33 #include <ALUT/alut.h>
    34 #else
    35 #include <AL/alut.h>
    36 #endif
     32#include <alut.h>
    3733#include <vorbis/vorbisfile.h>
    3834
  • code/branches/mac_osx/src/orxonox/sound/SoundManager.cc

    r8043 r8056  
    3131#include "SoundManager.h"
    3232
    33 #if defined(__APPLE__)
    34 #include <ALUT/alut.h>
    35 #else
    36 #include <AL/alut.h>
    37 #endif
    3833#include <utility>
     34#include <alut.h>
    3935#include <loki/ScopeGuard.h>
    4036
  • code/branches/mac_osx/src/orxonox/sound/SoundStreamer.cc

    r7664 r8056  
    2727#include "SoundStreamer.h"
    2828
    29 #ifdef ORXONOX_PLATFORM_APPLE
    30 #include "openal/al.h"
    31 #else
    3229#include <al.h>
    33 #endif
    34 
    3530#include <vorbis/vorbisfile.h>
    3631#include "SoundManager.h"
  • code/branches/mac_osx/src/orxonox/sound/WorldSound.cc

    r7591 r8056  
    3030#include "WorldSound.h"
    3131
    32 #if defined(__APPLE__)
    33 #include <ALUT/alut.h>
    34 #else
    35 #include <AL/alut.h>
    36 #endif
     32#include <alut.h>
     33
    3734#include "util/Math.h"
    3835#include "core/CoreIncludes.h"
Note: See TracChangeset for help on using the changeset viewer.