Bug 254481

Summary: lang/fpc: drop dependency on COMPAT_FREEBSD10
Product: Ports & Packages Reporter: Jan Beich <jbeich>
Component: Individual Port(s)Assignee: Jose Alonso Cardenas Marquez <acm>
Status: Closed FIXED    
Severity: Affects Only Me Keywords: buildisok, patch
Priority: --- Flags: bugzilla: maintainer-feedback? (acm)
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
fix
none
fix none

Description Jan Beich freebsd_committer 2021-03-22 16:53:52 UTC
Created attachment 223502 [details]
fix

rtl/bsd/bunxsysc.inc defines PIPE_RESULT_IN_EAX_AND_EDX on FreeBSD which makes FPpipe use inline asm instead of do_syscall. Fix by adopting Linux definition i.e., pass 0 as flags (2nd) argument

$ make clean all -C lang/fpc
[...]
./fpmake compile --localunitdir=../.. --globalunitdir=.. --os=freebsd --cpu=x86_64 -o -Cg -o -dx86_64 --compiler=/usr/ports/lang/fpc/work/fpc-3.2.0/compiler/ppcx64 -bu
gmake[1]: *** [Makefile:2484: all] Bad system call

$ truss packages/fcl-res/fpmake |& fgrep 'not implemented'
compat10.pipe()                                  ERR#78 'Function not implemented'

$ sysctl kern.conftxt | fgrep -i compat
options COMPAT_LINUXKPI
options COMPAT_FREEBSD12
options COMPAT_FREEBSD11
options COMPAT_FREEBSD32
Comment 1 Jan Beich freebsd_committer 2021-03-22 16:57:27 UTC
Created attachment 223503 [details]
fix

Drop __pipe_call as it's no longer used after inline asm was removed.
Comment 2 Automation User 2021-04-06 00:13:42 UTC
Build and package info is available at https://gitlab.com/swills/freebsd-ports/pipelines/281778139
Comment 3 Jose Alonso Cardenas Marquez freebsd_committer 2021-04-16 18:07:34 UTC
Hi Jan

Maybe the best just is remove "defined(freebsd) or" from this line:

{$if defined(freebsd) or defined (dragonfly)}

What do you think?
Comment 4 Jan Beich freebsd_committer 2021-04-16 20:29:52 UTC
(In reply to Jose Alonso Cardenas Marquez from comment #3)
Leaving DragonFly alone to fend off cruft is not a good idea.
https://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/ca1161c61688e19d06150eef59b47e2f8188e7d5
Comment 5 commit-hook freebsd_committer 2021-08-01 01:57:35 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=e40d870fc3cb88063b59d0f8449b9ccbdf5378ea

commit e40d870fc3cb88063b59d0f8449b9ccbdf5378ea
Author:     Jose Alonso Cardenas Marquez <acm@FreeBSD.org>
AuthorDate: 2021-08-01 01:52:39 +0000
Commit:     Jose Alonso Cardenas Marquez <acm@FreeBSD.org>
CommitDate: 2021-08-01 01:56:08 +0000

    lang/fpc: update to 3.2.2

    * Add new unit devel/fpc-tplylib
    * Remove COMPAT10 dependency  [PR/254481]
    PR:             254481
    Reported by:    jbeich

 Mk/Uses/fpc.mk                                     |  5 ++-
 Mk/bsd.default-versions.mk                         |  4 +-
 audio/fpc-mad/files/patch-packages_mad_fpmake.pp   |  2 +-
 .../files/patch-packages_modplug_fpmake.pp         |  2 +-
 databases/fpc-fpindexer/pkg-plist                  |  2 +
 databases/fpc-mysql/Makefile                       |  1 -
 databases/fpc-mysql/pkg-plist                      |  3 ++
 databases/fpc-sqlite/Makefile                      |  1 -
 devel/Makefile                                     |  1 +
 devel/fpc-dbus/pkg-plist                           |  3 ++
 devel/fpc-fcl-base/Makefile                        |  2 +-
 devel/fpc-fcl-base/pkg-plist                       |  3 --
 devel/fpc-fcl-db/Makefile                          |  1 -
 devel/fpc-fcl-db/pkg-plist                         |  6 +++
 devel/fpc-fcl-extra/Makefile                       |  2 +-
 devel/fpc-fcl-extra/pkg-plist                      |  3 ++
 devel/fpc-fcl-fpcunit/Makefile                     |  1 -
 devel/fpc-fcl-passrc/Makefile                      |  1 -
 devel/fpc-fcl-pdf/pkg-plist                        |  4 ++
 devel/fpc-fcl-res/Makefile                         |  1 +
 devel/fpc-fcl-res/pkg-plist                        |  4 ++
 devel/fpc-regexpr/Makefile                         |  1 -
 devel/fpc-tplylib/Makefile (new)                   | 12 ++++++
 devel/fpc-tplylib/pkg-plist (new)                  |  5 +++
 lang/fpc-base/Makefile                             |  3 +-
 lang/fpc-docs/Makefile                             |  2 +-
 lang/fpc-docs/distinfo                             |  6 +--
 .../files/patch-packages-pastojs_fpmake.pp (gone)  | 14 -------
 lang/fpc-rtl-extra/Makefile                        |  1 -
 lang/fpc-rtl-objpas/Makefile                       |  1 -
 lang/fpc-rtl-objpas/pkg-plist                      |  1 +
 lang/fpc-source/Makefile                           |  2 +-
 lang/fpc-source/distinfo                           |  6 +--
 lang/fpc-units/Makefile                            |  8 ++--
 lang/fpc-utils/Makefile                            |  1 -
 lang/fpc-utils/pkg-plist                           |  4 --
 lang/fpc/Makefile                                  |  7 ++--
 lang/fpc/distinfo                                  | 12 +++---
 lang/fpc/files/patch-rtl-bsd_bunxsysc.inc          | 49 +++++++++++++++++-----
 lang/fpc/files/patch-rtl-freebsd_unxfunc.inc       |  2 +-
 .../files/patch-packages_libvlc_fpmake.pp          |  2 +-
 41 files changed, 117 insertions(+), 74 deletions(-)
Comment 6 Jose Alonso Cardenas Marquez freebsd_committer 2021-08-01 02:06:59 UTC
Committed thanks!