Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix build with Win32 VC14 #248

Merged
merged 1 commit into from
Jan 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions lib/fko_encryption.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,20 @@
#include "gpgme_funcs.h"
#if HAVE_SYS_STAT_H
#include <sys/stat.h>
/* Taken from cURL for win32 build
*/
#if !defined(S_ISREG) && defined(S_IFMT) && defined(S_IFREG)
#define S_ISREG(m) (((m) & S_IFMT) == S_IFREG)
#endif
#if !defined(S_ISDIR) && defined(S_IFMT) && defined(S_IFDIR)
#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
#endif
#if !defined(S_IFLNK)
#define S_IFLNK 0xA000
#endif
#if !defined(S_ISLNK) && defined(S_IFMT)
#define S_ISLNK(m) (((m) & S_IFMT) == S_IFLNK)
#endif
#endif
#endif

Expand Down
5 changes: 4 additions & 1 deletion win32/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,9 @@
/* Define if you have libgpgme */
#undef HAVE_LIBGPGME

/* Path to gpg executable */
#define GPG_EXE "gpg.exe"

/* Define to 1 if your system has a GNU libc compatible `malloc' function, and
to 0 otherwise. */
#undef HAVE_MALLOC
Expand Down Expand Up @@ -123,7 +126,7 @@
#undef HAVE_SYS_SOCKET_H

/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
#define HAVE_SYS_STAT_H 1

/* Define to 1 if you have the <sys/time.h> header file. */
#undef HAVE_SYS_TIME_H
Expand Down