Skip to content

Commit

Permalink
Problem fix: <unistd.h> is not properly defined.
Browse files Browse the repository at this point in the history
  • Loading branch information
alanminko committed Sep 4, 2023
1 parent 3309cca commit 1cdb2da
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 5 deletions.
7 changes: 6 additions & 1 deletion src/aig/gia/giaKf.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,18 @@
#include "gia.h"
#include "misc/vec/vecSet.h"

#ifdef _MSC_VER
#define unlink _unlink
#else
#include <unistd.h>
#endif

#ifdef ABC_USE_PTHREADS

#ifdef _WIN32
#include "../lib/pthread.h"
#else
#include <pthread.h>
#include <unistd.h>
#endif

#endif
Expand Down
6 changes: 5 additions & 1 deletion src/aig/gia/giaStoch.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,18 @@
#include "base/main/main.h"
#include "base/cmd/cmd.h"

#ifdef _MSC_VER
#define unlink _unlink
#else
#include <unistd.h>
#endif

#ifdef ABC_USE_PTHREADS

#ifdef _WIN32
#include "../lib/pthread.h"
#else
#include <pthread.h>
#include <unistd.h>
#endif

#endif
Expand Down
7 changes: 6 additions & 1 deletion src/aig/gia/giaTranStoch.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,18 @@
#include <opt/sfm/sfm.h>
#include <opt/fxu/fxu.h>

#ifdef _MSC_VER
#define unlink _unlink
#else
#include <unistd.h>
#endif

#ifdef ABC_USE_PTHREADS

#ifdef _WIN32
#include "../lib/pthread.h"
#else
#include <pthread.h>
#include <unistd.h>
#endif

#endif
Expand Down
4 changes: 2 additions & 2 deletions src/sat/cnf/cnfUtil.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@
#include "cnf.h"
#include "sat/bsat/satSolver.h"

ABC_NAMESPACE_IMPL_START

#ifdef _MSC_VER
#define unlink _unlink
#else
Expand All @@ -39,6 +37,8 @@ ABC_NAMESPACE_IMPL_START

#endif

ABC_NAMESPACE_IMPL_START

////////////////////////////////////////////////////////////////////////
/// DECLARATIONS ///
////////////////////////////////////////////////////////////////////////
Expand Down

0 comments on commit 1cdb2da

Please sign in to comment.