Skip to content

devel/readline: fix build failure on DragonFly#1544

Closed
dragonflybot wants to merge 1 commit into
masterfrom
agentic/devel-readline-20260528-225306Z
Closed

devel/readline: fix build failure on DragonFly#1544
dragonflybot wants to merge 1 commit into
masterfrom
agentic/devel-readline-20260528-225306Z

Conversation

@dragonflybot

Copy link
Copy Markdown
Member

Generated by the DragonFly agentic build-fix loop and verified in a clean dev-env. Reviewed and accepted by operator operator before submission.

Problem

The build failed on @2026Q2 — classified compile-error, confidence medium.

The FreeBSD base port applies a patch to terminal.c that adds the cons25 termtype to the dumbterm assignment. During materialisation into DeltaPorts the patch was not applied correctly – the leading + from the patch’s unified-diff context ended up as a literal character in the source line. This turns the expression into + dumbterm, a unary-plus that is not an lvalue, and the compiler rejects it.

Evidence:

  • Compile error and the offending line (with a literal leading +):
    ./terminal.c: In function '_rl_init_terminal_io':
    ./terminal.c:583:13: error: lvalue required as left operand of assignment
     +  dumbterm = STREQ (term, "dumb") || STREQ (term, "vt52") || STREQ (term, "adm3a") || STREQ (term, "cons25");
               ^
    
  • cons25 is a FreeBSD-specific console terminal type; it does not exist in upstream GNU readline source. This confirms that a FreeBSD-originated patch modified terminal.c, and that the patch was mangled when applied.

Fix

Automated fix for the build failure in devel/readline.

What changed

1 file changed, +1/-0

  • ports/devel/readline/overlay.dops

Verification

Built successfully in a DragonFly dev-env (dsynth) for target @2026Q2.
Verified 2026-05-28T22:56:55.782297+00:00.

Provenance

  • Operator: operator
  • Agent: model=deepseek/deepseek-v4-pro attempts=1 tokens=147077

> Generated by the DragonFly agentic build-fix loop and verified in a clean dev-env. Reviewed and accepted by operator `operator` before submission.

## Problem

The build failed on `@2026Q2` — classified `compile-error`, confidence `medium`.

The FreeBSD base port applies a patch to `terminal.c` that adds the `cons25` termtype to the `dumbterm` assignment.  During materialisation into DeltaPorts the patch was not applied correctly – the leading `+` from the patch’s unified-diff context ended up as a literal character in the source line.  This turns the expression into `+ dumbterm`, a unary-plus that is not an lvalue, and the compiler rejects it.

**Evidence:**

- Compile error and the offending line (with a literal leading `+`):
  ```
  ./terminal.c: In function '_rl_init_terminal_io':
  ./terminal.c:583:13: error: lvalue required as left operand of assignment
   +  dumbterm = STREQ (term, "dumb") || STREQ (term, "vt52") || STREQ (term, "adm3a") || STREQ (term, "cons25");
             ^
  ```
- `cons25` is a FreeBSD-specific console terminal type; it does not exist in upstream GNU readline source.  This confirms that a FreeBSD-originated patch modified `terminal.c`, and that the patch was mangled when applied.

## Fix

Automated fix for the build failure in `devel/readline`.

## What changed

1 file changed, +1/-0

- `ports/devel/readline/overlay.dops`

## Verification

Built successfully in a DragonFly dev-env (dsynth) for target `@2026Q2`.
Verified 2026-05-28T22:56:55.782297+00:00.

## Provenance

- Operator: operator
- Agent: model=deepseek/deepseek-v4-pro attempts=1 tokens=147077

Signed-off-by: Fred [bot] <github@dragonflybsd.org>
@tuxillo tuxillo marked this pull request as ready for review May 28, 2026 23:02
@tuxillo tuxillo closed this May 28, 2026
@tuxillo tuxillo deleted the agentic/devel-readline-20260528-225306Z branch May 28, 2026 23:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants