mirror of
https://github.com/NixOS/nix.git
synced 2025-11-09 03:56:01 +01:00
Move setting GC_THREADS into eval-gc.hh
This commit is contained in:
parent
a3ff648f90
commit
4c1c4f79a3
4 changed files with 2 additions and 8 deletions
|
|
@ -15,8 +15,6 @@
|
||||||
# include <pthread_np.h>
|
# include <pthread_np.h>
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
# include <gc/gc.h>
|
|
||||||
# include <gc/gc_cpp.h>
|
|
||||||
# include <gc/gc_allocator.h>
|
# include <gc/gc_allocator.h>
|
||||||
|
|
||||||
# include <boost/coroutine2/coroutine.hpp>
|
# include <boost/coroutine2/coroutine.hpp>
|
||||||
|
|
|
||||||
|
|
@ -3,12 +3,13 @@
|
||||||
|
|
||||||
#include <cstddef>
|
#include <cstddef>
|
||||||
|
|
||||||
// For `NIX_USE_BOEHMGC`, and if that's set, `GC_THREADS`
|
// For `NIX_USE_BOEHMGC`
|
||||||
#include "nix/expr/config.hh"
|
#include "nix/expr/config.hh"
|
||||||
|
|
||||||
#if NIX_USE_BOEHMGC
|
#if NIX_USE_BOEHMGC
|
||||||
|
|
||||||
# define GC_INCLUDE_NEW
|
# define GC_INCLUDE_NEW
|
||||||
|
# define GC_THREADS 1
|
||||||
|
|
||||||
# include <gc/gc.h>
|
# include <gc/gc.h>
|
||||||
# include <gc/gc_cpp.h>
|
# include <gc/gc_cpp.h>
|
||||||
|
|
|
||||||
|
|
@ -6,9 +6,6 @@
|
||||||
#include "nix/expr/eval-error.hh"
|
#include "nix/expr/eval-error.hh"
|
||||||
#include "nix/expr/eval-settings.hh"
|
#include "nix/expr/eval-settings.hh"
|
||||||
|
|
||||||
// For `NIX_USE_BOEHMGC`, and if that's set, `GC_THREADS`
|
|
||||||
#include "nix/expr/config.hh"
|
|
||||||
|
|
||||||
namespace nix {
|
namespace nix {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -61,8 +61,6 @@ if bdw_gc.found()
|
||||||
define_value = cxx.has_function(funcspec).to_int()
|
define_value = cxx.has_function(funcspec).to_int()
|
||||||
configdata_priv.set(define_name, define_value)
|
configdata_priv.set(define_name, define_value)
|
||||||
endforeach
|
endforeach
|
||||||
# Affects ABI, because it changes what bdw_gc itself does!
|
|
||||||
configdata_pub.set('GC_THREADS', 1)
|
|
||||||
endif
|
endif
|
||||||
# Used in public header. Affects ABI!
|
# Used in public header. Affects ABI!
|
||||||
configdata_pub.set('NIX_USE_BOEHMGC', bdw_gc.found().to_int())
|
configdata_pub.set('NIX_USE_BOEHMGC', bdw_gc.found().to_int())
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue