File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -71,10 +71,11 @@ if(CLR_CMAKE_PLATFORM_UNIX)
7171
7272 set (CMAKE_CXX_STANDARD 11)
7373
74- add_compile_options (
75- -fms-extensions
76- -fdelayed-template-parsing
77- -msse4.1
74+ set (c_warn_flags
75+ -Wno-implicit-function-declaration
76+ )
77+
78+ set (cxx_warn_flags
7879 -Wno-microsoft
7980 -Wno-unused-value
8081 -Wno-int-to-void-pointer-cast
@@ -96,6 +97,18 @@ if(CLR_CMAKE_PLATFORM_UNIX)
9697 -Wno-switch # switch values not handled
9798 -Wno-int-to-pointer-cast
9899 )
100+
101+ set (cxx_compile_flags
102+ -fdelayed-template-parsing
103+ )
104+
105+ add_compile_options (
106+ -fms-extensions
107+ -msse4.1
108+ "$<$<COMPILE_LANGUAGE :C >:${c_warn_flags} >"
109+ "$<$<COMPILE_LANGUAGE :CXX >:${cxx_warn_flags} >"
110+ "$<$<COMPILE_LANGUAGE :CXX >:${cxx_compile_flags} >"
111+ )
99112endif (CLR_CMAKE_PLATFORM_UNIX )
100113
101114if (CMAKE_BUILD_TYPE STREQUAL Debug)
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ target_include_directories (
3333# icuuc: For the ICU (xplat-todo: Make this optional)
3434#
3535target_link_libraries (ChakraCore
36- -Wl,-undefined,error
36+ -Wl,--no- undefined
3737 -Wl,--start-group
3838 -Wl,--whole-archive
3939 Chakra.Jsrt
@@ -70,4 +70,4 @@ target_link_libraries(ChakraCore
7070add_custom_command (TARGET ChakraCore POST_BUILD
7171 COMMAND ${CMAKE_COMMAND} -E copy_if_different
7272 "${CHAKRACORE_BINARY_DIR} /bin/ChakraCore/libChakraCore.so"
73- ${CHAKRACORE_BINARY_DIR} / )
73+ ${CHAKRACORE_BINARY_DIR} / )
Original file line number Diff line number Diff line change @@ -4848,7 +4848,11 @@ namespace Js
48484848 void FunctionBody::SetEntryToDeferParseForDebugger ()
48494849 {
48504850 ProxyEntryPointInfo* defaultEntryPointInfo = this ->GetDefaultEntryPointInfo ();
4851- if (defaultEntryPointInfo->jsMethod != DefaultDeferredParsingThunk && defaultEntryPointInfo->jsMethod != ProfileDeferredParsingThunk)
4851+ if (defaultEntryPointInfo->jsMethod != DefaultDeferredParsingThunk
4852+ #ifdef ENABLE_SCRIPT_PROFILING
4853+ && defaultEntryPointInfo->jsMethod != ProfileDeferredParsingThunk
4854+ #endif
4855+ )
48524856 {
48534857#ifdef ENABLE_SCRIPT_PROFILING
48544858 // Just change the thunk, the cleanup will be done once the function gets called.
Original file line number Diff line number Diff line change @@ -2998,10 +2998,12 @@ namespace Js
29982998 ULONG * line, LONG * col);
29992999#endif
30003000
3001+ #ifdef ENABLE_SCRIPT_PROFILING
30013002 HRESULT RegisterFunction (BOOL fChangeMode , BOOL fOnlyCurrent = FALSE );
30023003 HRESULT ReportScriptCompiled ();
30033004 HRESULT ReportFunctionCompiled ();
30043005 void SetEntryToProfileMode ();
3006+ #endif
30053007
30063008 void CheckAndRegisterFuncToDiag (ScriptContext *scriptContext);
30073009 void SetEntryToDeferParseForDebugger ();
Original file line number Diff line number Diff line change 11project (CHAKRA_RUNTIME)
22
33include_directories (
4- $ ( CHAKRA_RUNTIME_SOURCE_DIR )
5- $ ( CHAKRA_RUNTIME_SOURCE_DIR ) ../Common
6- $ ( CHAKRA_RUNTIME_SOURCE_DIR ) ../Backend
7- $ ( CHAKRA_RUNTIME_SOURCE_DIR ) ../Parser
8- $ ( CHAKRA_RUNTIME_SOURCE_DIR ) / ByteCode
9- $ ( CHAKRA_RUNTIME_SOURCE_DIR ) / PlatformAgnostic
10- $ ( CHAKRA_RUNTIME_SOURCE_DIR ) / Math
4+ .
5+ ../Common
6+ ../Backend
7+ ../Parser
8+ ByteCode
9+ PlatformAgnostic
10+ Math
1111 )
1212
1313add_subdirectory (Base )
Original file line number Diff line number Diff line change 1+ //-------------------------------------------------------------------------------------------------------
2+ // Copyright (C) Microsoft. All rights reserved.
3+ // Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
4+ //-------------------------------------------------------------------------------------------------------
5+
6+ function say ( arg )
7+ {
8+ WScript . Echo ( arg ) ;
9+ }
10+
11+ say ( "hello world" ) ;
12+ say ( "PASS" ) ;
Original file line number Diff line number Diff line change 1+ # -------------------------------------------------------------------------------------------------------
2+ # Copyright (C) Microsoft. All rights reserved.
3+ # Licensed under the MIT license. See LICENSE.txt file in the project root for full license information.
4+ # -------------------------------------------------------------------------------------------------------
5+ #
6+ # Eventual test running harness on *nix for ChakraCore
7+ # Today, it's simply there to make sure hello.js doesn't regress
8+ #
9+
10+ test_path=` dirname " $0 " `
11+ ch_path=" $test_path /../BuildLinux/ch"
12+ hello_path=" $test_path /Basics/hello.js"
13+
14+ if [ ! -f $ch_path ]; then
15+ echo ' ch not found- exiting'
16+ exit 1
17+ fi
18+
19+ output=` $ch_path $hello_path 2>&1 | tail -n 1`
20+
21+ if [ ! $output == " PASS" ]; then
22+ echo " Hello world failed"
23+ exit 1
24+ fi
25+
26+ echo " Hello world passed"
27+ exit 0
You can’t perform that action at this time.
0 commit comments