delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2011/07/30/07:34:19

X-Authentication-Warning: delorie.com: mail set sender to djgpp-workers-bounces using -f
X-Recipient: djgpp-workers AT delorie DOT com
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=gmail.com; s=gamma;
h=mime-version:in-reply-to:references:date:message-id:subject:from:to
:content-type;
bh=ywT+dEwuRTcveDhfKgwlQLcQwGUQzTKESn3HCp3wGdY=;
b=hdrSel3ZnsfzC6iQ8hjpUW6iyyglkkQpYy/eenrrMoRT3720zAJSWymbo0nhoy2O/j
hDGkHGIXBqeDbFobmzD1SyWQpQEZjyBIt4q8TZZYy746uzzTsCy51RVoFC9Q7MiRLpE5
wWUH2umBu/wbf/xUcVAgD3qOwtMxFTH0fW3I4=
MIME-Version: 1.0
In-Reply-To: <83wrf0chf4.fsf@gnu.org>
References: <CAA2C=vCTyDxWBgYzoBB31=hoOBHJhL+famn_6XL2eYb3a_3egA AT mail DOT gmail DOT com>
<83zkjwcknb DOT fsf AT gnu DOT org>
<CAA2C=vBJEgnGapVsNwy7xW9HUCy0Rpxis2P5=05mxBze_qn7vQ AT mail DOT gmail DOT com>
<83wrf0chf4 DOT fsf AT gnu DOT org>
Date: Sat, 30 Jul 2011 14:34:00 +0300
Message-ID: <CAA2C=vBtiNnx1XPVHw_6Er1uf0_biO3vpaBEa0zeYQuZKh5BxA@mail.gmail.com>
Subject: Re: [PATCH] allow 64 bit host tools when cross compiling
From: Ozkan Sezer <sezeroz AT gmail DOT com>
To: djgpp-workers AT delorie DOT com
Reply-To: djgpp-workers AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp-workers AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

--002215b033ae42478d04a947c6f7
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

On Sat, Jul 30, 2011 at 11:16 AM, Eli Zaretskii <eliz AT gnu DOT org> wrote:
>> Date: Sat, 30 Jul 2011 10:17:43 +0300
>> From: Ozkan Sezer <sezeroz AT gmail DOT com>
>>
>> > =A0=A0IOW, what is the purpose of this compilation?
>>
>> To compile the djgpp runtime library
>
> Is dxegen required to be compiled and run natively for that? =A0(Sorry,

Yes, it is.

> I have long forgotten the details of the DJGPP build process.) =A0If it
> needs to be compiled and run natively, then I understand the need for
> the changes; otherwise I do not.
>

Why do you think I cared and posted a patch here anyway??!

(Can someone who actually does compile his own stuff confirm
this to him?)

>> > It is mostly okay, but I don't understand why you went so far and
>> > deep, and changed also the types that don't need to be changed at all.
>> > For example, neither `short' nor `int' have different size on any
>> > known machine that can be ever supported by DJGPP, so why change them
>> > at all?
>>
>> For consistency,
>
> We don't need such a consistency in this case. =A0Please understand that
> if you want to be consistent, you will have to make these changes all
> the way through all the DJGPP library and the headers, because GCC
> will complain about type mismatches if you use intNN_t where the
> prototype says `int' or `long'. =A0(Right now, these complaints are only
> emitted under certain non-default compiler switches, but with the
> apparent attitude of the GCC developers that brings more and more of
> such warnings into the default behavior, a day will come when the
> switches we use in compiling the DJGPP library will emit these
> warnings, and will then be an annoyance.)
>
> Therefore, any use of a different type has potentially bad and
> far-reaching effects, and we should strive to limit that to the
> absolute minimum. =A0This minimum is currently only the `long' and
> `unsigned long' types, so please limit the changes to these two only.
> I would even use a macro instead of a stdint.h type, like this:
>
> =A0#if _LP64
> =A0# define LONG int
> =A0# define ULONG unsigned int
> =A0#else
> =A0# define LONG long
> =A0# define ULONG unsigned long
> =A0#endf
>
> This will keep the x86_64 compiler happy, but OTOH will not change
> what the 32-bit compiler sees at all, thus avoiding various warnings
> about type mismatch.

I dislike such hacks when we have a legitimate solution of stdint.h,
but won't argue much about it.  Did a similar change in the attached
patch.

>
>> >> - =A0 =A0 =A0 =A0fwrite(&relocs[i].r_vaddr, 1, sizeof(long), outf);
>> >> + =A0 =A0 =A0 =A0fwrite(&relocs[i].r_vaddr, 1, sizeof(int32_t), outf)=
;
>> >
>> > This (and other similar) issue are better solved by using the variable
>> > in question, not its type. =A0Like this:
>> >
>> > =A0 =A0fwrite(&relocs[i].r_vaddr, 1, sizeof(relocs[i].r_vaddr), outf);
>>
>> That particular one (and its similars) I can do, if the changes
>> are acceptable
>
> They are acceptable, with the above comments taken care of.
>
> Thanks for working on this.

New patch attached.

There are other hostbin/*.exe which would need caring
but they don't stop the important parts of the build process.

--
O.S.

--002215b033ae42478d04a947c6f7
Content-Type: application/octet-stream; name="64b.patch"
Content-Disposition: attachment; filename="64b.patch"
Content-Transfer-Encoding: base64
X-Attachment-Id: f_gqqi5ggi0

SW5kZXg6IGluY2x1ZGUvY29mZi5oCj09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09
PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KUkNTIGZpbGU6IC9jdnMvZGpncHAvZGpn
cHAvaW5jbHVkZS9jb2ZmLmgsdgpyZXRyaWV2aW5nIHJldmlzaW9uIDEuMgpkaWZmIC11IC1wIC1y
MS4yIGNvZmYuaAotLS0gaW5jbHVkZS9jb2ZmLmgJNCBGZWIgMjAwMyAyMDoyMjo1NSAtMDAwMAkx
LjIKKysrIGluY2x1ZGUvY29mZi5oCTMwIEp1bCAyMDExIDExOjMwOjMyIC0wMDAwCkBAIC0zLDYg
KzMsMTggQEAKICNpZm5kZWYgX19kal9pbmNsdWRlX2NvZmZfaF8KICNkZWZpbmUgX19kal9pbmNs
dWRlX2NvZmZfaF8KIAorLyogdGhlIGZvbGxvd2luZyBhcmUgbmVlZGVkIHdoZW4gY3Jvc3MgY29t
cGlsaW5nIGhvc3RiaW4gZXhlcyAqLworI2lmbmRlZiBfREpfREVGSU5FRF9OQVRJVkVfVFlQRVMK
KyNkZWZpbmUgX0RKX0RFRklORURfTkFUSVZFX1RZUEVTCisjaWZkZWYgIF9MUDY0CQkJLyogTm90
ZTogd2luNjQgaXMgTExQNjQgKi8KKyMgZGVmaW5lIExPTkczMiAgaW50CisjIGRlZmluZSBVTE9O
RzMyIHVuc2lnbmVk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05HMzIgZGVwX3NpemU7CiAKLSAgICAgICAgbG9uZyBuX3VucmVzX3N5bXM7CS8qIE51bWJlciBv
ZiB1bnJlc29sdmVkIHN5bWJvbHMgKi8KLSAgICAgICAgbG9uZyB1bnJlc190YWJsZTsJLyogRmls
ZSBvZmZzZXQgdG8gdW5yZXNvbHZlZCB0YWJsZSAqLwotICAgICAgICBsb25nIHVucmVzX3NpemU7
CisgICAgICAgIExPTkczMiBuX3VucmVzX3N5bXM7CS8qIE51bWJlciBvZiB1bnJlc29sdmVkIHN5
bWJvbHMgKi8KKyAgICAgICAgTE9ORzMyIHVucmVzX3RhYmxlOwkvKiBGaWxlIG9mZnNldCB0byB1
bnJlc29sdmVkIHRhYmxlICovCisgICAgICAgIExPTkczMiB1bnJlc19zaXplOwogCi0gICAgICAg
IGxvbmcgc2VjX3NpemU7CQkvKiBTaXplIG9mIGNvbWJpbmVkIGNvZGUrZGF0YStic3Mgc2VjdGlv
biAqLwotICAgICAgICBsb25nIHNlY19mX3NpemU7CS8qIFBoeXNpY2FsIHNlY3Rpb24gc2l6ZSAo
dGhlIHJlc3QgaXMgemVyb2VkKSAqLworICAgICAgICBMT05HMzIgc2VjX3NpemU7CS8qIFNpemUg
b2YgY29tYmluZWQgY29kZStkYXRhK2JzcyBzZWN0aW9uICovCisgICAgICAgIExPTkczMiBzZWNf
Zl9zaXplOwkvKiBQaHlzaWNhbCBzZWN0aW9uIHNpemUgKHRoZSByZXN0IGlzIHplcm9lZCkgKi8K
IAotICAgICAgICBsb25nIF9pbml0OwotICAgICAgICBsb25nIF9maW5pOworICAgICAgICBMT05H
MzIgX2luaXQ7CisgICAgICAgIExPTkczMiBfZmluaTsKIH0gX19hdHRyaWJ1dGVfXygocGFja2Vk
KSkgZHhlM19oZWFkZXI7CiAKIHR5cGVkZWYgc3RydWN0CkluZGV4OiBzcmMvZGphc20vZGphc20u
eQo9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09
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TEUgKmluZiwgRklMRSAqbwogCiAgICAgIGlm
IChzeW1baV0uZV9zY251bSA9PSAwKSB7CiAgICAgICAgIHNob3J0ICpjb3VudDsKLSAgICAgICAg
bG9uZyAqcmVsX3JlbG9jcywgKmFic19yZWxvY3M7CisgICAgICAgIExPTkczMiAqcmVsX3JlbG9j
cywgKmFic19yZWxvY3M7CiAgICAgICAgIGludCBuX2Fic19yZWxvY3MgPSAwLCBuX3JlbF9yZWxv
Y3MgPSAwOwogCiAgICAgICAgIC8qIHVucmVzb2x2ZWQgc3ltYm9sICovCkBAIC02NDgsNyArNjQ5
LDcgQEAgc3RhdGljIGludCB3cml0ZV9keGUgKEZJTEUgKmluZiwgRklMRSAqbwogICAgICAgICAg
ICBleGl0KC00KTsKICAgICAgICAgfQogCi0gICAgICAgIG5ld3NpemUgPSB1bnJlc19zaXplICsg
MiAqIHNpemVvZihzaG9ydCkgKyBuYW1lbGVuICsgKG5fcmVsX3JlbG9jcyArIG5fYWJzX3JlbG9j
cykgKiBzaXplb2YobG9uZyk7CisgICAgICAgIG5ld3NpemUgPSB1bnJlc19zaXplICsgMiAqIHNp
emVvZihzaG9ydCkgKyBuYW1lbGVuICsgKG5fcmVsX3JlbG9jcyArIG5fYWJzX3JlbG9jcykgKiBz
aXplb2YoTE9ORzMyKTsKICAgICAgICAgaWYgKG5ld3NpemUgPiB1bnJlc19tYXhzaXplKSB7CiAg
ICAgICAgICAgIGludCBhZGRsZW49bmV3c2l6ZSAtIHVucmVzX21heHNpemUgKyAzMTc7CiAgICAg
ICAgICAgIGlmICghKChhZGRsZW4rdW5yZXNfbWF4c2l6ZSkgJiAxKSkgewpAQCAtNjY3LDE1ICs2
NjgsMTUgQEAgc3RhdGljIGludCB3cml0ZV9keGUgKEZJTEUgKmluZiwgRklMRSAqbwogICAgICAg
ICBjb3VudFswXSA9IG5fcmVsX3JlbG9jczsKICAgICAgICAgY291bnRbMV0gPSBuX2Fic19yZWxv
Y3M7CiAKLSAgICAgICAgcmVsX3JlbG9jcyA9IChsb25nICopKHVucmVzX3RhYmxlICsgdW5yZXNf
c2l6ZSArIDIgKiBzaXplb2Yoc2hvcnQpICsgbmFtZWxlbik7Ci0gICAgICAgIGFic19yZWxvY3Mg
PSAobG9uZyAqKSh1bnJlc190YWJsZSArIG5ld3NpemUpOworICAgICAgICByZWxfcmVsb2NzID0g
KExPTkczMiAqKSh1bnJlc190YWJsZSArIHVucmVzX3NpemUgKyAyICogc2l6ZW9mKHNob3J0KSAr
IG5hbWVsZW4pOworICAgICAgICBhYnNfcmVsb2NzID0gKExPTkczMiAqKSh1bnJlc190YWJsZSAr
IG5ld3NpemUpOwogCiAgICAgICAgIHVucmVzX3NpemUgPSBuZXdzaXplOwogCiAgICAgICAgIGZv
ciAoaiA9IDA7IGogPCBzYy5zX25yZWxvYzsgaisrKSB7CiAgICAgICAgICAgICBpZiAocmVsb2Nz
W2pdLnJfc3ltbmR4ID09IGkpIHsKICAgICAgICAgICAgICAgIC8qIG1hcmsgdGhlIHJlbG9jYXRp
b24gYXMgcHJvY2Vzc2VkICovCi0gICAgICAgICAgICAgICByZWxvY3Nbal0ucl9zeW1uZHggPSAt
MVVMOworICAgICAgICAgICAgICAgcmVsb2NzW2pdLnJfc3ltbmR4ID0gMHhGRkZGRkZGRjsKIAog
ICAgICAgICAgICAgICAgaWYgKHJlbG9jc1tqXS5yX3R5cGUgPT0gUkVMT0NfUkVMMzIpIHsKICAg
ICAgICAgICAgICAgICAgICpyZWxfcmVsb2NzKysgPSByZWxvY3Nbal0ucl92YWRkcjsKQEAgLTc0
MiwxMyArNzQzLDEzIEBAIHN0YXRpYyBpbnQgd3JpdGVfZHhlIChGSUxFICppbmYsIEZJTEUgKm8K
ICAgICAgICAgICAgZXJyY291bnQrKzsKICAgICAgICAgfQogCi0gICAgICAgIG5ld3NpemUgPSBl
eHBzeW1fc2l6ZSArIHNpemVvZihsb25nKSArIG5hbWVsZW47CisgICAgICAgIG5ld3NpemUgPSBl
eHBzeW1fc2l6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MF0pOwogICAgIHBjKys7
CiB9CiAK
--002215b033ae42478d04a947c6f7--

- Raw text -


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