Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes to Map++ C API #2394

Merged
merged 5 commits into from
Aug 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions modules/map/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ target_sources(
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src/MAP_Types.h>
$<INSTALL_INTERFACE:mapsys.h>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src/mapsys.h>
$<INSTALL_INTERFACE:maperror.h>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src/maperror.h>
$<INSTALL_INTERFACE:mapapi.h>
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}/src/mapapi.h>
)
Expand Down
10 changes: 8 additions & 2 deletions modules/map/src/mapapi.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,17 @@
****************************************************************/


#include "mapapi.h"
#include "map.h"
#include "maperror.h"
#include "MAP_Types.h"
#include "mapapi.h"
#include "lineroutines.h"
#include "freedata.h"
#include "mapinit.h"
#include "outputstream.h"
#include "numeric.h"
#include "jacobian.h"
#include "residual.h"
#include <string.h>


MAP_EXTERNCALL void map_initialize_msqs_base(MAP_InputType_t* u_type,
Expand Down Expand Up @@ -1162,6 +1162,12 @@ MAP_EXTERNCALL void map_set_gravity(MAP_ParameterType_t* p_type, const double gr
p_type->g = gravity;
};

MAP_EXTERNCALL void map_set_input_text(MAP_InitInputType_t* init_type, const char* input_txt_line)
{
strncpy(init_type->library_input_str, input_txt_line, 254);
init_type->library_input_str[254] = '\0';
}


MAP_EXTERNCALL void map_add_cable_library_input_text(MAP_InitInputType_t* init_type)
{
Expand Down
Loading