Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .github/scripts/build-headers.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/sh

set -eu #Needed so CI fails when anything is wrong
set -x

#Any arguments are passed to configure

cd src
./autogen.sh
./configure "$@" --disable-check-runtime-deps --enable-werror
make headers
37 changes: 20 additions & 17 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ env:
jobs:

rip-and-test:
runs-on: ubuntu-24.04
runs-on: ubuntu-26.04
timeout-minutes: 45
steps:
- name: Dump GitHub context
Expand Down Expand Up @@ -57,7 +57,7 @@ jobs:
.github/scripts/verify-clean-repo.sh

rip-headless:
runs-on: ubuntu-24.04
runs-on: ubuntu-26.04
timeout-minutes: 45
steps:
- name: Dump GitHub context
Expand Down Expand Up @@ -109,7 +109,7 @@ jobs:
.github/scripts/verify-clean-repo.sh

rip-rtai:
runs-on: ubuntu-24.04
runs-on: ubuntu-26.04
timeout-minutes: 45
steps:
- name: Dump GitHub context
Expand Down Expand Up @@ -138,7 +138,7 @@ jobs:
.github/scripts/verify-clean-repo.sh

rip-and-test-clang:
runs-on: ubuntu-24.04
runs-on: ubuntu-26.04
timeout-minutes: 45
steps:
- name: Dump GitHub context
Expand Down Expand Up @@ -172,7 +172,7 @@ jobs:
.github/scripts/verify-clean-repo.sh

cppcheck:
runs-on: ubuntu-24.04
runs-on: ubuntu-26.04
timeout-minutes: 45
steps:
- name: Checkout repository
Expand All @@ -183,16 +183,19 @@ jobs:
- name: Install dependencies
run: |
set -x
.github/scripts/use-main-ubuntu-mirror.sh
sudo apt-get -q update
.github/scripts/install-deps.sh
sudo apt-get --yes install cppcheck
- name: Build headers
run: |
set -x
.github/scripts/build-headers.sh --with-realtime=uspace
- name: Cppcheck
run: |
set -x
scripts/cppcheck.sh

shellcheck:
runs-on: ubuntu-24.04
runs-on: ubuntu-26.04
timeout-minutes: 45
steps:
- name: Checkout repository
Expand All @@ -215,7 +218,7 @@ jobs:
scripts/shellcheck.sh

htmldocs:
runs-on: ubuntu-24.04
runs-on: ubuntu-26.04
timeout-minutes: 60
steps:
- name: Dump GitHub context
Expand All @@ -241,15 +244,15 @@ jobs:
run: scripts/manpage-name-check.py --enforce docs/build/man
- name: Check for derived-id section references
run: scripts/docs-anchor-check.py --enforce
- name: Verify no untracked or modified files after build
run: |
#*.po and documentation.pot are modifyed by build. Ignore them for now.
.github/scripts/verify-clean-repo.sh ':(exclude)docs/po/*.po' ':(exclude)docs/po/documentation.pot'
- name: HTML checks
run: |
set -x
#-w sets warn only, remove to generate a CI failure on error
scripts/htmlcheck.sh -w
- name: Verify no untracked or modified files after build
run: |
#*.po and documentation.pot are modified by build. Ignore them for now.
.github/scripts/verify-clean-repo.sh ':(exclude)docs/po/*.po' ':(exclude)docs/po/documentation.pot'
- name: Tar linuxcnc-doc
run: |
set -x
Expand All @@ -267,7 +270,7 @@ jobs:
timeout-minutes: 75
strategy:
matrix:
runner: ["ubuntu-24.04", "ubuntu-24.04-arm"]
runner: ["ubuntu-26.04", "ubuntu-26.04-arm"]
image: ["debian:bookworm", "debian:trixie", "debian:sid"]
include:
- allow_fail: False
Expand Down Expand Up @@ -357,7 +360,7 @@ jobs:
if-no-files-found: error

package-indep:
runs-on: ubuntu-24.04
runs-on: ubuntu-26.04
timeout-minutes: 75
strategy:
matrix:
Expand Down Expand Up @@ -410,7 +413,7 @@ jobs:
.github/scripts/build-package-indep.sh
- name: Verify no untracked or modified files after build
run: |
#*.po and documentation.pot are modifyed by build. Ignore them for now.
#*.po and documentation.pot are modified by build. Ignore them for now.
.github/scripts/verify-clean-repo.sh ':(exclude)VERSION' ':(exclude)debian/changelog' ':(exclude)docs/po/*.po' ':(exclude)docs/po/documentation.pot'
- name: Install debian packages
run: |
Expand Down Expand Up @@ -447,7 +450,7 @@ jobs:
if: (github.event_name == 'release' && github.event.action == 'published') || startsWith(github.ref, 'refs/tags/')
permissions:
contents: write
runs-on: ubuntu-24.04
runs-on: ubuntu-26.04
steps:
- name: Download artifacts
uses: actions/download-artifact@v8
Expand Down
7 changes: 7 additions & 0 deletions src/emc/rs274ngc/Submakefile
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,13 @@ LIBRS274SRCS += emc/nml_intf/modal_state.cc
USERSRCS += $(LIBRS274SRCS)

$(call TOOBJSDEPS, $(LIBRS274SRCS)) : EXTRAFLAGS+=-fPIC $(BOOST_DEBUG_FLAGS)

# interp_g7x.cc takes discrete threshold branches on iterated floating-point
# values; FMA contraction (GCC default -ffp-contract=fast when targeting
# x86-64-v3, as on the ubuntu-26.04 CI runners) changes rounding enough to
# flip branches and diverge the G71 toolpath. Disable contraction for this
# file so codegen is independent of the compiler default arch.
$(call TOOBJS, emc/rs274ngc/interp_g7x.cc): EXTRAFLAGS += -ffp-contract=off
$(call TOOBJSDEPS, emc/rs274ngc/pyinterp1.cc emc/rs274ngc/pyparamclass.cc emc/rs274ngc/pyinterp1.cc emc/rs274ngc/pyblock.cc emc/rs274ngc/pyarrays.cc emc/rs274ngc/interpmodule.cc): EXTRAFLAGS += $(SILENCE_BOOST_INTERNAL_DIAGNOSTICS_FLAGS)

TARGETS += ../lib/librs274.so ../lib/librs274.so.0
Expand Down
2 changes: 1 addition & 1 deletion src/emc/rs274ngc/gcodemodule.cc
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ class MoveBatch {
// have still been handed over once, and re-delivering them from a later
// flush would duplicate them in the consumer's program.
count_ = 0;
PyObject *view = PyMemoryView_FromMemory((char*)buf_,
PyObject *view = PyMemoryView_FromMemory(reinterpret_cast<char*>(buf_),
(Py_ssize_t)n * ROW * sizeof(double), PyBUF_READ);
if(!view) { interp_error ++; return; }
PyObject *result = callmethod(callback, "move_batch", "O", view);
Expand Down
Loading
Loading