/*
 * Copyright (c) 2000 Shlomi Fish
 *
 * Permission is hereby granted, free of charge, to any person
 * obtaining a copy of this software and associated documentation
 * files (the "Software"), to deal in the Software without
 * restriction, including without limitation the rights to use,
 * copy, modify, merge, publish, distribute, sublicense, and/or sell
 * copies of the Software, and to permit persons to whom the
 * Software is furnished to do so, subject to the following
 * conditions:
 *
 * The above copyright notice and this permission notice shall be
 * included in all copies or substantial portions of the Software.
 *
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
 * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
 * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
 * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
 * OTHER DEALINGS IN THE SOFTWARE.
 */
/*
 * config.h - Configuration file for Freecell Solver
 *
 * ${AUTOGENERATED_CONFIG_H}
*/

#ifndef FC_SOLVE__CONFIG_H
#define FC_SOLVE__CONFIG_H

#ifdef __cplusplus
extern "C" {
#endif

#include "fcs_back_compat.h"

#cmakedefine DEBUG_STATES
#cmakedefine COMPACT_STATES
#cmakedefine INDIRECT_STACK_STATES

#cmakedefine FCS_RCS_STATES

#cmakedefine CARD_DEBUG_PRES

/*
 * Define this macro if the C compiler supports the keyword inline or
 * a similar keyword that was found by Autoconf (and defined as inline).
 * */
#cmakedefine HAVE_C_INLINE

#cmakedefine FCS_INLINE_KEYWORD ${FCS_INLINE_KEYWORD}

/*
    The sort margin size for the previous states array.
*/
#define PREV_STATES_SORT_MARGIN 32

/*
    The amount the pack pointers array grows by. Shouldn't be too high
    because it doesn't happen too often.
*/
#cmakedefine IA_STATE_PACKS_GROW_BY 32

/* The size of a single pack in alloc.c/alloc.h measured in 1024 chars. */
#cmakedefine FCS_IA_PACK_SIZE ${FCS_IA_PACK_SIZE}

#ifndef FCS_FREECELL_ONLY
#cmakedefine FCS_FREECELL_ONLY
#endif

#cmakedefine FCS_DISABLE_SIMPLE_SIMON

#cmakedefine FCS_SINGLE_HARD_THREAD

#cmakedefine FCS_WITHOUT_FC_PRO_MOVES_COUNT

/*
 * This macro disables the flipping card logic. The flipping card logic
 * was an experimental feature that aimed to give Freecell Solver the
 * ability to solve Gypsy and Klondike-like games. In practice, this
 * didn't happen due to other technical difficulties.
 * */

/*
 * Get rid of the visited_iter counter on each state's extra_info. It is
 * used a little for debugging, but otherwise is not needed for the run-time
 * operation.
 * */
#cmakedefine FCS_WITHOUT_VISITED_ITER

/*
 * Disable the patsolve code at compile time in case it isn't wanted.
 * */
#cmakedefine FCS_DISABLE_PATSOLVE
/*
 * Get rid of the "depth" field on each state's extra_info. It is
 * used a little, but otherwise is not needed for the run-time
 * operation.
 * */
#cmakedefine FCS_WITHOUT_DEPTH_FIELD

/*
 * This flag controls a hash behaviour. It seems to improve things somewhat.
 * */
#cmakedefine FCS_INLINED_HASH_COMPARISON ${FCS_INLINED_HASH_COMPARISON}

#cmakedefine FCS_INT_BIT_SIZE_LOG2 ${FCS_INT_BIT_SIZE_LOG2}

#cmakedefine FCS_WITH_CONTEXT_VARIABLE

/* This is an integer that specifies the maximal size of identifiers
 * in chars/bytes. */
#cmakedefine FCS_MAX_IDENT_LEN ${FCS_MAX_IDENT_LEN}

/*
 * The size of void*.
 */
@SIZEOF_VOID_P_CODE@

/*
 * This flag determines whether we are using the more compact but slower,
 * internal move tokens.
 *  */
#cmakedefine FCS_USE_COMPACT_MOVE_TOKENS

#cmakedefine FCS_HARD_CODED_NUM_FCS_FOR_FREECELL_ONLY ${FCS_HARD_CODED_NUM_FCS_FOR_FREECELL_ONLY}

#ifndef FCS_HARD_CODED_NUM_FCS_FOR_FREECELL_ONLY
#define FCS_HARD_CODED_NUM_FCS_FOR_FREECELL_ONLY 4
#endif

/*
 * The maximal number of Freecells. For efficiency's sake it should be a
 * multiple of 4.
 * */

#ifdef FCS_FREECELL_ONLY
#define HARD_CODED_NUM_FREECELLS FCS_HARD_CODED_NUM_FCS_FOR_FREECELL_ONLY
#define HARD_CODED_NUM_STACKS 8
#define HARD_CODED_NUM_DECKS 1
#ifndef FCS_DISABLE_SIMPLE_SIMON
#define FCS_DISABLE_SIMPLE_SIMON
#endif

#endif

#ifdef HARD_CODED_NUM_FREECELLS
#define MAX_NUM_FREECELLS HARD_CODED_NUM_FREECELLS
#else
#define MAX_NUM_FREECELLS ${MAX_NUM_FREECELLS}
#endif

/*
 * The maximal number of Stacks. For efficiency's sake it should be a
 * multiple of 4.
 * */

#ifdef HARD_CODED_NUM_STACKS
#define MAX_NUM_STACKS HARD_CODED_NUM_STACKS
#else
#define MAX_NUM_STACKS ${MAX_NUM_STACKS}
#endif
/*
 * The maximal number of initial cards that can be found in a stack.
 * */
#define MAX_NUM_INITIAL_CARDS_IN_A_STACK ${MAX_NUM_INITIAL_CARDS_IN_A_STACK}

#ifdef HARD_CODED_NUM_DECKS
#define MAX_NUM_DECKS HARD_CODED_NUM_DECKS
#else
#define MAX_NUM_DECKS ${MAX_NUM_DECKS}
#endif


#define FCS_STATE_STORAGE_INDIRECT 0
#define FCS_STATE_STORAGE_INTERNAL_HASH 1
#define FCS_STATE_STORAGE_LIBAVL2_TREE 2
#define FCS_STATE_STORAGE_LIBREDBLACK_TREE 3
#define FCS_STATE_STORAGE_GLIB_TREE 4
#define FCS_STATE_STORAGE_GLIB_HASH 5
#define FCS_STATE_STORAGE_DB_FILE 6
#define FCS_STATE_STORAGE_JUDY 7
#define FCS_STATE_STORAGE_GOOGLE_DENSE_HASH 8
#define FCS_STATE_STORAGE_KAZ_TREE 9

#define FCS_STACK_STORAGE_NULL (-1)
#define FCS_STACK_STORAGE_INTERNAL_HASH 0
#define FCS_STACK_STORAGE_LIBAVL2_TREE 1
#define FCS_STACK_STORAGE_LIBREDBLACK_TREE 2
#define FCS_STACK_STORAGE_GLIB_TREE 3
#define FCS_STACK_STORAGE_GLIB_HASH 4
#define FCS_STACK_STORAGE_JUDY 5
#define FCS_STACK_STORAGE_GOOGLE_DENSE_HASH 6

#define FCS_STATE_STORAGE ${FCS_STATE_STORAGE}
#define FCS_STACK_STORAGE ${FCS_STACK_STORAGE}

#define FCS_RCS_CACHE_STORAGE_JUDY 0
#define FCS_RCS_CACHE_STORAGE_KAZ_TREE 1

#define FCS_RCS_CACHE_STORAGE ${FCS_RCS_CACHE_STORAGE}

/* Define to 1 if you have the `m' library (-lm). */
#cmakedefine HAVE_LIBM

#cmakedefine HAVE_STRNDUP

#cmakedefine HAVE_STRNCASECMP

#cmakedefine HAVE_VASPRINTF

/* Name of package */
#define PACKAGE "${PACKAGE}"

/* Define to the address where bug reports for this package should be sent. */
#define PACKAGE_BUGREPORT "${PACKAGE_BUGREPORT}"

/* Define to the full name of this package. */
#define PACKAGE_NAME "${PACKAGE_NAME}"

/* Define to the full name and version of this package. */
#define PACKAGE_STRING "${PACKAGE_STRING}"

/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "${PACKAGE_TARNAME}"

/* Define to the version of this package. */
#define PACKAGE_VERSION "${PACKAGE_VERSION}"

/* Version number of package */
#define VERSION "${VERSION}"

#ifndef FCS_INT_BIT_SIZE_LOG2
#define FCS_INT_BIT_SIZE_LOG2 ((sizeof(int) == 8) ? 6 : (sizeof(int) == 2) ? 4 : 5)
#endif

#define FCS_WHICH_STATES_GOOGLE_HASH__DENSE  0
#define FCS_WHICH_STATES_GOOGLE_HASH__SPARSE 1

#define FCS_WHICH_COLUMNS_GOOGLE_HASH__DENSE  0
#define FCS_WHICH_COLUMNS_GOOGLE_HASH__SPARSE 1

#define FCS_WHICH_COLUMNS_GOOGLE_HASH ${FCS_WHICH_COLUMNS_GOOGLE_HASH}
#define FCS_WHICH_STATES_GOOGLE_HASH ${FCS_WHICH_STATES_GOOGLE_HASH}

#if defined(FCS_RCS_STATES) && (!defined(COMPACT_STATES) )
#error FCS_RCS_STATES requires COMPACT_STATES
#endif

#ifdef __cplusplus
}
#endif

#endif    /* #ifndef FC_SOLVE__CONFIG_H */

