Skip to content
GitLab
Menu
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
af9c85b5
Commit
af9c85b5
authored
Apr 09, 2003
by
Diederik van Arkel
Browse files
fix so that 'cfrg' includes correct stack size;
parent
546c3fe6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Mac/linker_resources.icl
View file @
af9c85b5
...
...
@@ -39,7 +39,7 @@ create_application_resource file_name add_carb /* RWS ... */ application_existed
(
ok3
,
t6
)=
change_size_resource
(
heap_size
+
stack_size
+
application_and_extra_memory_size
)
t5
;
/* ... RWS */
(
ok2
,
t5
)=
add_sthp_resource
heap_size
heap_size_multiple
stack_size
flags
initial_heap_size
t4
;
(
ok1
,
t4
)=
add_cfrg_resource
file_name
t2
;
(
ok1
,
t4
)=
add_cfrg_resource
file_name
stack_size
t2
;
/*
(ok1,t4)=add_code1_resource t3;
(ok0,t3)=add_code0_resource t2;
...
...
@@ -86,33 +86,33 @@ remove_resource resource_name n t0
(
handle
,
t1
)=
Get1Resource
resource_name
n
t0
;
}
add_cfrg_resource
::
String
*
Int
->
(!
Bool
,!*
Int
);
add_cfrg_resource
file_name
t0
add_cfrg_resource
::
String
Int
*
Int
->
(!
Bool
,!*
Int
);
add_cfrg_resource
file_name
stack_size
t0
#
total_size
=
75
+
(
size
file_name
);
#
n_align4_bytes
=
(
4
-
(
total_size
bitand
3
))
bitand
3
;
#
(
handle
,_,
t1
)
=
NewHandle
(
total_size
+
n_align4_bytes
)
t0
;
|
handle
==
0
=
(
False
,
t1
);
#
(
error_n
,
t2
)
=
ResError
(
AddResource
(
fill_cfrg_handle
file_name
n_align4_bytes
handle
)
"cfrg"
0
""
t1
);
#
(
error_n
,
t2
)
=
ResError
(
AddResource
(
fill_cfrg_handle
file_name
n_align4_bytes
handle
stack_size
)
"cfrg"
0
""
t1
);
=
(
error_n
==
0
,
t2
);
fill_cfrg_handle
file_name
n_align4_bytes
handle
fill_cfrg_handle
file_name
n_align4_bytes
handle
stack_size
=
h1
;
{
(
h1
,_)=
append_align_bytes
n_align4_bytes
s21
;
s21
=
AppendString
s20
file_name
;
s20
=
AppendByte
s19
(
file_name_length
);
s19
=
AppendWord
s18
(
43
+
file_name_length
+
n_align4_bytes
);
s18
=
AppendLong
s17
0
;
s17
=
AppendLong
s16
0
;
s16
=
AppendLong
s15
0
;
s15
=
AppendLong
s14
0
;
s14
=
AppendLong
s13
0x101
;
s13
=
AppendLong
s12
0
;
s12
=
AppendLong
s11
0
;
s11
=
AppendLong
s10
0
;
s10
=
AppendLong
s9
0
;
s9
=
AppendString
s8
"pwpc"
;
s20
=
AppendByte
s19
(
file_name_length
);
// name
s19
=
AppendWord
s18
(
43
+
file_name_length
+
n_align4_bytes
);
// memberSize
s18
=
AppendLong
s17
0
;
// extension_count + uWhere2
s17
=
AppendLong
s16
0
;
// uWhere1
s16
=
AppendLong
s15
0
;
// length
s15
=
AppendLong
s14
0
;
// offset
s14
=
AppendLong
s13
0x101
;
// usage (kApplicationCFrag)
s13
=
AppendLong
s12
stack_size
;
// appStackSize
s12
=
AppendLong
s11
0
;
// oldDefVersion
s11
=
AppendLong
s10
0
;
// current version
s10
=
AppendLong
s9
0
;
// reserved + update level
s9
=
AppendString
s8
"pwpc"
;
// architecture
s8
=
AppendLong
s7
1
;
s7
=
AppendLong
s6
0
;
s6
=
AppendLong
s5
0
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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