delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2023/01/28/06:39:29

X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f
X-Recipient: djgpp AT delorie DOT com
X-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=gmail.com; s=20210112;
h=to:subject:message-id:date:from:references:in-reply-to:mime-version
:from:to:cc:subject:date:message-id:reply-to;
bh=7AvxyzLAmxyiq6maaqeRyUak5AhA51HbzLNvwzvHQgI=;
b=WSNeXtUiJFGmc/1W+7+JQlbbBxlTO069qS/LmtvHFOJCiMSVprSBMlg6yJNKDvh7/8
2HZ3snz8b3IpmjDJIvhJ4Tf+1TXj3dZVKnRmsslCjLroaRA/t8rzz1WB64ZO2ay0V8Lh
IAsvpgKoxGNrziMMSlVBXdfMmXU0p+3S+lmMe+N0gWvHhhUuQcyL3Uiamj8qTFO8oHwQ
u5wuoB1KjwPddE09m2OzzFJI1IoFBk790YspKLvIYDkb2jKBcb4nFgggCBmoTqT0FIQO
cFDcXIrSGPHE6iLIu5GmHLiuWWVqN4V4likXTUO3JeVEpJ6Mg9U6mu05p16jb2v97uFh
2Fqw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20210112;
h=to:subject:message-id:date:from:references:in-reply-to:mime-version
:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to;
bh=7AvxyzLAmxyiq6maaqeRyUak5AhA51HbzLNvwzvHQgI=;
b=u4TrniKOer8dsNUhxsFL5JhdeKi1SoVEFnyWFmHeFFou3yGjDeNZZQtpndhChdmzx4
yr1x1H444KgKmiiSO8KwNyprfFB67CVKg0o7Hmjq72wjACdme2Xe/8+cuNwKNQaS0EQm
zJRQcO20BSplhVEycJ+StBe76se064Tc0uGCCuwPGS1EHZc2dnHdL1m9wo+N4QvyKxBG
p850aW10ldjBbUdn6o7S3E+q22jzCwNLlWXs9BqOTTMtNbkcxtwJHheAVQOAvvxh8ZjX
fQBqPGyAOmYK8S2r1w/taT3QYYm9/GC4RkDiS3rMVbi1gipKowG6mTb4NN1ZlmbyfrXk
LZAg==
X-Gm-Message-State: AO0yUKWI2DuJXk7umXkDyz+lHwUFGYA/e4gIlZAS9NvQ8yRK1NiGSh0M
M/VLLSp/jqMQP3gzugHdHIdKRoYXj9rHQTIEzEQ9IJD1
X-Google-Smtp-Source: AK7set9h7RUrfM1fDkiC8hXLFQzD0/NeovjTeuBGs1KL4UYyUKx5DUpN14q4+S+UPLzDVHC+5hvwgPSeClvlPDBnF3o=
X-Received: by 2002:a05:6000:170e:b0:2bf:b77b:fafc with SMTP id
n14-20020a056000170e00b002bfb77bfafcmr567540wrc.475.1674905778986; Sat, 28
Jan 2023 03:36:18 -0800 (PST)
MIME-Version: 1.0
In-Reply-To: <496da509-6d4f-88a1-e94a-6c330a915f05@iki.fi>
References: <496da509-6d4f-88a1-e94a-6c330a915f05 AT iki DOT fi>
From: "Ozkan Sezer (sezeroz AT gmail DOT com) [via djgpp AT delorie DOT com]" <djgpp AT delorie DOT com>
Date: Sat, 28 Jan 2023 14:36:18 +0300
Message-ID: <CAA2C=vA6APeRO_ccMsucbYpHqy0AfnvEeUAzh87S99MfiqMrSg@mail.gmail.com>
Subject: Re: Linking DXE3 with libraries
To: djgpp AT delorie DOT com
Reply-To: djgpp AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On 1/28/23, Andris Pavenis (andris DOT pavenis AT iki DOT fi) [via
djgpp AT delorie DOT com] <djgpp AT delorie DOT com> wrote:
> I have not used DXE myself, so my thoughts could be inaccurate
>
> Some general thoughts:
>
> - DXE loader has no way to found symbols of running executable (which
> requests to load DXE) unless
> one tells where they are located

General issue

> - linking DXE directly with libraries (like libstdcxx.a or libc.a) will
> cause duplicate copy of symbols.

Linking with libc.a can be especially problematic.

However, if you have a dxe written in c++, and especially if your
exe is C-only, linking dxe with libstdc++ is a good thing

As for duplication of symbols: Well that's a known general issue
because djgpp libc is a static library.

> I tried to run DXE3RES under x86_64 Linux, but is seems that DXE3RES is
> broken when compiled for
> 64-bit systems:
>
> [andris AT ap ~]$ i686-pc-msdosdjgpp-dxe3res -o tmp.c
> /usr/i686-pc-msdosdjgpp/lib/libc.a
> /usr/i686-pc-msdosdjgpp/lib/libc.a: Exec format error

You should run dxe3res against a dxe module, not an archive,
like: dxe3gen -o tmp.c my.dxe

As for rest of your notes, I will try looking at them later.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019