Aeon Engine c550894
AeonGames Open Source Game Engine
Loading...
Searching...
No Matches
Platform.hpp
Go to the documentation of this file.
1/*
2Copyright (C) 2016,2017,2020,2021,2025,2026 Rodrigo Jose Hernandez Cordoba
3
4Licensed under the Apache License, Version 2.0 (the "License");
5you may not use this file except in compliance with the License.
6You may obtain a copy of the License at
7
8 http://www.apache.org/licenses/LICENSE-2.0
9
10Unless required by applicable law or agreed to in writing, software
11distributed under the License is distributed on an "AS IS" BASIS,
12WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13See the License for the specific language governing permissions and
14limitations under the License.
15*/
22#ifndef AEONGAMES_PLATFORM_H
23#define AEONGAMES_PLATFORM_H
24
25#ifdef _WIN32
26#ifndef WIN32_LEAN_AND_MEAN
27#define WIN32_LEAN_AND_MEAN
28#endif
29#ifndef NOMINMAX
30#define NOMINMAX
31#endif
32#include <windows.h>
33#ifdef __MINGW32__
34#include <sys/types.h>
35#include <sys/stat.h>
36#include <unistd.h>
37#endif
38#ifndef DLL
39#ifdef AeonEngine_EXPORTS
40#define DLL __declspec( dllexport )
41#else
42#define DLL __declspec( dllimport )
43#endif
44#ifndef PLUGIN
45#define PLUGIN __declspec( dllexport )
46#endif
47#endif
48#elif defined(__unix__) || defined(__APPLE__)
49#include <sys/types.h>
50#include <sys/stat.h>
51#include <unistd.h>
52#include <dlfcn.h>
53#ifndef DLL
54#define DLL
55#endif
56#ifndef PLUGIN
57#define PLUGIN
58#endif
59#endif
60
61#if defined(__GNUC__) && defined(__i386__)
62#define ENTRYPOINT __attribute__((force_align_arg_pointer))
63#else
64#define ENTRYPOINT
65#endif
66
67#endif