# We make separate GOAL variables for each algorithm, to make it easy to
# switch each to the Legacy provider when needed.

$RSA_KEM_GOAL=../../libdefault.a ../../libfips.a
$EC_KEM_GOAL=../../libdefault.a
$TEMPLATE_KEM_GOAL=../../libtemplate.a
$ML_KEM_GOAL=../../libdefault.a ../../libfips.a
$TLS_ML_KEM_HYBRID_GOAL=../../libdefault.a ../../libfips.a

SOURCE[$RSA_KEM_GOAL]=rsa_kem.c

IF[{- !$disabled{ec} -}]
  SOURCE[$EC_KEM_GOAL]=kem_util.c ec_kem.c
  IF[{- !$disabled{ecx} -}]
    SOURCE[$EC_KEM_GOAL]=ecx_kem.c
  ENDIF
ENDIF

IF[{- !$disabled{'ml-kem'} -}]
  IF[{- !$disabled{ec} -}]
    SOURCE[$TLS_ML_KEM_HYBRID_GOAL]=mlx_kem.c
  ENDIF
  SOURCE[$ML_KEM_GOAL] = ml_kem_kem.c
ENDIF

SOURCE[$TEMPLATE_KEM_GOAL]=template_kem.c
