Archived OpenModelica forums. Posting is disabled.

Alternative forums include GitHub discussions or StackOverflow (make sure to read the Stack Overflow rules; you need to have well-formed questions)


Forgot password? | Forgot username? | Register

MAC - Error building simulator

MAC - Error building simulator

Hello,

I just downloaded the OpenModelica Package for mac and tried the first tutorial simulation, the DC Motor in OMEdit. If I try to simulate, i get following error.
Does anybody know an easy fix for this problem?



thanks, Jonas


getSimulationOptions(checkj)
{0.0, 1.0, 500, 0.000001, "dassl", "checkj", false, false, "", "mat", ".*", false, "", ""} /* startTime, stopTime, numberOfIntervals, tolerance, method, fileNamePrefix, storeInTemp, noClean, options, outputFormat */

buildModel(checkj,startTime=0.0, stopTime=1.0, numberOfIntervals=500, method="dassl", tolerance=0.000001, outputFormat="mat")
{"",""}

errors:=getMessagesStringInternal()
{record .OpenModelica.Scripting.ErrorMessage
    info = record .OpenModelica.Scripting.SourceInfo
    filename = "",
    readonly = false,
    lineStart = 0,
    columnStart = 0,
    lineEnd = 0,
    columnEnd = 0
end .OpenModelica.Scripting.SourceInfo;,
    message = "Error building simulator. Buildlog: /opt/openmodelica/bin/gcc-mp-4.4  -O3 -falign-functions -msse2 -mfpmath=sse   -I\"/opt/openmodelica/include/omc\" -I.    -c -o checkj.o checkj.c
In file included from /opt/openmodelica/include/omc/openmodelica.h:45,
                 from checkj.c:3:
/opt/openmodelica/include/omc/stdlib.h:32:23: error: tr1/cstdlib: No such file or directory
In file included from checkj.c:3:
/opt/openmodelica/include/omc/openmodelica.h:46:19: error: stdio.h: No such file or directory
In file included from /opt/openmodelica/lib/gcc44/gcc/x86_64-apple-darwin11/4.4.7/include-fixed/syslimits.h:7,
                 from /opt/openmodelica/lib/gcc44/gcc/x86_64-apple-darwin11/4.4.7/include-fixed/limits.h:11,
                 from /opt/openmodelica/include/omc/openmodelica.h:47,
                 from checkj.c:3:
/opt/openmodelica/lib/gcc44/gcc/x86_64-apple-darwin11/4.4.7/include-fixed/limits.h:122:61: error: limits.h: No such file or directory
In file included from checkj.c:3:
/opt/openmodelica/include/omc/openmodelica.h:48:20: error: assert.h: No such file or directory
/opt/openmodelica/include/omc/openmodelica.h:86:20: error: unistd.h: No such file or directory
In file included from checkj.c:3:
/opt/openmodelica/include/omc/openmodelica.h:230: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/openmodelica.h:236: error: expected specifier-qualifier-list before 'size_t'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:48,
                 from checkj.c:4:
/opt/openmodelica/include/omc/index_spec.h:46: error: expected ';', ',' or ')' before '*' token
In file included from /opt/openmodelica/include/omc/boolean_array.h:36,
                 from /opt/openmodelica/include/omc/openmodelica_func.h:49,
                 from checkj.c:4:
/opt/openmodelica/include/omc/base_array.h:49: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'alloc_base_array'
/opt/openmodelica/include/omc/base_array.h:52: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'base_array_nr_of_elements'
/opt/openmodelica/include/omc/base_array.h:69: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'calc_base_index_spec'
/opt/openmodelica/include/omc/base_array.h:71: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'calc_base_index'
/opt/openmodelica/include/omc/base_array.h:72: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'calc_base_index_va'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:49,
                 from checkj.c:4:
/opt/openmodelica/include/omc/boolean_array.h:41: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:43: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:43: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:170: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'boolean_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:50,
                 from checkj.c:4:
/opt/openmodelica/include/omc/integer_array.h:42: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:44: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:44: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:46: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:46: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:46: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:50,
                 from checkj.c:4:
/opt/openmodelica/include/omc/integer_array.h:253: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'integer_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:51,
                 from checkj.c:4:
/opt/openmodelica/include/omc/real_array.h:43: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:224: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'real_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:52,
                 from checkj.c:4:
/opt/openmodelica/include/omc/string_array.h:40: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/string_array.h:168: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'string_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:56,
                 from checkj.c:4:
/opt/openmodelica/include/omc/utility.h:37:18: error: math.h: No such file or directory
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:56,
                 from checkj.c:4:
/opt/openmodelica/include/omc/utility.h: In function 'modelica_mod_real':
/opt/openmodelica/include/omc/utility.h:83: warning: incompatible implicit declaration of built-in function 'floor'
In file included from checkj.c:7:
/opt/openmodelica/include/omc/omc_error.h:36:20: error: setjmp.h: No such file or directory
In file included from checkj.c:7:
/opt/openmodelica/include/omc/omc_error.h: At top level:
/opt/openmodelica/include/omc/omc_error.h:46: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'globalJmpbuf'
checkj.c:10:20: error: string.h: No such file or directory
In file included from /opt/openmodelica/include/omc/modelica.h:96,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/read_write.h:38:19: error: errno.h: No such file or directory
In file included from /opt/openmodelica/include/omc/modelica.h:96,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/read_write.h:87: error: expected declaration specifiers or '...' before 'size_t'
In file included from /opt/openmodelica/include/omc/gc.h:58,
                 from /opt/openmodelica/include/omc/meta_modelica.h:46,
                 from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/common.h:88: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:112: error: expected ')' before 'number_of_pages'
/opt/openmodelica/include/omc/common.h:130: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:151: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:158: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:166: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:178: error: expected ')' before 'default_free_slots_size'
/opt/openmodelica/include/omc/common.h:179: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:180: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'list_length'
/opt/openmodelica/include/omc/common.h:181: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'list_size'
/opt/openmodelica/include/omc/common.h:182: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:205: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:212: error: expected ')' before 'default_stack_size'
/opt/openmodelica/include/omc/common.h:216: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'stack_peek'
/opt/openmodelica/include/omc/common.h:218: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'stack_pop'
/opt/openmodelica/include/omc/common.h:220: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:222: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:237: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:247: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:253: error: expected ')' before 'default_pages_size'
In file included from /opt/openmodelica/include/omc/gc.h:58,
                 from /opt/openmodelica/include/omc/meta_modelica.h:46,
                 from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/common.h:257: error: expected ')' before 'default_page_size'
/opt/openmodelica/include/omc/common.h:259: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:261: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:267: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'pages_list_length'
/opt/openmodelica/include/omc/common.h:268: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'pages_list_size'
In file included from /opt/openmodelica/include/omc/gc.h:59,
                 from /opt/openmodelica/include/omc/meta_modelica.h:46,
                 from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/roots.h:53: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/roots.h:61: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/roots.h:70: error: expected ')' before 'default_roots_size'
/opt/openmodelica/include/omc/roots.h:72: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/roots.h:74: error: expected declaration specifiers or '...' before 'size_t'
In file included from /opt/openmodelica/include/omc/gc.h:61,
                 from /opt/openmodelica/include/omc/meta_modelica.h:46,
                 from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/marksweep.h:75: error: expected specifier-qualifier-list before 'size_t'
In file included from /opt/openmodelica/include/omc/meta_modelica.h:46,
                 from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/gc.h:80: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/gc.h:115: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'dummy_local_GC_state'
In file included from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/meta_modelica.h: In function 'mmc_mk_scon':
/opt/openmodelica/include/omc/meta_modelica.h:262: warning: incompatible implicit declaration of built-in function 'strlen'
/opt/openmodelica/include/omc/meta_modelica.h:274: warning: incompatible implicit declaration of built-in function 'memcpy'
In file included from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/meta_modelica.h: At top level:
/opt/openmodelica/include/omc/meta_modelica.h:628: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
In file included from /opt/openmodelica/include/omc/modelica.h:101,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/varinfo.h:43: error: expected ')' before '*' token
checkj.c: In function 'setupDataStruc':
checkj.c:30: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:30: error: 'stderr' undeclared (first use in this function)
checkj.c:30: error: (Each undeclared identifier is reported only once
checkj.c:30: error: for each function it appears in.)
checkj.c:30: error: 'NULL' undeclared (first use in this function)
checkj.c:30: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:30: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:30: error: 'globalJmpbuf' undeclared (first use in this function)
checkj.c: In function 'setupDataStruc2':
checkj.c:70: warning: incompatible implicit declaration of built-in function 'memcpy'
checkj.c:72: warning: incompatible implicit declaration of built-in function 'calloc'
checkj.c:75: error: 'NULL' undeclared (first use in this function)
checkj.c:86: warning: incompatible implicit declaration of built-in function 'malloc'
checkj.c: In function 'callExternalObjectDestructors':
checkj.c:101: warning: incompatible implicit declaration of built-in function 'free'
checkj.c: In function 'updateBoundStartValues':
checkj.c:147: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:147: error: 'stdout' undeclared (first use in this function)
checkj.c:147: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:147: error: 'NULL' undeclared (first use in this function)
checkj.c: In function 'initial_residual':
checkj.c:158: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:158: error: 'stdout' undeclared (first use in this function)
checkj.c:158: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:158: error: 'NULL' undeclared (first use in this function)
checkj.c: At top level:
checkj.c:262: error: 'NULL' undeclared here (not in a function)
gmake: *** [checkj.o] Fehler 1
",
    kind = .OpenModelica.Scripting.ErrorKind.translation,
    level = .OpenModelica.Scripting.ErrorLevel.error,
    id = 22
end .OpenModelica.Scripting.ErrorMessage;}

size(errors,1)
1

currentError:=errors[1]
record .OpenModelica.Scripting.ErrorMessage
    info = record .OpenModelica.Scripting.SourceInfo
    filename = "",
    readonly = false,
    lineStart = 0,
    columnStart = 0,
    lineEnd = 0,
    columnEnd = 0
end .OpenModelica.Scripting.SourceInfo;,
    message = "Error building simulator. Buildlog: /opt/openmodelica/bin/gcc-mp-4.4  -O3 -falign-functions -msse2 -mfpmath=sse   -I\"/opt/openmodelica/include/omc\" -I.    -c -o checkj.o checkj.c
In file included from /opt/openmodelica/include/omc/openmodelica.h:45,
                 from checkj.c:3:
/opt/openmodelica/include/omc/stdlib.h:32:23: error: tr1/cstdlib: No such file or directory
In file included from checkj.c:3:
/opt/openmodelica/include/omc/openmodelica.h:46:19: error: stdio.h: No such file or directory
In file included from /opt/openmodelica/lib/gcc44/gcc/x86_64-apple-darwin11/4.4.7/include-fixed/syslimits.h:7,
                 from /opt/openmodelica/lib/gcc44/gcc/x86_64-apple-darwin11/4.4.7/include-fixed/limits.h:11,
                 from /opt/openmodelica/include/omc/openmodelica.h:47,
                 from checkj.c:3:
