Skip to content

fix: add DXF image export to CLI#289

Merged
spe-ciellt merged 2 commits intodevelopfrom
fix/dxf-cli-export
Feb 27, 2026
Merged

fix: add DXF image export to CLI#289
spe-ciellt merged 2 commits intodevelopfrom
fix/dxf-cli-export

Conversation

@spe-ciellt
Copy link
Copy Markdown
Contributor

Cherry-pick of PR #228 by @snhobbs, rebased onto develop with conflict resolution. Based on #228

Closes #227.

Adds --export=dxf to the CLI. Calls gerbv_export_dxf_file_from_image() (already present in export-dxf.cpp). The #ifndef ENABLE_DXF stub was dropped — DXF export is always available.

Original commit by Simon Hobbs (@snhobbs), 2023-11-24, preserved in git history.

Co-authored-by: snhobbs simon.hobbs@electrooptical.net

snhobbs and others added 2 commits February 27, 2026 16:35
Cherry-picked from PR #228 (0a4e276), rebased onto develop.
Conflicts resolved: removed #ifndef ENABLE_DXF stub (function already
exists in export-dxf.cpp), adapted to develop's coding style and
existing --svg-layers help text.

Co-authored-by: simon <simon.hobbs@electrooptical.net>
When dxflib is not installed, export-dxf.cpp is not compiled and
gerbv_export_dxf_file_from_image() is undefined. Guard all DXF
references in main.c (enum, name arrays, switch cases, help text)
with #ifdef HAVE_LIBDXFLIB to fix the linker error on systems
without dxflib.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@spe-ciellt spe-ciellt self-assigned this Feb 27, 2026
@spe-ciellt spe-ciellt merged commit f0c6ea4 into develop Feb 27, 2026
1 check passed
@spe-ciellt spe-ciellt deleted the fix/dxf-cli-export branch February 28, 2026 10:09
@spe-ciellt spe-ciellt added the enhancement New feature or request label Feb 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add DXF export to CLI export type

2 participants