SoarGroup / Soar

Soar, a general cognitive architecture for systems that exhibit intelligent behavior.
http://soar.eecs.umich.edu
Other
322 stars 70 forks source link

compile SVS tests in CI #476

Open garfieldnate opened 3 days ago

garfieldnate commented 3 days ago

There's an SConstruct file under Core/SVS/tests. I tried calling SConstruct() on it from the SVS SConstruct file and importing env followed by calling env.Append with all of its environment arguments, but it still fails to build with this message:

Core/SVS/src/serialize.cpp:87:15: error: use of undeclared identifier 'SNPRINTF'
    int res = SNPRINTF(buf, buf_len, "%a", v);

SNPRINTF is defined in Core/shared/portability.h, which should actually be included given the clang call I see printed:

clang++ -o /Users/nathanglenn/build/svs2/serialize.o -c -std=c++17 -Wunused-variable -Wreorder -g -fvisibility=hidden -DGCC_HASCLASSVISIBILITY -g -Wno-enum-compare -ICore/shared -ICore/SoarKernel/src/debug_code -ICore/SoarKernel/src/decision_process -ICore/SoarKernel/src/episodic_memory -ICore/SoarKernel/src/explanation_memory -ICore/SoarKernel/src/explanation_based_chunking -ICore/SoarKernel/src/interface -ICore/SoarKernel/src/output_manager -ICore/SoarKernel/src/parsing -ICore/SoarKernel/src/reinforcement_learning -ICore/SoarKernel/src/semantic_memory -ICore/SoarKernel/src/shared -ICore/SoarKernel/src/soar_representation -ICore/SoarKernel/src/visualizer -ICore/ElementXML/src -ICore/KernelSML/src -ICore/ConnectionSML/src -ICore/ClientSML/src -ICore/CLI/src -Ibuild/Core/SVS/src -ICore/SVS/src -Ibuild/Core/SVS/src/algorithms -ICore/SVS/src/algorithms -Ibuild/Core/SVS/src/models -ICore/SVS/src/models -Ibuild/Core/SVS/src/posix -ICore/SVS/src/posix -Ibuild/Core/SVS/eigen -ICore/SVS/eigen Core/SVS/src/serialize.cpp

However, build/Core/shared only contains shared.os (a .o file marked by SCons for usage in a shared library), while what we need is the original .h file, which contains the required #define. I don't know exactly the changes to make to the SConstruct() call right now and it's not pressing, so I'm setting it aside for now.