mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-15 10:51:08 +02:00
* fix dynamic library compilation on darwin (both i386 and ppc)
git-svn-id: trunk@2875 -
This commit is contained in:
parent
fad4e25b39
commit
638b2ecb2b
@ -1291,7 +1291,9 @@ implementation
|
|||||||
pd:=create_main_proc(make_mangledname('',current_module.localsymtable,mainaliasname),potype_proginit,current_module.localsymtable);
|
pd:=create_main_proc(make_mangledname('',current_module.localsymtable,mainaliasname),potype_proginit,current_module.localsymtable);
|
||||||
{ Win32 startup code needs a single name }
|
{ Win32 startup code needs a single name }
|
||||||
if not(target_info.system in [system_powerpc_darwin,system_i386_darwin]) then
|
if not(target_info.system in [system_powerpc_darwin,system_i386_darwin]) then
|
||||||
pd.aliasnames.insert('PASCALMAIN');
|
pd.aliasnames.insert('PASCALMAIN')
|
||||||
|
else
|
||||||
|
pd.aliasnames.insert(target_info.Cprefix+'PASCALMAIN')
|
||||||
end
|
end
|
||||||
else if (target_info.system in [system_i386_netware,system_i386_netwlibc,system_powerpc_macos,system_powerpc_darwin,system_i386_darwin]) then
|
else if (target_info.system in [system_i386_netware,system_i386_netwlibc,system_powerpc_macos,system_powerpc_darwin,system_i386_darwin]) then
|
||||||
begin
|
begin
|
||||||
|
@ -390,11 +390,14 @@ begin
|
|||||||
{ Open link.res file }
|
{ Open link.res file }
|
||||||
LinkRes:=TLinkRes.Create(outputexedir+Info.ResName);
|
LinkRes:=TLinkRes.Create(outputexedir+Info.ResName);
|
||||||
|
|
||||||
case target_info.system of
|
if (not isdll) then
|
||||||
system_powerpc_darwin:
|
begin
|
||||||
LinkRes.Add('-arch ppc');
|
case target_info.system of
|
||||||
system_i386_darwin:
|
system_powerpc_darwin:
|
||||||
LinkRes.Add('-arch i386');
|
LinkRes.Add('-arch ppc');
|
||||||
|
system_i386_darwin:
|
||||||
|
LinkRes.Add('-arch i386');
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
{ Write path to search libraries }
|
{ Write path to search libraries }
|
||||||
HPath:=TStringListItem(current_module.locallibrarysearchpath.First);
|
HPath:=TStringListItem(current_module.locallibrarysearchpath.First);
|
||||||
|
Loading…
Reference in New Issue
Block a user