blob: 9bfa298b1f1c5025cff3108313a230f001871521 [file] [log] [blame]
Evan Lloyd04dc3442017-05-25 19:06:47 +01001/*
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +00002 * Copyright (c) 2016-2018, ARM Limited and Contributors. All rights reserved.
Evan Lloyd04dc3442017-05-25 19:06:47 +01003 *
4 * SPDX-License-Identifier: BSD-3-Clause
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +00005 */
6/*
Evan Lloyd04dc3442017-05-25 19:06:47 +01007 * Build platform specific handling.
8 * This allows for builds on non-Posix platforms
9 * e.g. Visual Studio on Windows
10 */
11
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000012#ifndef FIPTOOL_PLATFORM_H
13#define FIPTOOL_PLATFORM_H
Evan Lloyd04dc3442017-05-25 19:06:47 +010014
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000015#ifndef _MSC_VER
Evan Lloyd04dc3442017-05-25 19:06:47 +010016
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000017/* Not Visual Studio, so include Posix Headers. */
18# include <getopt.h>
19# include <openssl/sha.h>
20# include <unistd.h>
Evan Lloyd04dc3442017-05-25 19:06:47 +010021
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000022# define BLD_PLAT_STAT stat
Evan Lloyd04dc3442017-05-25 19:06:47 +010023
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000024#else
Evan Lloyd04dc3442017-05-25 19:06:47 +010025
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000026/* Visual Studio. */
27# include "win_posix.h"
Evan Lloyd04dc3442017-05-25 19:06:47 +010028
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000029#endif
Evan Lloyd04dc3442017-05-25 19:06:47 +010030
Antonio Nino Diaz5eb88372018-11-08 10:20:19 +000031#endif /* FIPTOOL_PLATFORM_H */