with the cvs history? trying to help INDEX builds.

Matthew Seaman m.seaman at infracaninophile.co.uk
Sat Jan 21 20:05:22 UTC 2012

On 21/01/2012 19:33, Mark Linimon wrote:
> On Thu, Jan 19, 2012 at 08:58:04AM +0000, Matthew Seaman wrote:
>> By my calculations there are 28 ports that set 'BROKEN' because of
>> architecture incompatibility on my amd64 system
> IMHO these Makefiles are broken and should be fixed.

Actually, collecting the data by another method, it seems that there are
359 ports that set BROKEN with the reason mentioning ${ARCH}, i386,
amd64, ia64, powerpc or sparc.  Of course this doesn't pick up cases
where there's no clue about the architecture in the BROKEN message.

I have a patch adding a BROKEN_FOR_ARCHS variable, parallel to
ONLY_FOR_ARCHS, but I haven't managed to test it properly yet.  I
thought I'd try applying it or {ONLY,NOT}_FOR_ARCHS (as I judge[*]
appropriate) to the 79 of those ports which haven't got a maintainer,
which should show well enough if it works properly.



[*] well, more like guess really.


How I worked out those numbers:

i) Used my portindexdb stuff to get a list of all the Makefiles under

select path from makefile where path ~ '^/usr/ports/[^/]+/[^/]+/'

ii) Grep through those makefiles for lines starting BROKEN= and
mentioning something to do with CPU architecture:

< /tmp/ports-makefiles xargs grep -l
'^BROKEN=.*\(${ARCH}\|i386\|amd64\|ia64\|powerpc\|sparc\)' >

-- results in 359 matches

iii) Then grep through those 359 makefiles for ones containing
ports at FreeBSD.org

% < /tmp/ports-BROKEN-for-arch xargs grep -l 'ports at FreeBSD.org' >

-- results in 79 matches.

MK/bsd.ports.mk patch:

cvs diff: Diffing .
Index: bsd.port.mk
RCS file: /home/ncvs/ports/Mk/bsd.port.mk,v
retrieving revision 1.702
diff -u -u -r1.702 bsd.port.mk
--- bsd.port.mk	15 Jan 2012 22:13:42 -0000	1.702
+++ bsd.port.mk	21 Jan 2012 19:36:50 -0000
@@ -222,6 +222,18 @@
 #				- Set this instead of ONLY_FOR_ARCHS if the given port
 #				  fetches and installs compiled i386 binaries.
+# Set these if your port temporarily does not work on certain
+# architectures due to programming errors, broken dependencies
+# etc. Values are lists of architecture names as above. (Defaults: not
+# set)
+#               - Declare port broken on ${ARCH} if the port is temporarily
+#                 unusable there
+#               - Reason why the port is broken on ${ARCH}
 # Dependency checking.  Use these if your port requires another port
 # not in the list below.  (Default: empty.)
@@ -3156,6 +3168,26 @@


+.if defined(BROKEN_FOR_ARCHS)
+.if ${ARCH:M${__BARCH}} != ""
+.if defined(__ARCH_BROKEN)
+BROKEN=		broken on ${BROKEN_FOR_ARCHS}, and you are running ${ARCH}
 # Check the user interaction and legal issues
 .if !defined(NO_IGNORE)
 .if (defined(IS_INTERACTIVE) && defined(BATCH))

As I said, not tested yet.  I'll submit this and patches against those
79 ports as a PR once I've managed to do that.

Dr Matthew J Seaman MA, D.Phil.                   7 Priory Courtyard
                                                  Flat 3
PGP: http://www.infracaninophile.co.uk/pgpkey     Ramsgate
JID: matthew at infracaninophile.co.uk               Kent, CT11 9PW

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 267 bytes
Desc: OpenPGP digital signature
Url : http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20120121/18f702a4/signature.pgp

More information about the freebsd-ports mailing list