Created
March 8, 2016 16:26
-
-
Save drex44/91385edceb95a79841ba to your computer and use it in GitHub Desktop.
error while executing builder
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This file is released under the 3-clause BSD license. See COPYING-BSD. | |
function builder_gw_c() | |
includes_src_c = ilib_include_flag(get_absolute_file_path("builder_gateway_c.sce") + "../../src/c"); | |
// PutLhsVar managed by user in sci_sum and in sci_sub | |
// if you do not this variable, PutLhsVar is added | |
// in gateway generated (default mode in scilab 4.x and 5.x) | |
WITHOUT_AUTO_PUTLHSVAR = %t; | |
tbx_build_gateway("skeleton_c", .. | |
["scisha256","sha256_wrap"], .. | |
["sha256_wrap.c"], .. | |
get_absolute_file_path("builder_gateway_c.sce"), .. | |
["../../src/c/libcsum"], .. | |
"", .. | |
includes_src_c); | |
endfunction | |
builder_gw_c(); | |
clear builder_gw_c; // remove builder_gw_c on stack |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// This file is released under the 3-clause BSD license. See COPYING-BSD. | |
function builder_gw_c() | |
includes_src_c = ilib_include_flag(get_absolute_file_path("builder_gateway_c.sce") + "../../src/c"); | |
// PutLhsVar managed by user in sci_sum and in sci_sub | |
// if you do not this variable, PutLhsVar is added | |
// in gateway generated (default mode in scilab 4.x and 5.x) | |
WITHOUT_AUTO_PUTLHSVAR = %t; | |
tbx_build_gateway("skeleton_c", .. | |
["c_sum","sci_csum", "csci"; ... | |
"c_sub","sci_csub", "csci"; ... | |
"c_multiplybypi","sci_multiplybypi", "csci"; ... | |
"foo","sci_foo", "csci"; ... | |
"c_error","sci_cerror", "csci"; | |
"c_sum6","sci_csum6", "csci6"; ... | |
"c_sub6","sci_csub6", "csci6"; ... | |
"c_multiplybypi6","sci_multiplybypi6", "csci6"; ... | |
"foo6","sci_foo6", "csci6"; ... | |
"c_error6","sci_cerror6", "csci6"; ... | |
"scisha256","sha256_wrap",""], .. | |
["sci_csum.c","sci_csub.c","sci_multiplybypi.c","sci_foo.c","sci_cerror.c", ... | |
"sci_csum6.c","sci_csub6.c","sci_multiplybypi6.c","sci_foo6.c","sci_cerror6.c","sha256_wrap.c"], .. | |
get_absolute_file_path("builder_gateway_c.sce"), .. | |
["../../src/c/libcsum"], .. | |
"", .. | |
includes_src_c); | |
endfunction | |
builder_gw_c(); | |
clear builder_gw_c; // remove builder_gw_c on stack |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
xec builder_gateway_c.sce | |
--> // This file is released under the 3-clause BSD license. See COPYING-BSD. | |
--> function builder_gw_c() | |
--> includes_src_c = ilib_include_flag(get_absolute_file_path("builder_gateway_c.sce") + "../../src/c"); | |
--> // PutLhsVar managed by user in sci_sum and in sci_sub | |
--> // if you do not this variable, PutLhsVar is added | |
--> // in gateway generated (default mode in scilab 4.x and 5.x) | |
--> WITHOUT_AUTO_PUTLHSVAR = %t; | |
--> tbx_build_gateway("skeleton_c", .. | |
--> ["scisha256","sha256_wrap"], .. | |
--> ["sha256_wrap.c"], .. | |
--> get_absolute_file_path("builder_gateway_c.sce"), .. | |
--> ["../../src/c/libcsum"], .. | |
--> "", .. | |
--> includes_src_c); | |
--> endfunction | |
Warning : redefining function: builder_gw_c . Use funcprot(0) to avoid this message | |
--> builder_gw_c(); | |
Generate a gateway file | |
at line 125 of function ilib_gen_gateway ( /usr/local/share/scilab/modules/dynamic_link/macros/ilib_gen_gateway.sci line 146 ) | |
at line 88 of function ilib_build ( /usr/local/share/scilab/modules/dynamic_link/macros/ilib_build.sci line 101 ) | |
at line 134 of function tbx_build_gateway ( /usr/local/share/scilab/modules/modules_manager/macros/tbx_build_gateway.sci line 148 ) | |
at line 10 of function builder_gw_c ( /usr/local/share/scilab/contrib/toolbox_skeleton/sci_gateway/c/builder_gateway_c.sce line 12 ) | |
at line 22 of executed file /usr/local/share/scilab/contrib/toolbox_skeleton/sci_gateway/c/builder_gateway_c.sce | |
mputl: Cannot open file libskeleton_c.cpp. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
exec builder_gateway_c.sce | |
--> // This file is released under the 3-clause BSD license. See COPYING-BSD. | |
--> function builder_gw_c() | |
--> includes_src_c = ilib_include_flag(get_absolute_file_path("builder_gateway_c.sce") + "../../src/c"); | |
--> // PutLhsVar managed by user in sci_sum and in sci_sub | |
--> // if you do not this variable, PutLhsVar is added | |
--> // in gateway generated (default mode in scilab 4.x and 5.x) | |
--> WITHOUT_AUTO_PUTLHSVAR = %t; | |
--> tbx_build_gateway("skeleton_c", .. | |
--> ["c_sum","sci_csum", "csci"; ... | |
--> "c_sub","sci_csub", "csci"; ... | |
--> "c_multiplybypi","sci_multiplybypi", "csci"; ... | |
--> "foo","sci_foo", "csci"; ... | |
--> "c_error","sci_cerror", "csci"; | |
--> "c_sum6","sci_csum6", "csci6"; ... | |
--> "c_sub6","sci_csub6", "csci6"; ... | |
--> "c_multiplybypi6","sci_multiplybypi6", "csci6"; ... | |
--> "foo6","sci_foo6", "csci6"; ... | |
--> "c_error6","sci_cerror6", "csci6"; ... | |
--> "scisha256","sha256_wrap",""], .. | |
--> ["sci_csum.c","sci_csub.c","sci_multiplybypi.c","sci_foo.c","sci_cerror.c", ... | |
--> "sci_csum6.c","sci_csub6.c","sci_multiplybypi6.c","sci_foo6.c","sci_cerror6.c","sha256_wrap.c"], .. | |
--> get_absolute_file_path("builder_gateway_c.sce"), .. | |
--> ["../../src/c/libcsum"], .. | |
--> "", .. | |
--> includes_src_c); | |
--> endfunction | |
--> builder_gw_c(); | |
at line 55 of function ilib_build ( /usr/local/share/scilab/modules/dynamic_link/macros/ilib_build.sci line 68 ) | |
at line 134 of function tbx_build_gateway ( /usr/local/share/scilab/modules/modules_manager/macros/tbx_build_gateway.sci line 148 ) | |
at line 10 of function builder_gw_c ( /usr/local/share/scilab/contrib/toolbox_skeleton/sci_gateway/c/builder_gateway_c.sce line 12 ) | |
at line 33 of executed file /usr/local/share/scilab/contrib/toolbox_skeleton/sci_gateway/c/builder_gateway_c.sce | |
ilib_build: Wrong value for input argument #3: existing file(s) expected. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%module sha256 | |
%{ | |
#include "sha.h" | |
%} | |
%include "sha.h" | |
%inline %{ | |
char* sha256(char * string) { | |
unsigned char digest[SHA256_DIGEST_LENGTH]; | |
SHA256_CTX ctx; | |
SHA256_Init(&ctx); | |
SHA256_Update(&ctx, string, strlen(string)); | |
SHA256_Final(digest, &ctx); | |
static char mdString[SHA256_DIGEST_LENGTH*2+1]; | |
for (int i = 0; i < SHA256_DIGEST_LENGTH; i++) | |
sprintf(&mdString[i*2], "%02x", (unsigned int)digest[i]); | |
return (char *)mdString; | |
} | |
%} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment