Fix the OSX build
Fix the OSX build

Apple does not support staticaly built applications on OSX, and all
dynamically built apps have to be linked against the System lib
(i.e., `-static` should not be used and `-lSystem` is a must).
As System contains all libc and libm functions, building (and
linking) the minimal jerry-libc and jerry-libm libs makes no sense.
Moreover, if JERRY_LIBC is ON, the compiler will use the jerry-libc
headers but will link the libc functions from System, which causes
heavy confusion and segfaults at run time.

Thus, this patch changes the build system to disable the building
of jerry-libc and jerry-libm, and enables the use of system
libraries when building on OSX.

JerryScript-DCO-1.0-Signed-off-by: Akos Kiss akiss@inf.u-szeged.hu

loki04/jerryscript,LeeHayun/jerryscript,LaszloLango/jerryscript,glistening/jerryscript,zherczeg/jerryscript,jerryscript-project/jerryscript,grgustaf/jerryscript,jack60504/jerryscript,dbatyai/jerryscript,tilmannOSG/jerryscript,martijnthe/jerryscript,slaff/jerryscript,grgustaf/jerryscript,bsdelf/jerryscript,yichoi/jerryscript,loki04/jerryscript,LaszloLango/jerryscript,slaff/jerryscript,tilmannOSG/jerryscript,grgustaf/jerryscript,martijnthe/jerryscript,glistening/jerryscript,dbatyai/jerryscript,bzsolt/jerryscript,yichoi/jerryscript,gabrielschulhof/jerryscript,jack60504/jerryscript,bsdelf/jerryscript,jack60504/jerryscript,LeeHayun/jerryscript,jerryscript-project/jerryscript,martijnthe/jerryscript,yichoi/jerryscript,bzsolt/jerryscript,grgustaf/jerryscript,akosthekiss/jerryscript,gabrielschulhof/jerryscript,yichoi/jerryscript,martijnthe/jerryscript,zherczeg/jerryscript,bsdelf/jerryscript,tilmannOSG/jerryscript,akosthekiss/jerryscript,tilmannOSG/jerryscript,akosthekiss/jerryscript,grgustaf/jerryscript,jack60504/jerryscript,robertsipka/jerryscript,jack60504/jerryscript,akosthekiss/jerryscript,zherczeg/jerryscript,martijnthe/jerryscript,martijnthe/jerryscript,bzsolt/jerryscript,grgustaf/jerryscript,bzsolt/jerryscript,dbatyai/jerryscript,yichoi/jerryscript,slaff/jerryscript,robertsipka/jerryscript,slaff/jerryscript,bsdelf/jerryscript,glistening/jerryscript,LaszloLango/jerryscript,bsdelf/jerryscript,LaszloLango/jerryscript,jerryscript-project/jerryscript,loki04/jerryscript,gabrielschulhof/jerryscript,dbatyai/jerryscript,dbatyai/jerryscript,bsdelf/jerryscript,LeeHayun/jerryscript,bzsolt/jerryscript,loki04/jerryscript,slaff/jerryscript,zherczeg/jerryscript,loki04/jerryscript,jerryscript-project/jerryscript,LeeHayun/jerryscript,tilmannOSG/jerryscript,robertsipka/jerryscript,LaszloLango/jerryscript,akosthekiss/jerryscript,robertsipka/jerryscript,glistening/jerryscript,glistening/jerryscript,robertsipka/jerryscript,jack60504/jerryscript,LeeHayun/jerryscript,jerryscript-project/jerryscript,zherczeg/jerryscript,gabrielschulhof/jerryscript,gabrielschulhof/jerryscript,robertsipka/jerryscript,loki04/jerryscript,glistening/jerryscript