From nobody Mon Apr 11 17:53:29 2022 X-Original-To: ports@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id E3A0F8D63F1 for ; Mon, 11 Apr 2022 17:55:38 +0000 (UTC) (envelope-from fernando.apesteguia@gmail.com) Received: from mail-lj1-f170.google.com (mail-lj1-f170.google.com [209.85.208.170]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Kcc2y0jk1z4qnM for ; Mon, 11 Apr 2022 17:55:38 +0000 (UTC) (envelope-from fernando.apesteguia@gmail.com) Received: by mail-lj1-f170.google.com with SMTP id q189so4535275ljb.13 for ; Mon, 11 Apr 2022 10:55:38 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=cT2MyQBiSkxXVKHrWg+Qf2M3wYlXFGVgla+OjS06oxE=; b=eEI652Mz/lNIwM9rjmqzw0y0Uf5Exer3VMOnPufKIl5MdcMNqX/gFMcpMhA9qipLjR RcRIRMljJBk4JBma2exGndYc3c1cIheoBVaizjltHYn5wHnF73snJFm+OeJ/CLCFoJxU umJdqjfgi+fZIJTUjrt6/4wPa+QseM0HnpZPJH83toRfkjlAAABrsJGghXykPd/jmxks GmwSTIJWQtHdfSEG7vVz8oMdkl7sRUTLyJbugNygAlp6lIJjMdEwg710OFQ0PnxkLM+C aUqvoETIedtRJBCjhkA6hjxIqktkmfswyrWeJIahfQSt3698NdhEZk+hcx/5FCxMg2i7 e/5Q== X-Gm-Message-State: AOAM533HLIQCrUs7WhRokCBsBcBcB3PTnJUZvuUugVg9M8miSqnoo6Xq ZZRkBQz3rr6LJ305IPM+w/vGCvOjrL6yIw== X-Google-Smtp-Source: ABdhPJyU9qVcz6y0pHViy6hs2L4E4Yicm7jnCEOtMno9KGrDYdR5CBe3J3ObdIaT/LuCJIRVtjx7BQ== X-Received: by 2002:a2e:9b59:0:b0:24b:439c:8928 with SMTP id o25-20020a2e9b59000000b0024b439c8928mr14397385ljj.154.1649699731027; Mon, 11 Apr 2022 10:55:31 -0700 (PDT) Received: from mail-lj1-f171.google.com (mail-lj1-f171.google.com. [209.85.208.171]) by smtp.gmail.com with ESMTPSA id 194-20020a2e05cb000000b0024b5c059e31sm710330ljf.138.2022.04.11.10.55.30 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 11 Apr 2022 10:55:30 -0700 (PDT) Received: by mail-lj1-f171.google.com with SMTP id r18so5460308ljp.0 for ; Mon, 11 Apr 2022 10:55:30 -0700 (PDT) X-Received: by 2002:a2e:7f13:0:b0:247:ef72:9e8b with SMTP id a19-20020a2e7f13000000b00247ef729e8bmr20982812ljd.205.1649699729943; Mon, 11 Apr 2022 10:55:29 -0700 (PDT) List-Id: Porting software to FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-ports List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-ports@freebsd.org X-BeenThere: freebsd-ports@freebsd.org MIME-Version: 1.0 References: In-Reply-To: From: =?UTF-8?Q?Fernando_Apestegu=C3=ADa?= Date: Mon, 11 Apr 2022 19:53:29 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: Build issue with i386 port To: jbo@insane.engineer Cc: "ports@freebsd.org" Content-Type: text/plain; charset="UTF-8" X-Rspamd-Queue-Id: 4Kcc2y0jk1z4qnM X-Spamd-Bar: / Authentication-Results: mx1.freebsd.org; dkim=none; dmarc=none; spf=pass (mx1.freebsd.org: domain of fernandoapesteguia@gmail.com designates 209.85.208.170 as permitted sender) smtp.mailfrom=fernandoapesteguia@gmail.com X-Spamd-Result: default: False [-0.24 / 15.00]; TO_DN_EQ_ADDR_SOME(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:209.85.128.0/17:c]; RCVD_COUNT_THREE(0.00)[4]; NEURAL_HAM_SHORT(-1.00)[-1.000]; RCPT_COUNT_TWO(0.00)[2]; FORGED_SENDER(0.30)[fernape@freebsd.org,fernandoapesteguia@gmail.com]; MIME_TRACE(0.00)[0:+]; R_DKIM_NA(0.00)[]; FREEMAIL_ENVFROM(0.00)[gmail.com]; FROM_NEQ_ENVFROM(0.00)[fernape@freebsd.org,fernandoapesteguia@gmail.com]; R_MIXED_CHARSET(0.62)[subject]; ASN(0.00)[asn:15169, ipnet:209.85.128.0/17, country:US]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.86)[-0.862]; TAGGED_FROM(0.00)[]; FROM_HAS_DN(0.00)[]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[ports@freebsd.org]; DMARC_NA(0.00)[freebsd.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_SPAM_LONG(1.00)[1.000]; RCVD_IN_DNSWL_NONE(0.00)[209.85.208.170:from,209.85.208.171:received]; MLMMJ_DEST(0.00)[ports]; RWL_MAILSPIKE_POSSIBLE(0.00)[209.85.208.170:from]; RCVD_TLS_ALL(0.00)[] X-ThisMailContainsUnwantedMimeParts: N On Mon, Apr 11, 2022 at 7:24 PM wrote: > > Hello folks, > > I'm fairly new to the porting game so please bear with me. > > A few months ago, I created my first port: sysutils/cpufetch > Back then, I was only testing this on amd64 so ONLY_FOR_ARCHS was set to amd64. > In the meantime, I've spun up some i386 VMs (both FreeBSD 13 and 14) as upstream advertises to also support 32-bit FreeBSD. > In the VMs, if I just clone the upstream repository [1] and run gmake, the software compiles & runs fine. > After those successful tests I've updated the port's Makefile to also include i386 in ONLY_FOR_ARCHS. > > Not long after, I was receiving my first pkg fallout message informing me that the official pkg builds are failing: > > =================================================== > ===> Building for cpufetch-1.00_1 > gmake[1]: Entering directory '/wrkdirs/usr/ports/sysutils/cpufetch/work/cpufetch-1.00' > Makefile:38: Unsupported arch detected: i386. See https://github.com/Dr-Noob/cpufetch#1-support > Makefile:39: If your architecture is supported but the compilation fails, please open an issue in https://github.com/Dr-Noob/cpufetch/issues > Makefile:40: *** Aborting compilation. Stop. > gmake[1]: Leaving directory '/wrkdirs/usr/ports/sysutils/cpufetch/work/cpufetch-1.00' > ===> Compilation failed unexpectedly. > Try to set MAKE_JOBS_UNSAFE=yes and rebuild before reporting the failure to > the maintainer. > *** Error code 1 > > Upstream's Makefile uses $(shell uname -m) to determine the architecture [2]. My VMs are successfully reporting this as > i386 which upstream's Makefile appears to support explicitly. After all, I'm also able to build this software > on those VMs if just cloning & running gmake manually. > > I'm not really sure where to go from here. As I can build the software in FreeBSD i386 VMs I think > that the issue is related to my port and not upstream. But then again, the build fails "within" upstream's Makefile. > > Could somebody help me out here? When the Makefile checks the output of uname -m, it compares the result with a list of values that includes i686 but not i386. I think a simple REINPLACE_CMD would suffice here. Since I failed to detect this, do you want me to fix it in the repo? I will also send a patch upstream. Cheers. > > [1] https://github.com/dr-noob/cpufetch > [2] https://github.com/Dr-Noob/cpufetch/blob/master/Makefile#L14 > > > Best regards, > ~ Joel Bodenmann >