From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/12221 Path: news.gmane.org!.POSTED!not-for-mail From: Nicholas Wilson Newsgroups: gmane.linux.lib.musl.general Subject: [PATCH] Remove possibly unused lines from Makefile Date: Thu, 7 Dec 2017 15:55:52 +0000 Message-ID: Reply-To: musl@lists.openwall.com NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1512662168 8032 195.159.176.226 (7 Dec 2017 15:56:08 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 7 Dec 2017 15:56:08 +0000 (UTC) To: "musl@lists.openwall.com" Original-X-From: musl-return-12237-gllmg-musl=m.gmane.org@lists.openwall.com Thu Dec 07 16:56:04 2017 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by blaine.gmane.org with smtp (Exim 4.84_2) (envelope-from ) id 1eMyWp-0001wZ-GE for gllmg-musl@m.gmane.org; Thu, 07 Dec 2017 16:56:03 +0100 Original-Received: (qmail 13930 invoked by uid 550); 7 Dec 2017 15:56:08 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 13895 invoked from network); 7 Dec 2017 15:56:08 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=realvnc.onmicrosoft.com; s=selector1-realvnc-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=57S9BB3oiVJaT9N3+uhVpWsgpxo41YmzXq98RajfRxg=; b=PPZWcCe6KQMN7yMDXOFkZsvnVsI6m15O0qSZrXwk8/bJV8Kv60svghObyaYqGcNrzLxBaphseK3Hyy3bqhqrRwTfmUdAH30GNlA9SRnTYqGotf46v59iQfiRKEhtf4bx9cwPQJDIJhuQx+UTi8tIsG2eMOrGoo1iqPY04BoSkQw= Thread-Topic: [PATCH] Remove possibly unused lines from Makefile Thread-Index: AQHTb3PMhFyaWchuZ0y8wDgFDjTk3g== Accept-Language: en-GB, en-US Content-Language: en-GB X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [2a02:390:a001:192:d6be:d9ff:fe9c:1892] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;VI1PR0502MB3888;6:Tn8mmyVW7RUkswifW5ctzVy/18FuR5zdcg1JjJ/gN5rr0vKe4xtbnrHbe4CQm9OMG9ajrP+sCqo8pFSVSVv/yga3qBMmJV8G7qLvcN15L39+BIFIaaqnw38otn0db3IC7rM8fb80B+qfR5/XAZG353dw3CtEy7c4+B88UieUh5k9TfOM3RkBIddySN0sCPSL7j6MO5XU2OrzGGTH28DKPeImRi/8qWbl7/E5fMS1x+JJAmClf92H9GYP0F+OeFo2WqEmzij/gHGsGLoCNU0W+r5If9aQtdqzK6xsjUeupZL+R2bFNvpBHhsOq9t24r+5vdZ7VZlHOtVa8QW5DL0H3ewFCJf6mNdJ4wp1Vlww1ig=;5:ayH4of6LyPN1ZIxUUR/rFwY1LrtwnmNZALDAFymi4ZRAi9GhQZ/nv9ozvnEAxrqg0qwGarNDf2/FlZvsVVK8JLzourrRtzcT34ovZfafjLzl3xCeqahBDDcEB6++kKPpYi4LD2grVmMxOlDU3toyXOsTfCvRbZyKk9Sl4neYbKM=;24:rI1/Bsbcru59tGZwdaqX/c75OpOGWMCrcpHLcHSGMYB0M06xbkHgmGa+WKSB8tu6I6GgQlU/OUy097+6YMKAHnzgX2CpHlQCLb1dNU0+LcU=;7:p6A6WiCjT3e7u+4CWV50OsrmNUjzB1tS/TmVh4Q7bikhT2iBd1sawxE124IT+chlSvz29tanCdgTuGxVKBFz8hiOX2g/ zYXpttSaT/x5Et8tcUgskplfeatT210wvkfLMF/P8MjS21dkVyqsFG47/ZXSyn2TT1Vmqhz0e6zmSuk2VP1nL4guxjVbytcETC x-ms-exchange-antispam-srfa-diagnostics: SSOS; x-ms-office365-filtering-correlation-id: 27299c98-a9c4-46bb-de91-08d53d8afe73 x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(5600026)(4604075)(4534020)(4602075)(4603075)(4627115)(201702281549075)(2017052603286);SRVR:VI1PR0502MB3888; x-ms-traffictypediagnostic: VI1PR0502MB3888: authentication-results: spf=none (sender IP is ) smtp.mailfrom=nicholas.wilson@realvnc.com; x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:; x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(6040450)(2401047)(5005006)(8121501046)(3002001)(93006095)(93001095)(10201501046)(3231022)(6041248)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123564025)(20161123560025)(2016111802025)(20161123558100)(20161123562025)(20161123555025)(6043046)(6072148)(201708071742011);SRVR:VI1PR0502MB3888;BCL:0;PCL:0;RULEID:(100000803101)(100110400095);SRVR:VI1PR0502MB3888; x-forefront-prvs: 05143A8241 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(376002)(346002)(366004)(39830400002)(189003)(199004)(33656002)(7696005)(101416001)(3660700001)(2906002)(5250100002)(99286004)(3280700002)(2351001)(53936002)(106356001)(105586002)(25786009)(7736002)(2501003)(305945005)(74316002)(102836003)(81156014)(6116002)(1730700003)(81166006)(8676002)(2900100001)(68736007)(8936002)(9686003)(55016002)(5660300001)(86362001)(14454004)(478600001)(316002)(5640700003)(6916009)(97736004)(6506006)(6436002);DIR:OUT;SFP:1101;SCL:1;SRVR:VI1PR0502MB3888;H:VI1PR0502MB3885.eurprd05.prod.outlook.com;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; received-spf: None (protection.outlook.com: realvnc.com does not designate permitted sender hosts) spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM X-MS-Exchange-CrossTenant-Network-Message-Id: 27299c98-a9c4-46bb-de91-08d53d8afe73 X-MS-Exchange-CrossTenant-originalarrivaltime: 07 Dec 2017 15:55:52.5487 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 9ad766d3-c6a5-4458-8c58-244e7c118728 X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR0502MB3888 X-OriginatorOrg: realvnc.com Xref: news.gmane.org gmane.linux.lib.musl.general:12221 Archived-At: Hi, There are a couple of lines I've had to hack out of the Makefile to get Was= m to build. In WebAssembly, we can't use crti.s/crtn.s, because the compile= r doesn't support raw assembly chunks like that. That should be OK, since there are default empty files in "crt/{crti,crtn}.= c". Those empty files are currently unused, as all archs provide the assemb= ly versions. For WebAssembly, I'm happy for those empty C files to be used. There's some clever stuff at the top of the Makefile to construct BASE_SRCS= and ARCH_SRCS, and it works fine for WebAssembly: we just compile the dumm= y .c files if the .s files aren't provided by the arch. The problem is further down the Makefile, where an apparently unnecessary d= ependency is placed on the assembly files. I can't work out why these two l= ines are there, and they need to be removed in one way or another for the W= asm build to succeed. Getting rid of them doesn't seem to have any negative= consequences for the standard x86 build. Patch below. Thanks, Nick =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D diff --git a/Makefile b/Makefile index d2e89979..308ddaae 100644 --- a/Makefile +++ b/Makefile @@ -113,10 +113,6 @@ obj/crt/rcrt1.o: $(srcdir)/ldso/dlstart.c =20 obj/crt/Scrt1.o obj/crt/rcrt1.o: CFLAGS_ALL +=3D -fPIC =20 -obj/crt/$(ARCH)/crti.o: $(srcdir)/crt/$(ARCH)/crti.s - -obj/crt/$(ARCH)/crtn.o: $(srcdir)/crt/$(ARCH)/crtn.s - OPTIMIZE_SRCS =3D $(wildcard $(OPTIMIZE_GLOBS:%=3D$(srcdir)/src/%)) $(OPTIMIZE_SRCS:$(srcdir)/%.c=3Dobj/%.o) $(OPTIMIZE_SRCS:$(srcdir)/%.c=3Do= bj/%.lo): CFLAGS +=3D -O3 =20