Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
clean-and-itasks
clean-ide
Commits
20c8eb9d
Commit
20c8eb9d
authored
Oct 24, 2016
by
Jurrien Stutterheim
Browse files
Port ProjectCompilerOptions record to MacOSX and Linux
parent
19488f39
Changes
7
Hide whitespace changes
Inline
Side-by-side
CpmMacOSX.prj
View file @
20c8eb9d
...
...
@@ -31,6 +31,7 @@ Global
Link
LinkMethod: Static
GenerateRelocations: False
GenerateSymbolTable: False
GenerateLinkMap: False
LinkResources: False
ResourceSource:
...
...
@@ -1050,6 +1051,20 @@ OtherModules
ReadableABC: False
ReuseUniqueNodes: True
Fusion: False
Module
Name: StdDebug
Dir: {Application}/lib/StdEnv
Compiler
NeverMemoryProfile: False
NeverTimeProfile: False
StrictnessAnalysis: True
ListTypes: StrictExportTypes
ListAttributes: True
Warnings: True
Verbose: True
ReadableABC: False
ReuseUniqueNodes: True
Fusion: False
Module
Name: StdEnum
Dir: {Application}/lib/StdEnv
...
...
Mac/PmCleanSystem.dcl
View file @
20c8eb9d
...
...
@@ -40,6 +40,14 @@ instance == CompilerMsg
::
WindowFun
env
:==
([
String
])
->
env
->
env
::
ProjectCompilerOptions
=
{
pco_memory_profiling
::
!
Bool
,
pco_time_profiling
::
!
Bool
,
pco_desc_exl
::
!
Bool
,
pco_dynamics
::
!
Bool
,
pco_link_dynamic
::
!
Bool
}
Compile
::
// Compiles the given file:
!
String
// compiler exe name and options
// !! should be full path so that cocl generates diagnostics in logical place...
...
...
@@ -51,9 +59,7 @@ Compile :: // Compiles the given file:
!
CompileOrCheckSyntax
// check syntax only?
!
Pathname
// full .icl pathname of module to be compiled
!(
List
Pathname
)
// list of paths where compiler can find imported .dcl files
!
Bool
// project memory profiling?
!
Bool
// project time profiling?
!
Bool
// project eager or dynamic linking?
!
ProjectCompilerOptions
!
CompilerOptions
// compiler options
!
Pathname
// startup directory
!
CompilerProcessIds
...
...
Mac/PmCleanSystem.icl
View file @
20c8eb9d
...
...
@@ -167,20 +167,19 @@ file_path startupdir base_name slot
/* Compiles the given file: */
Compile
::
!
String
!
Bool
!
Bool
!(
WindowFun
*
env
)
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
Pathname
!(
List
Pathname
)
!
Bool
!
Bool
!
Bool
Compile
::
!
String
!
Bool
!
Bool
!(
WindowFun
*
env
)
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
Pathname
!(
List
Pathname
)
!
ProjectCompilerOptions
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
->
(!
Pathname
,!
CompilerMsg
,!
CompilerProcessIds
,!*
env
)
|
FileEnv
env
Compile
cocl`
use_compiler_process_psn
write_module_times
errwin
typewin
compileOrCheckSyntax
path
paths
projectMemoryProfiling
projectTimeProfiling
projectEagerOrDynamic
Compile
cocl`
use_compiler_process_psn
write_module_times
errwin
typewin
compileOrCheckSyntax
path
paths
project_compiler_options
co
=:{
CompilerOptions
|
listTypes
}
startupdir
compiler_psns
ps
#
(
cocl
,
name
,
signature
)
=
mangleCompiler
cocl`
startupdir
// platform dependant mangling...
#
command
=
cocl
+++
clear_cache_option
+++
write_module_times_string
+++
MakeCompilerOptionsString
compileOrCheckSyntax
project
M
emory
P
rofiling
project
T
ime
P
rofiling
project
EagerOrD
ynamic
project
_compiler_options
.
pco_m
emory
_p
rofiling
project
_compiler_options
.
pco_t
ime
_p
rofiling
project
_compiler_options
.
pco_link_d
ynamic
co
+++
" -sl"
+++
" -P "
+++
quoted_string
(
ConcatenatePath
paths
)
...
...
MacOSX/PmCleanSystem.dcl
View file @
20c8eb9d
...
...
@@ -23,6 +23,14 @@ import PmCallBack
::
WindowFun
env
:==
([
String
])
->
env
->
env
::
ProjectCompilerOptions
=
{
pco_memory_profiling
::
!
Bool
,
pco_time_profiling
::
!
Bool
,
pco_desc_exl
::
!
Bool
,
pco_dynamics
::
!
Bool
,
pco_link_dynamic
::
!
Bool
}
instance
==
CompileOrCheckSyntax
instance
==
CodeGenerateAsmOrCode
...
...
@@ -38,19 +46,19 @@ CompileHandleExitCode :: !Int !String !String !Int !(WindowFun *env) !(WindowFun
InitCompilingInfo
::
*
CompilingInfo
Compile
::
!
String
!
Bool
!
Bool
!(
WindowFun
*
env
)
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
ModuleDirAndName
!
Pathname
!(
List
Pathname
)
!
Bool
!
Bool
!
Bool
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
!(
List
Pathname
)
!
ProjectCompilerOptions
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
->
(!
Pathname
,!
CompilerMsg
,!
CompilerProcessIds
,!*
env
)
|
FileEnv
env
CompilePersistent
::
!
String
!
Bool
!(
WindowFun
*
env
)
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
ModuleDirAndName
!(
List
Pathname
)
!
Bool
!
Bool
!
Bool
!
CompilerOptions
!
Pathname
!*
CompilingInfo
!*
env
!(
List
Pathname
)
!
ProjectCompilerOptions
!
CompilerOptions
!
Pathname
!*
CompilingInfo
!*
env
->
(!*
CompilingInfo
,!(!*
env
,
!
Pathname
,
!
CompilerMsg
))
|
FileEnv
env
CompileStartCommand
::
!
String
!
Bool
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
Pathname
!(
List
Pathname
)
!
Int
!
Bool
!
Bool
!
Bool
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
!(
List
Pathname
)
!
Int
!
ProjectCompilerOptions
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
->
(!
Bool
,!
CompilerProcessIds
,!*
env
)
|
FileEnv
env
...
...
MacOSX/PmCleanSystem.icl
View file @
20c8eb9d
...
...
@@ -71,12 +71,12 @@ InitCompilingInfo :: *CompilingInfo
InitCompilingInfo
=
NoCompiler
Compile
::
!
String
!
Bool
!
Bool
!(
WindowFun
*
env
)
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
ModuleDirAndName
!
Pathname
!(
List
Pathname
)
!
Bool
!
Bool
!
Bool
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
!(
List
Pathname
)
!
ProjectCompilerOptions
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
->
(!
Pathname
,!
CompilerMsg
,!
CompilerProcessIds
,!*
env
)
|
FileEnv
env
Compile
cocl
use_compiler_process_ids
write_module_times
errwin
typewin
compileOrCheckSyntax
mdn
path
paths
project
HeapProfiling
projectTimeProfiling
projectEagerOrDynamic
co
=:{
CompilerOptions
|
listTypes
}
cocl
use_compiler_process_ids
write_module_times
errwin
typewin
compileOrCheckSyntax
mdn
path
paths
project
_compiler_options
co
=:{
CompilerOptions
|
listTypes
}
startupdir
compiler_process_ids
env
#
(
cocl
,
cocl_dir
,
options1
,
options2
)
=
get_path_name_and_options2
cocl
startupdir
...
...
@@ -84,7 +84,7 @@ Compile
out_file_name
=
out_file_path
temp_dir
0
errors_file_name
=
errors_file_path
temp_dir
0
#
cocl_arguments
=
compiler_arguments
out_file_name
errors_file_name
compileOrCheckSyntax
path
paths
write_module_times
project
HeapProfiling
projectT
ime
P
rofiling
project
EagerOrD
ynamic
co
#
cocl_arguments
=
compiler_arguments
out_file_name
errors_file_name
compileOrCheckSyntax
path
paths
write_module_times
project
_compiler_options
.
pco_memory_profiling
project_compiler_options
.
pco_t
ime
_p
rofiling
project
_compiler_options
.
pco_link_d
ynamic
co
cocl_arguments
=
add_options_string_to_args
0
options2
cocl_arguments
cocl_arguments
=
add_options_string_to_args
0
options1
cocl_arguments
...
...
@@ -116,11 +116,10 @@ Compile
CompilePersistent
::
!
String
!
Bool
!(
WindowFun
*
env
)
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
ModuleDirAndName
!(
List
Pathname
)
!
Bool
!
Bool
!
Bool
!
CompilerOptions
!
Pathname
!*
CompilingInfo
!*
env
!(
List
Pathname
)
!
ProjectCompilerOptions
!
CompilerOptions
!
Pathname
!*
CompilingInfo
!*
env
->
(!*
CompilingInfo
,!(!*
env
,
!
Pathname
,
!
CompilerMsg
))
|
FileEnv
env
CompilePersistent
cocl
write_module_times
errwin
typewin
compileOrCheckSyntax
mdn
paths
projectHeapProfiling
projectTimeProfiling
projectEagerOrDynamic
co
=:{
CompilerOptions
|
listTypes
}
CompilePersistent
cocl
write_module_times
errwin
typewin
compileOrCheckSyntax
mdn
paths
project_compiler_options
co
=:{
CompilerOptions
|
listTypes
}
startupdir
compiling_info
env
#
(
cocl
,
cocl_dir
,
options1
,
options2
)
=
get_path_name_and_options2
cocl
startupdir
...
...
@@ -130,7 +129,7 @@ CompilePersistent cocl write_module_times errwin typewin compileOrCheckSyntax md
out_file_name
=
out_file_path
temp_dir
0
errors_file_name
=
errors_file_path
temp_dir
0
#
args
=
makeCompilerOptionsArguments
compileOrCheckSyntax
write_module_times
project
HeapProfiling
projectT
ime
P
rofiling
project
EagerOrD
ynamic
co
#
args
=
makeCompilerOptionsArguments
compileOrCheckSyntax
write_module_times
project
_compiler_options
.
pco_memory_profiling
project_compiler_options
.
pco_t
ime
_p
rofiling
project
_compiler_options
.
pco_link_d
ynamic
co
#
args_string
=
concat_args
args
+++
" "
+++
mdn
.
mdn_name
+++
" -P "
+++
"
\"
"
+++
concatenate_paths
paths
+++
"
\"
"
+++
...
...
@@ -175,11 +174,11 @@ parse_result_number i result_string
CompileStartCommand
::
!
String
!
Bool
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
Pathname
!(
List
Pathname
)
!
Int
!
Bool
!
Bool
!
Bool
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
!(
List
Pathname
)
!
Int
!
ProjectCompilerOptions
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
->
(!
Bool
,!
CompilerProcessIds
,!*
env
)
|
FileEnv
env
CompileStartCommand
cocl
write_module_times
errwin
compileOrCheckSyntax
path
paths
slot
project
HeapProfiling
projectTimeProfiling
projectEagerOrDynamic
co
startupdir
compiler_process_ids
ps
paths
slot
project
_compiler_options
co
startupdir
compiler_process_ids
ps
#
(
cocl
,
cocl_dir
,
options1
,
options2
)
=
get_path_name_and_options2
cocl
startupdir
#
({
commands_fd
,
results_fd
},
compiler_process_ids
)
...
...
@@ -189,7 +188,7 @@ CompileStartCommand cocl write_module_times errwin compileOrCheckSyntax path
out_file_name
=
out_file_path
temp_dir
slot
errors_file_name
=
errors_file_path
temp_dir
slot
#
args
=
makeCompilerOptionsArguments
compileOrCheckSyntax
write_module_times
project
HeapProfiling
projectT
ime
P
rofiling
project
EagerOrD
ynamic
co
#
args
=
makeCompilerOptionsArguments
compileOrCheckSyntax
write_module_times
project
_compiler_options
.
pco_memory_profiling
project_compiler_options
.
pco_t
ime
_p
rofiling
project
_compiler_options
.
pco_link_d
ynamic
co
#
args_string
=
concat_args
args
+++
" "
+++
path
+++
" -P "
+++
concatenate_paths
paths
+++
...
...
Unix/PmCleanSystem.dcl
View file @
20c8eb9d
...
...
@@ -24,6 +24,14 @@ import PmCallBack
::
WindowFun
env
:==
([
String
])
->
env
->
env
::
ProjectCompilerOptions
=
{
pco_memory_profiling
::
!
Bool
,
pco_time_profiling
::
!
Bool
,
pco_desc_exl
::
!
Bool
,
pco_dynamics
::
!
Bool
,
pco_link_dynamic
::
!
Bool
}
instance
==
CompileOrCheckSyntax
instance
==
CodeGenerateAsmOrCode
...
...
@@ -39,7 +47,7 @@ CompileHandleExitCode :: !Int !String !String !Int !(WindowFun *env) !(WindowFun
InitCompilingInfo
::
*
CompilingInfo
Compile
::
!
String
!
Bool
!
Bool
!(
WindowFun
*
env
)
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
ModuleDirAndName
!
Pathname
!(
List
Pathname
)
!
Bool
!
Bool
!
Bool
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
!(
List
Pathname
)
!
ProjectCompilerOptions
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
->
(!
Pathname
,!
CompilerMsg
,!
CompilerProcessIds
,!*
env
)
|
FileEnv
env
...
...
Unix/PmCleanSystem.icl
View file @
20c8eb9d
...
...
@@ -71,12 +71,12 @@ InitCompilingInfo :: *CompilingInfo
InitCompilingInfo
=
NoCompiler
Compile
::
!
String
!
Bool
!
Bool
!(
WindowFun
*
env
)
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
ModuleDirAndName
!
Pathname
!(
List
Pathname
)
!
Bool
!
Bool
!
Bool
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
!(
List
Pathname
)
!
ProjectCompilerOptions
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
->
(!
Pathname
,!
CompilerMsg
,!
CompilerProcessIds
,!*
env
)
|
FileEnv
env
Compile
cocl
use_compiler_process_ids
write_module_times
errwin
typewin
compileOrCheckSyntax
mdn
path
paths
project
HeapProfiling
projectTimeProfiling
projectEagerOrDynamic
co
=:{
CompilerOptions
|
listTypes
}
cocl
use_compiler_process_ids
write_module_times
errwin
typewin
compileOrCheckSyntax
mdn
path
paths
project
_compiler_options
co
=:{
CompilerOptions
|
listTypes
}
startupdir
compiler_process_ids
env
#
(
cocl
,
cocl_dir
,
options1
,
options2
)
=
get_path_name_and_options2
cocl
startupdir
...
...
@@ -84,7 +84,7 @@ Compile
out_file_name
=
out_file_path
temp_dir
0
errors_file_name
=
errors_file_path
temp_dir
0
#
cocl_arguments
=
compiler_arguments
out_file_name
errors_file_name
compileOrCheckSyntax
path
paths
write_module_times
project
HeapProfiling
projectT
ime
P
rofiling
project
EagerOrD
ynamic
co
#
cocl_arguments
=
compiler_arguments
out_file_name
errors_file_name
compileOrCheckSyntax
path
paths
write_module_times
project
_compiler_options
.
pco_memory_profiling
project_compiler_options
.
pco_t
ime
_p
rofiling
project
_compiler_options
.
pco_link_d
ynamic
co
cocl_arguments
=
add_options_string_to_args
0
options2
cocl_arguments
cocl_arguments
=
add_options_string_to_args
0
options1
cocl_arguments
...
...
@@ -116,11 +116,11 @@ Compile
CompilePersistent
::
!
String
!
Bool
!(
WindowFun
*
env
)
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
ModuleDirAndName
!(
List
Pathname
)
!
Bool
!
Bool
!
Bool
!
CompilerOptions
!
Pathname
!*
CompilingInfo
!*
env
!(
List
Pathname
)
!
ProjectCompilerOptions
!
CompilerOptions
!
Pathname
!*
CompilingInfo
!*
env
->
(!*
CompilingInfo
,!(!*
env
,
!
Pathname
,
!
CompilerMsg
))
|
FileEnv
env
CompilePersistent
cocl
write_module_times
errwin
typewin
compileOrCheckSyntax
mdn
paths
project
HeapProfiling
projectTimeProfiling
projectEagerOrDynamic
co
=:{
CompilerOptions
|
listTypes
}
CompilePersistent
cocl
write_module_times
errwin
typewin
compileOrCheckSyntax
mdn
paths
project
_compiler_options
co
=:{
CompilerOptions
|
listTypes
}
startupdir
compiling_info
env
#
(
cocl
,
cocl_dir
,
options1
,
options2
)
=
get_path_name_and_options2
cocl
startupdir
...
...
@@ -130,7 +130,7 @@ CompilePersistent cocl write_module_times errwin typewin compileOrCheckSyntax md
out_file_name
=
out_file_path
temp_dir
0
errors_file_name
=
errors_file_path
temp_dir
0
#
args
=
makeCompilerOptionsArguments
compileOrCheckSyntax
write_module_times
project
HeapProfiling
projectT
ime
P
rofiling
project
EagerOrD
ynamic
co
#
args
=
makeCompilerOptionsArguments
compileOrCheckSyntax
write_module_times
project
_compiler_options
.
pco_memory_profiling
project_compiler_options
.
pco_t
ime
_p
rofiling
project
_compiler_options
.
pco_link_d
ynamic
co
#
args_string
=
concat_args
args
+++
" "
+++
mdn
.
mdn_name
+++
" -P "
+++
"
\"
"
+++
concatenate_paths
paths
+++
"
\"
"
+++
...
...
@@ -175,11 +175,11 @@ parse_result_number i result_string
CompileStartCommand
::
!
String
!
Bool
!(
WindowFun
*
env
)
!
CompileOrCheckSyntax
!
Pathname
!(
List
Pathname
)
!
Int
!
Bool
!
Bool
!
Bool
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
!(
List
Pathname
)
!
Int
!
ProjectCompilerOptions
!
CompilerOptions
!
Pathname
!
CompilerProcessIds
!*
env
->
(!
Bool
,!
CompilerProcessIds
,!*
env
)
|
FileEnv
env
CompileStartCommand
cocl
write_module_times
errwin
compileOrCheckSyntax
path
paths
slot
project
HeapProfiling
projectTimeProfiling
projectEagerOrDynamic
co
startupdir
compiler_process_ids
ps
paths
slot
project
_compiler_options
co
startupdir
compiler_process_ids
ps
#
(
cocl
,
cocl_dir
,
options1
,
options2
)
=
get_path_name_and_options2
cocl
startupdir
#
({
commands_fd
,
results_fd
},
compiler_process_ids
)
...
...
@@ -189,7 +189,7 @@ CompileStartCommand cocl write_module_times errwin compileOrCheckSyntax path
out_file_name
=
out_file_path
temp_dir
slot
errors_file_name
=
errors_file_path
temp_dir
slot
#
args
=
makeCompilerOptionsArguments
compileOrCheckSyntax
write_module_times
project
HeapProfiling
projectT
ime
P
rofiling
project
EagerOrD
ynamic
co
#
args
=
makeCompilerOptionsArguments
compileOrCheckSyntax
write_module_times
project
_compiler_options
.
pco_memory_profiling
project_compiler_options
.
pco_t
ime
_p
rofiling
project
_compiler_options
.
pco_link_d
ynamic
co
#
args_string
=
concat_args
args
+++
" "
+++
path
+++
" -P "
+++
concatenate_paths
paths
+++
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment