From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from m15113.mail.126.com (m15113.mail.126.com [220.181.15.113]) by sourceware.org (Postfix) with ESMTP id B37163858D28 for ; Mon, 11 Oct 2021 06:43:32 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org B37163858D28 Received: from [192.168.48.55] (unknown [116.236.172.42]) by smtp3 (Coremail) with SMTP id DcmowACnugQO3WNhVSfcAw--.53900S2; Mon, 11 Oct 2021 14:43:27 +0800 (CST) To: Tom Kacvinsky , =?UTF-8?B?5qGC5rC45p6X?= Cc: gcc-help , =?UTF-8?B?5p+z6IyC5piV?= , =?UTF-8?B?5p2O6Zev6Zev?= References: <20f6fd91.5593e.17c6d6050ed.Coremail.guiyonglin@huaqin.com> From: LIU Hao Subject: Re: GCC link error help! Message-ID: <0e6a4bba-872f-92e5-af61-e5cc94a2b547@126.com> Date: Mon, 11 Oct 2021 14:43:25 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="qUX6UocZZifgqmLJObf6nGltYDGB0cCfG" X-CM-TRANSID: DcmowACnugQO3WNhVSfcAw--.53900S2 X-Coremail-Antispam: 1Uf129KBjvdXoWrZF1fZFW8Aw15GrWrXry5Arb_yoWDKFg_AF 9Y9r1ak390grWxJw1qgF18ZwsxtFWqya4fJ3s8GrWDWr9IvFs3GFWqgr9IqFW7K3yDAFn0 g3Z0qay09r1q9jkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUvcSsGvfC2KfnxnUUI43ZEXa7IUnjFAPUUUUU== X-Originating-IP: [116.236.172.42] X-CM-SenderInfo: 5okbz0xxvhqiyswou0bp/1tbiFw4pRlpECVr4ZwABsl X-Spam-Status: No, score=-3124.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, NICE_REPLY_A, RCVD_IN_BARRACUDACENTRAL, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=no autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-help@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-help mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Oct 2021 06:43:35 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --qUX6UocZZifgqmLJObf6nGltYDGB0cCfG Content-Type: multipart/mixed; boundary="vmbOW3d8HxWAzM6X42OTJRDRjvfQq5dWS"; protected-headers="v1" From: LIU Hao To: Tom Kacvinsky , =?UTF-8?B?5qGC5rC45p6X?= Cc: gcc-help , =?UTF-8?B?5p+z6IyC5piV?= , =?UTF-8?B?5p2O6Zev6Zev?= Message-ID: <0e6a4bba-872f-92e5-af61-e5cc94a2b547@126.com> Subject: Re: GCC link error help! References: <20f6fd91.5593e.17c6d6050ed.Coremail.guiyonglin@huaqin.com> In-Reply-To: --vmbOW3d8HxWAzM6X42OTJRDRjvfQq5dWS Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: quoted-printable =E5=9C=A8 10/11/21 1:10 PM, Tom Kacvinsky via Gcc-help =E5=86=99=E9=81=93= : >> >> It seems that the link can not fond some lib, but the real reason is= that >> the project path and source code file on windows environment is too lo= ng. >> But,if we use the same GCC version to compile my project on Linux >> enviroment, it can compile sucess. The GCC compiler and source code we= used >> on Linux is same with Windos. >> We don't know how the GCC restict the path lenth and source code fil= e The conventional DOS path has a hard limit of 259 characters: 3 for the d= rive letter and immediate=20 colon-slash, and 256 for the path itself. (If the null terminator is coun= ted then it's 260=20 characters, which is exactly the value of `PATH_MAX`.) The simple solution is to move the toolchain to somewhere shallower, appa= rently. The permanent solution to this problem would be using UNC paths. For exam= ple, instead of writing=20 `C:\Windows`, you write `\\?\C:\Windows`. This makes use of a 64KiB buffe= r, but please note Windows=20 NT uses UTF-16 paths, so the length limit of a path is 32767 UTF-16 code = units. --=20 Best regards, LIU Hao --vmbOW3d8HxWAzM6X42OTJRDRjvfQq5dWS-- --qUX6UocZZifgqmLJObf6nGltYDGB0cCfG Content-Type: application/pgp-signature; name="OpenPGP_signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="OpenPGP_signature" -----BEGIN PGP SIGNATURE----- wsF5BAABCAAjFiEEZJCxCN6/ow6T+6yoFqQYocZTnsgFAmFj3Q0FAwAAAAAACgkQFqQYocZTnsgg jRAAla8WWSAV68EK/W+rizYyClSiJKWWZ5fNOkb8FF/QizlGV5SoMF+eE2kfC1/zIHGQzwdEfepr 103eJKP8sk+V+YBGwz/7LNbOSBmGo0GfROcZyBUmweX8uZbKSFL2iu3NK0Du2qa3fsRjdQCHHUhx MBo9f9obe22lkKxzI267hFgSgJ2b7Bvty2B2EKBWnyBLBQVGeovPcDQnJ1XC4ZR3+b5V0ki9T8NT AVtFgFGLHbz71u2MFnqKcHhwL4iRBc/3gslUlHaosuXpvl8iXz4Pp9vfCk30AtSRautF3KCdogUT Y6L+75PktoNW/aaGmzzIwercVt7ad6WfOHrN3f1SI6U0jKfdPBpzTPb9Gt17X6fg5j7sJHsMfY21 gpYu9OIbP/RH9Hfjk63uOKc/ppjKnCAZ9CDsqyMTzwB72OslPkm6DLZDInwyTOCWwcpHddKv39sJ GFi7KIhUx9PckFbqE0Wyufbj6jUm1pftcxbhHGkBx4lhcIpsss3c0NzIt6jKCznQdaU/LIynwA8d D6G2MGzoWHn0pU0ndvtCPFdSVqF+vSImYWcJB+OJB9wxIh30I+Lly7V1qZcVzS866LUGxHIptFDS 1GXvX6F7uER88EY+UJEZUWKsrMGXGgDuKfeFO2hOgk+yO0pkbZCPE0VJOblq6fT6NfTp3jpvI2q8 qog= =/uwS -----END PGP SIGNATURE----- --qUX6UocZZifgqmLJObf6nGltYDGB0cCfG--