Photon 1.0.0
Loading...
Searching...
No Matches
Macros.hpp
Go to the documentation of this file.
1/*
2 * =====================================================================
3 *
4 * Photon
5 * Copyright Amlal EL Mahrouss, all rights reserved.
6 *
7 * File: Macros.h
8 * Purpose:
9 *
10 * =====================================================================
11 */
12
13#pragma once
14
15#ifndef PHOTON_GET_DATA_DIR
16#ifdef PHOTON_WINDOWS
17#define PHOTON_GET_DATA_DIR(DIR) \
18 Photon::String DIR = getenv("APPDATA"); \
19 DIR += "/.PHOTON/";
20
21#else
22#define PHOTON_GET_DATA_DIR(DIR) \
23 Photon::String DIR = getenv("HOME"); \
24 DIR += "/.PHOTON/";
25
26#endif
27
28#ifdef PHOTON_PHOTON_OS
29#define PHOTON_GET_DATA_DIR(DIR) \
30 Photon::String DIR = EnvGetVar("HOME"); \
31 DIR += "\\.PHOTON\\";
32
33#else
34#define PHOTON_GET_DATA_DIR(DIR) \
35 Photon::String DIR = getenv("HOME"); \
36 DIR += "/.PHOTON/";
37
38#endif
39#endif // ifndef PHOTON_GET_DATA_DIR