From MAILER-DAEMON Wed Nov 12 09:21:10 2025
Received: from list by lists.gnu.org with archive (Exim 4.90_1)
	id 1vJBig-000628-9S
	for mharc-gforth@gnu.org; Wed, 12 Nov 2025 09:21:10 -0500
Received: from eggs.gnu.org ([2001:470:142:3::10])
 by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256)
 (Exim 4.90_1) (envelope-from <marvin.littlewood.426716@gmail.com>)
 id 1vJBiV-0005lF-0z
 for gforth@gnu.org; Wed, 12 Nov 2025 09:21:01 -0500
Received: from mail-lj1-x22a.google.com ([2a00:1450:4864:20::22a])
 by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
 (Exim 4.90_1) (envelope-from <marvin.littlewood.426716@gmail.com>)
 id 1vJBiT-0007wM-6u
 for gforth@gnu.org; Wed, 12 Nov 2025 09:20:58 -0500
Received: by mail-lj1-x22a.google.com with SMTP id
 38308e7fff4ca-37b95f87d64so4332051fa.2
 for <gforth@gnu.org>; Wed, 12 Nov 2025 06:20:56 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=gmail.com; s=20230601; t=1762957254; x=1763562054; darn=gnu.org;
 h=content-transfer-encoding:to:subject:message-id:date:from
 :mime-version:from:to:cc:subject:date:message-id:reply-to;
 bh=fMsstiSToAbJUQ8tKagBtTcip8A/xeMgfmg7+4rDbvM=;
 b=gQm2dDW4sFQM+x7GeS75/8FuLdrosBP2+92gTkqfGcdgcg8YMlnKkVEEkaigCfxQRv
 d90rWfh3H3CYGfHozDOK7YyhTtQXSMmaU4yJp6YS94yp5dF+e5zSCTx/yrJszUpEnVdT
 NI/w3wqjzGwVWkH3IF5fgbZsHDkyajY1aG+Wyz/qQZIfVTQImC+Ldq9o8L7ZtLWMBrQm
 9U410GX4rYkeRm6l/Gy1uOzZaliU/8j5MQwY0HKuDi9kkqCrY8pMpgbBEUVZUAzM8ldY
 HLr0dtk9O1x3iGourtuTnsW7W0h8Dcoo82/chtu/TclRSp1M39e5HefFQ79p8w4qXfKl
 sbDw==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20230601; t=1762957254; x=1763562054;
 h=content-transfer-encoding:to:subject:message-id:date:from
 :mime-version:x-gm-gg:x-gm-message-state:from:to:cc:subject:date
 :message-id:reply-to;
 bh=fMsstiSToAbJUQ8tKagBtTcip8A/xeMgfmg7+4rDbvM=;
 b=gRiXjvmtdkjpi4zuFceBFuRrqDmshmujMliabFP411uCCidpeNdEN3hXEZ8rWfU3gs
 iinDenx/g41l+SkA9QacH4cGMfU+iH//vTIvlnz2qrGV05U+oiduu1SL1USMiqkDxB/R
 lQJW6CVqS873cZ83CtBN4R772/9gp5z80KjAUz2eLf6/SOkrH/CAyhmsv8owg2uVZopv
 mTYPq7ekIDDU5CmSpFBdTRVuCuouYHjTktmV+mPyecpGNoiBdKeYcza5mN778nuzfTSH
 E7m+OcASeWQA5Bn7Qc03AH1f46jOEOw2jTT9r03ShL5uKCrugZEfoGzqmOGWwp5eyH4d
 +oKA==
X-Gm-Message-State: AOJu0YyW/N2sLtkxp9Pc4BYmSd0yDaONTuIG90FA3SQGtp7qZq0alSVX
 1eTyc3Vt4pIOwgGYSeTvRN2JTKHB2sVFBHz2b4gzwLxKGP3Ohp1dp9q46BAf9gN1JtElSEJ0Od9
 CI7Av2Q7VL9ro1+s4Q5sNrLIDzx1LhyJ/5VMT
X-Gm-Gg: ASbGncvLi96c8wvvTsweOnZmSNnGHfg2CeBGLvomABH1oEI1W77UDGyrxbMyf6WfkSh
 xw37Ky2rXLgG2vggi50m6gOMDlGu1qCOB02qvltknBb8PCI7PRL6dNgfdB9NTHlO2lN8rb6c0EZ
 Qec9zf9WD+FPn21JlHWowky8ow7hlJ0lng8RoMxY5M8NtOtI3qQzpjvDv8LljB5cX0C8nO2w6Gf
 hzE27fThVMbqH/3E1G0sL9N2GIva/cnrviBguHSISSl/60J+gKA0X+xgyMJ
X-Google-Smtp-Source: AGHT+IGYDxnHYmYQoQRE6RP2yGt07PDHEQw9Q51lPyVMCtvWsoMnsrQ99+GMQ6Gq+ZD+YQq9PonhDxJkEf55/i+I5H0=
X-Received: by 2002:a05:651c:31d2:b0:372:8f0d:b0bc with SMTP id
 38308e7fff4ca-37b8c317413mr9718931fa.9.1762957253453; Wed, 12 Nov 2025
 06:20:53 -0800 (PST)
