lines(0);
function main_builder()
-
- setenv('DEBUG_SCILAB_DYNAMIC_LINK','YES')
TOOLBOX_NAME = "toolbox_skeleton";
TOOLBOX_TITLE = "Toolbox Skeleton";
toolbox_dir = get_absolute_file_path("builder.sce");
// =============================================================================
function ret = isRelease()
[a,b] = getversion();
- ret = b(4) == "release";
+ if or(getscilabmode() == ["NWNI", "SCILAB_API"]) then
+ ret = b(4) == "release";
+ else
+ ret = b(5) == "release";
+ end
endfunction
if ( nt <> 3 ) then
error(msprintf(gettext("%s: Wrong size for input argument #%d: %d expected.\n"),"ilib_gen_gateway",2,3));
end
- [gate,names,cppCompilation] = new_names(table);
+
global cppCompilation;
+ if isempty(cppCompilation) then
+ cppCompilation = %f;
+ end
+
+ [gate,names,cpp] = new_names(table);
+ cppCompilation = cppCompilation | cpp;
+
//generate cpp interface file
if cppCompilation then
t = [
"#define " + TNAME + "_GW_IMPEXP";
"#endif";
"";
+ "#include <cpp_gateway_prototype.hxx>";
+ "";
"extern ""C"" " + TNAME + "_GW_IMPEXP int " + tname + "(wchar_t* _pwstFuncName);";
"";
- gate(:, 2);
+ unique(gate(:, 2));
"";
"#endif /* __" + TNAME + "_GW_HXX__ */"];
"";
"#include ""c_gateway_prototype.h""";
"";
- gate(:, 1);
+ unique(gate(:, 1));
"";
"#endif /* __" + TNAME + "_GW_H__ */"];