/opt/openmodelica/lib/gcc44/gcc/x86_64-apple-darwin11/4.4.7/include-fixed/limits.h:122:61: error: limits.h: No such file or directory
In file included from checkj.c:3:
/opt/openmodelica/include/omc/openmodelica.h:48:20: error: assert.h: No such file or directory
/opt/openmodelica/include/omc/openmodelica.h:86:20: error: unistd.h: No such file or directory
In file included from checkj.c:3:
/opt/openmodelica/include/omc/openmodelica.h:230: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/openmodelica.h:236: error: expected specifier-qualifier-list before 'size_t'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:48,
                 from checkj.c:4:
/opt/openmodelica/include/omc/index_spec.h:46: error: expected ';', ',' or ')' before '*' token
In file included from /opt/openmodelica/include/omc/boolean_array.h:36,
                 from /opt/openmodelica/include/omc/openmodelica_func.h:49,
                 from checkj.c:4:
/opt/openmodelica/include/omc/base_array.h:49: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'alloc_base_array'
/opt/openmodelica/include/omc/base_array.h:52: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'base_array_nr_of_elements'
/opt/openmodelica/include/omc/base_array.h:69: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'calc_base_index_spec'
/opt/openmodelica/include/omc/base_array.h:71: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'calc_base_index'
/opt/openmodelica/include/omc/base_array.h:72: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'calc_base_index_va'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:49,
                 from checkj.c:4:
/opt/openmodelica/include/omc/boolean_array.h:41: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:43: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:43: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:170: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'boolean_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:50,
                 from checkj.c:4:
/opt/openmodelica/include/omc/integer_array.h:42: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:44: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:44: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:46: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:46: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:46: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:50,
                 from checkj.c:4:
/opt/openmodelica/include/omc/integer_array.h:253: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'integer_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:51,
                 from checkj.c:4:
/opt/openmodelica/include/omc/real_array.h:43: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:224: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'real_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:52,
                 from checkj.c:4:
/opt/openmodelica/include/omc/string_array.h:40: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/string_array.h:168: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'string_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:56,
                 from checkj.c:4:
/opt/openmodelica/include/omc/utility.h:37:18: error: math.h: No such file or directory
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:56,
                 from checkj.c:4:
/opt/openmodelica/include/omc/utility.h: In function 'modelica_mod_real':
/opt/openmodelica/include/omc/utility.h:83: warning: incompatible implicit declaration of built-in function 'floor'
In file included from checkj.c:7:
/opt/openmodelica/include/omc/omc_error.h:36:20: error: setjmp.h: No such file or directory
In file included from checkj.c:7:
/opt/openmodelica/include/omc/omc_error.h: At top level:
/opt/openmodelica/include/omc/omc_error.h:46: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'globalJmpbuf'
checkj.c:10:20: error: string.h: No such file or directory
In file included from /opt/openmodelica/include/omc/modelica.h:96,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/read_write.h:38:19: error: errno.h: No such file or directory
In file included from /opt/openmodelica/include/omc/modelica.h:96,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/read_write.h:87: error: expected declaration specifiers or '...' before 'size_t'
In file included from /opt/openmodelica/include/omc/gc.h:58,
                 from /opt/openmodelica/include/omc/meta_modelica.h:46,
                 from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/common.h:88: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:112: error: expected ')' before 'number_of_pages'
/opt/openmodelica/include/omc/common.h:130: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:151: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:158: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:166: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:178: error: expected ')' before 'default_free_slots_size'
/opt/openmodelica/include/omc/common.h:179: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:180: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'list_length'
/opt/openmodelica/include/omc/common.h:181: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'list_size'
/opt/openmodelica/include/omc/common.h:182: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:205: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:212: error: expected ')' before 'default_stack_size'
/opt/openmodelica/include/omc/common.h:216: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'stack_peek'
/opt/openmodelica/include/omc/common.h:218: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'stack_pop'
/opt/openmodelica/include/omc/common.h:220: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:222: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:237: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:247: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:253: error: expected ')' before 'default_pages_size'
In file included from /opt/openmodelica/include/omc/gc.h:58,
                 from /opt/openmodelica/include/omc/meta_modelica.h:46,
                 from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/common.h:257: error: expected ')' before 'default_page_size'
/opt/openmodelica/include/omc/common.h:259: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:261: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/common.h:267: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'pages_list_length'
/opt/openmodelica/include/omc/common.h:268: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'pages_list_size'
In file included from /opt/openmodelica/include/omc/gc.h:59,
                 from /opt/openmodelica/include/omc/meta_modelica.h:46,
                 from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/roots.h:53: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/roots.h:61: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/roots.h:70: error: expected ')' before 'default_roots_size'
/opt/openmodelica/include/omc/roots.h:72: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/roots.h:74: error: expected declaration specifiers or '...' before 'size_t'
In file included from /opt/openmodelica/include/omc/gc.h:61,
                 from /opt/openmodelica/include/omc/meta_modelica.h:46,
                 from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/marksweep.h:75: error: expected specifier-qualifier-list before 'size_t'
In file included from /opt/openmodelica/include/omc/meta_modelica.h:46,
                 from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/gc.h:80: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/gc.h:115: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'dummy_local_GC_state'
