Skip to content

Commit 4e2b5e4

Browse files
author
peng.li24
committed
fix(deb): move flavor suffix after version number in DEB filename (ver-flavor convention)
1 parent e304dd6 commit 4e2b5e4

3 files changed

Lines changed: 12 additions & 10 deletions

File tree

.github/workflows/ci.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,9 @@
99
# Same API, pure <cmath> + C++ loops. Tests run with atol/rtol tolerance.
1010
# No external math dependencies.
1111
#
12-
# DEB packaging:
13-
# cmake -DNUMPYCPP_STD_ONLY=OFF → numpycpp-dev-bitexact-*.deb
14-
# cmake -DNUMPYCPP_STD_ONLY=ON → numpycpp-dev-std-*.deb
12+
# DEB packaging (flavor appears after version number in filename):
13+
# cmake -DNUMPYCPP_STD_ONLY=OFF → numpycpp-dev-<ver>-bitexact-Linux.deb
14+
# cmake -DNUMPYCPP_STD_ONLY=ON → numpycpp-dev-<ver>-std-Linux.deb
1515

1616
name: CI
1717

@@ -123,13 +123,13 @@ jobs:
123123
run: |
124124
cmake -S . -B build_bitexact -DNUMPYCPP_STD_ONLY=OFF
125125
cmake --build build_bitexact --target deb
126-
ls build_bitexact/*.deb
126+
ls build_bitexact/numpycpp-dev-*-bitexact-*.deb
127127
128128
- name: Build std DEB
129129
run: |
130130
cmake -S . -B build_std_deb -DNUMPYCPP_STD_ONLY=ON
131131
cmake --build build_std_deb --target deb
132-
ls build_std_deb/*.deb
132+
ls build_std_deb/numpycpp-dev-*-std-*.deb
133133
134134
- name: Upload DEBs as artifacts
135135
uses: actions/upload-artifact@v4

CMakeLists.txt

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,11 @@ install(DIRECTORY example/
7979
)
8080

8181
# ---- CPack DEB packaging ----------------------------------------------------
82-
# Package name and description differ by backend:
83-
# bitexact: numpycpp-dev-bitexact-<ver>-Linux.deb
84-
# std: numpycpp-dev-std-<ver>-Linux.deb
82+
# Package name and file name differ by backend flavor.
83+
# File naming: numpycpp-dev-<version>-<flavor>-Linux.deb
84+
# bitexact: numpycpp-dev-1.21.2-bitexact-Linux.deb
85+
# std: numpycpp-dev-1.21.2-std-Linux.deb
86+
# Package name keeps the flavor so both DEBs can coexist on the same machine.
8587
if(NUMPYCPP_STD_ONLY)
8688
set(_NUMPYCPP_DEB_FLAVOR "std")
8789
set(_NUMPYCPP_DEB_SUMMARY "C++ numpy-API header-only library — pure std backend (perf-first)")
@@ -101,7 +103,7 @@ set(CPACK_DEBIAN_PACKAGE_MAINTAINER "miaobyte")
101103
set(CPACK_DEBIAN_PACKAGE_SECTION "libdevel")
102104
set(CPACK_DEBIAN_PACKAGE_PRIORITY "optional")
103105
set(CPACK_DEBIAN_FILE_NAME
104-
"numpycpp-dev-${_NUMPYCPP_DEB_FLAVOR}-${CPACK_PACKAGE_VERSION}-Linux.deb")
106+
"numpycpp-dev-${CPACK_PACKAGE_VERSION}-${_NUMPYCPP_DEB_FLAVOR}-Linux.deb")
105107
set(CPACK_PACKAGING_INSTALL_PREFIX "/usr")
106108
# Wipe the old include tree on install/upgrade so stale headers cannot accumulate.
107109
set(CPACK_DEBIAN_PACKAGE_CONTROL_EXTRA "${CMAKE_CURRENT_SOURCE_DIR}/cmake/preinst")

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ cmake -DNUMPYCPP_STD_ONLY=ON .. # std / performance-first backend
130130
| **Dot / matmul** | OpenBLAS ILP64 via `dlsym` | Pure C++ loops (auto-vectorised) |
131131
| **Precision vs numpy** | **IEEE 754 bit-identical** | 0–2 ULP (not bit-exact) |
132132
| **External deps** | libdl + numpy `.so` loaded | **None** — pure C++17 |
133-
| **DEB package** | `numpycpp-dev-bitexact-*.deb` | `numpycpp-dev-std-*.deb` |
133+
| **DEB package** | `numpycpp-dev-<ver>-bitexact-Linux.deb` | `numpycpp-dev-<ver>-std-Linux.deb` |
134134
| **cmake propagation** | `target_link_libraries(… dl)` | `target_compile_definitions(… NUMPYCPP_STD_ONLY)` |
135135

136136
#### Compiler flags — bitexact backend (`NUMPYCPP_STD_ONLY=OFF`)

0 commit comments

Comments
 (0)