MIME-Version: 1.0
From: Marvin Littlewood <marvin.littlewood.426716@gmail.com>
Date: Wed, 12 Nov 2025 14:20:41 +0000
X-Gm-Features: AWmQ_blhZNax3O24LPUOYt3sQvXkFqvyo5TExQplAKuRLdve24q36ueHK94TW4E
Message-ID: <CABMy3_Bw44qKuKHz6TjNNrSEuuzYTB09LSn-_rPAXAsJfhUnRg@mail.gmail.com>
Subject: Missing semi-colon while compiling gforth 20251001 using MacPorts
To: gforth@gnu.org
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Received-SPF: pass client-ip=2a00:1450:4864:20::22a;
 envelope-from=marvin.littlewood.426716@gmail.com;
 helo=mail-lj1-x22a.google.com
X-Spam_score_int: -17
X-Spam_score: -1.8
X-Spam_bar: -
X-Spam_report: (-1.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1,
 DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1,
 FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001,
 RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001,
 SPF_PASS=-0.001 autolearn=ham autolearn_force=no
X-Spam_action: no action
X-BeenThere: gforth@gnu.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Gforth discussion and announcements <gforth.gnu.org>
List-Unsubscribe: <https://lists.gnu.org/mailman/options/gforth>,
 <mailto:gforth-request@gnu.org?subject=unsubscribe>
List-Archive: <https://lists.gnu.org/archive/html/gforth>
List-Post: <mailto:gforth@gnu.org>
List-Help: <mailto:gforth-request@gnu.org?subject=help>
List-Subscribe: <https://lists.gnu.org/mailman/listinfo/gforth>,
 <mailto:gforth-request@gnu.org?subject=subscribe>
X-List-Received-Date: Wed, 12 Nov 2025 14:21:05 -0000

Back in June, I tried compiling the 0.7.9_20250611 tarball on a
MacBook Pro (Intel) using MacPorts' libraries. This failed - see (SWIG
can't process X11 files in a MacPorts build)

I downloaded the 0.7.9_20251001 tarball. I installed almost all the
required dependencies from a fully updated MacPorts on my Mac Mini
(M4, Sequoia) using the homebrew and debian lists in install-deps.sh
as a guide. and then carried out the following steps:

sudo port select --set gcc mp-gcc14
export CC=3Dgcc
./install-swig.sh --nosudo "--prefix=3D$PWD/local"
export PATH=3D"$PATH:$PWD/local/bin=E2=80=9D
export CFLAGS=3D"-I/opt/local/include"
export LDFLAGS=3D"-L/opt/local/lib"
./configure --prefix=3D/Users/mark/Applications/gforth/0.7.9_20250817

All dependencies were met according to the output of ./configure so I
ran make -j 1. The compile failed as follows:

--- Error message:
SWIG-GEN x.fs
Failed x-fsi.c on first attempt
--------------compilation output--------------
x-fsi.c: In function 'main':
x-fsi.c:4233:60: error: expected ';' before 'if'
 4233 |         if(offsetof(struct _XExtData, free_private) >=3D 0) 0
      |                                                            ^
      |                                                            ;
 4234 |         if(offsetof(struct funcs, create_image) >=3D 0) 0
      |         ~~
------------compilation output end------------
x-fsi-fixed.c: In function 'main':
x-fsi-fixed.c:4234:56: error: expected ';' before 'if'

 4234 |         if(offsetof(struct funcs, create_image) >=3D 0) 0
      |                                                        ^
      |                                                        ;
 4235 |         if(offsetof(struct funcs, destroy_image) >=3D 0) 0
      |         ~~
make[1]: *** [x.fs] Error 1
make: *** [unix/x.fs] Error 2

Around line 4230 in x-fsi-fixed.c, the problematic code is:

 if(offsetof(struct _XExtData, free_private) >=3D 0) 0
 if(offsetof(struct funcs, create_image) >=3D 0) 0
 if(offsetof(struct funcs, destroy_image) >=3D 0) 0
 if(offsetof(struct funcs, get_pixel) >=3D 0) 0
 if(offsetof(struct funcs, put_pixel) >=3D 0) 0
 if(offsetof(struct funcs, sub_image) >=3D 0) 0
 if(offsetof(struct funcs, add_pixel) >=3D 0) 0

It appears that the following script in x.i is failing to put a
semicolon after the terminal \0.

// prep: sed -e
's/swigFunctionPointer.*{((\([^*]*\)\*)ptr)->\([^}]*\)}.*/if(offsetof(\1,
\2) >=3D 0) \0/g'

I added the semicolon and re-built clean. The process completed
without error and x.fs exists. I cannot be certain that replacing the
semicolon is the right way to go, but looking at the code, an extra
one would not affect its meaning.

My next problem is that gl.fs is missing, despite there being
unix/gl.i and unix/gl-fsi.c. Also GL/gl.h can be found in the given
include paths. I am in the process of investigating this issue. Any
thoughts welcome...

Many thanks