In file included from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/meta_modelica.h: In function 'mmc_mk_scon':
/opt/openmodelica/include/omc/meta_modelica.h:262: warning: incompatible implicit declaration of built-in function 'strlen'
/opt/openmodelica/include/omc/meta_modelica.h:274: warning: incompatible implicit declaration of built-in function 'memcpy'
In file included from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/meta_modelica.h: At top level:
/opt/openmodelica/include/omc/meta_modelica.h:628: error: expected '=', ',', ';', 'asm' or '__attribute__' before '*' token
In file included from /opt/openmodelica/include/omc/modelica.h:101,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/varinfo.h:43: error: expected ')' before '*' token
checkj.c: In function 'setupDataStruc':
checkj.c:30: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:30: error: 'stderr' undeclared (first use in this function)
checkj.c:30: error: (Each undeclared identifier is reported only once
checkj.c:30: error: for each function it appears in.)
checkj.c:30: error: 'NULL' undeclared (first use in this function)
checkj.c:30: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:30: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:30: error: 'globalJmpbuf' undeclared (first use in this function)
checkj.c: In function 'setupDataStruc2':
checkj.c:70: warning: incompatible implicit declaration of built-in function 'memcpy'
checkj.c:72: warning: incompatible implicit declaration of built-in function 'calloc'
checkj.c:75: error: 'NULL' undeclared (first use in this function)
checkj.c:86: warning: incompatible implicit declaration of built-in function 'malloc'
checkj.c: In function 'callExternalObjectDestructors':
checkj.c:101: warning: incompatible implicit declaration of built-in function 'free'
checkj.c: In function 'updateBoundStartValues':
checkj.c:147: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:147: error: 'stdout' undeclared (first use in this function)
checkj.c:147: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:147: error: 'NULL' undeclared (first use in this function)
checkj.c: In function 'initial_residual':
checkj.c:158: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:158: error: 'stdout' undeclared (first use in this function)
checkj.c:158: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:158: error: 'NULL' undeclared (first use in this function)
checkj.c: At top level:
checkj.c:262: error: 'NULL' undeclared here (not in a function)
gmake: *** [checkj.o] Fehler 1
",
    kind = .OpenModelica.Scripting.ErrorKind.translation,
    level = .OpenModelica.Scripting.ErrorLevel.error,
    id = 22
end .OpenModelica.Scripting.ErrorMessage;

currentError.info.filename
""

currentError.info.readonly
false

currentError.info.lineStart
0

currentError.info.columnStart
0

currentError.info.lineEnd
0

currentError.info.columnEnd
0

currentError.message
"Error building simulator. Buildlog: /opt/openmodelica/bin/gcc-mp-4.4  -O3 -falign-functions -msse2 -mfpmath=sse   -I\"/opt/openmodelica/include/omc\" -I.    -c -o checkj.o checkj.c
In file included from /opt/openmodelica/include/omc/openmodelica.h:45,
                 from checkj.c:3:
/opt/openmodelica/include/omc/stdlib.h:32:23: error: tr1/cstdlib: No such file or directory
In file included from checkj.c:3:
/opt/openmodelica/include/omc/openmodelica.h:46:19: error: stdio.h: No such file or directory
In file included from /opt/openmodelica/lib/gcc44/gcc/x86_64-apple-darwin11/4.4.7/include-fixed/syslimits.h:7,
                 from /opt/openmodelica/lib/gcc44/gcc/x86_64-apple-darwin11/4.4.7/include-fixed/limits.h:11,
                 from /opt/openmodelica/include/omc/openmodelica.h:47,
                 from checkj.c:3:
/opt/openmodelica/lib/gcc44/gcc/x86_64-apple-darwin11/4.4.7/include-fixed/limits.h:122:61: error: limits.h: No such file or directory
In file included from checkj.c:3:
/opt/openmodelica/include/omc/openmodelica.h:48:20: error: assert.h: No such file or directory
/opt/openmodelica/include/omc/openmodelica.h:86:20: error: unistd.h: No such file or directory
In file included from checkj.c:3:
/opt/openmodelica/include/omc/openmodelica.h:230: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/openmodelica.h:236: error: expected specifier-qualifier-list before 'size_t'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:48,
                 from checkj.c:4:
/opt/openmodelica/include/omc/index_spec.h:46: error: expected ';', ',' or ')' before '*' token
In file included from /opt/openmodelica/include/omc/boolean_array.h:36,
                 from /opt/openmodelica/include/omc/openmodelica_func.h:49,
                 from checkj.c:4:
/opt/openmodelica/include/omc/base_array.h:49: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'alloc_base_array'
/opt/openmodelica/include/omc/base_array.h:52: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'base_array_nr_of_elements'
/opt/openmodelica/include/omc/base_array.h:69: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'calc_base_index_spec'
/opt/openmodelica/include/omc/base_array.h:71: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'calc_base_index'
/opt/openmodelica/include/omc/base_array.h:72: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'calc_base_index_va'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:49,
                 from checkj.c:4:
/opt/openmodelica/include/omc/boolean_array.h:41: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:43: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:43: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/boolean_array.h:170: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'boolean_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:50,
                 from checkj.c:4:
/opt/openmodelica/include/omc/integer_array.h:42: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:44: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:44: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:46: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:46: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:46: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/integer_array.h:48: error: expected declaration specifiers or '...' before 'size_t'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:50,
                 from checkj.c:4:
/opt/openmodelica/include/omc/integer_array.h:253: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'integer_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:51,
                 from checkj.c:4:
/opt/openmodelica/include/omc/real_array.h:43: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:45: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:47: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:49: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/real_array.h:224: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'real_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:52,
                 from checkj.c:4:
/opt/openmodelica/include/omc/string_array.h:40: error: expected declaration specifiers or '...' before 'size_t'
/opt/openmodelica/include/omc/string_array.h:168: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'string_array_nr_of_elements'
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:56,
                 from checkj.c:4:
/opt/openmodelica/include/omc/utility.h:37:18: error: math.h: No such file or directory
In file included from /opt/openmodelica/include/omc/openmodelica_func.h:56,
                 from checkj.c:4:
/opt/openmodelica/include/omc/utility.h: In function 'modelica_mod_real':
/opt/openmodelica/include/omc/utility.h:83: warning: incompatible implicit declaration of built-in function 'floor'
In file included from checkj.c:7:
/opt/openmodelica/include/omc/omc_error.h:36:20: error: setjmp.h: No such file or directory
In file included from checkj.c:7:
/opt/openmodelica/include/omc/omc_error.h: At top level:
/opt/openmodelica/include/omc/omc_error.h:46: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'globalJmpbuf'
checkj.c:10:20: error: string.h: No such file or directory
In file included from /opt/openmodelica/include/omc/modelica.h:96,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/read_write.h:38:19: error: errno.h: No such file or directory
In file included from /opt/openmodelica/include/omc/modelica.h:96,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/read_write.h:87: error: expected declaration specifiers or '...' before 'size_t'
In file included from /opt/openmodelica/include/omc/gc.h:58,
                 from /opt/openmodelica/include/omc/meta_modelica.h:46,
                 from /opt/openmodelica/include/omc/modelica.h:98,
                 from checkj_functions.h:4,
                 from checkj.c:12:
/opt/openmodelica/include/omc/common.h:88: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:112: error: expected ')' before 'number_of_pages'
/opt/openmodelica/include/omc/common.h:130: error: expected specifier-qualifier-list before 'size_t'
/opt/openmodelica/include/omc/common.h:151: error: expected specifier-qualifier-list before 'size_t'
.....
and so on
.....
checkj.c: In function 'callExternalObjectDestructors':
checkj.c:101: warning: incompatible implicit declaration of built-in function 'free'
checkj.c: In function 'updateBoundStartValues':
checkj.c:147: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:147: error: 'stdout' undeclared (first use in this function)
checkj.c:147: warning: incompatible implicit declaration of built-in function 'fprintf'
checkj.c:147: error: 'NULL

Re: MAC - Error building simulator

If you do not have /usr/include/stdio.h, I suppose you do not have XCode installed for the system headers.

Re: MAC - Error building simulator

Thank you for the fast answer, I just installed Xcode, but still the same problem. do I have to reinstall OpenModelica?


or is it a path problem:
If I search for stdio.h i find it in:

opt/openmodelica/include/gcc44/c++/tr1.stdio.h
and
opt/openmodelica/include/gcc44/gcc/x86_64-apple-darwin11/4.4.7/include/ssp/stdio.h

thanks

Re: MAC - Error building simulator

I am fairly sure those stdio files try to use the system headers. So your XCode does not install /usr/include/stdio.h? How does it compile simple C-files then?

Code:

$ echo -e '#include <stdio.h>\nint main() {puts("abc\\n");}' | /opt/openmodelica/bin/gcc-mp-4.4 -xc - && ./a.out 

Code:

$ echo -e '#include <stdio.h>\nint main() {puts("abc\\n");}' | cc -xc - && ./a.out 

Re: MAC - Error building simulator

Hey, now it worked, somehow the header files were missing. After installing the XCode command line tools in preferences/downloads it worked.
thanks for your help and a good day!!
jonas

There are 0 guests and 0 other users also viewing this topic
You are here: