Fork of tn5250/tn5250 adding CCSID 1145 (Spain/Latin America + Euro sign) support with wide-character rendering.
CCSID 1145 support — the Euro-enabled variant of CCSID 284 (Spain). The Euro sign (U+20AC) is properly rendered on UTF-8 terminals using ncurses wide-character support (add_wch).
The upstream tn5250 only supports CCSID 284 which lacks the Euro sign. CCSID 1145 is identical to 284 except EBCDIC byte 0x9F maps to € instead of ¤.
Note: The accented character fix (setlocale issue) is now fixed upstream in commit e1ce065.
A signed and Apple-notarized binary is available in Releases.
- Signed: Developer ID Application: Beach Lab LTD
- Notarized: Apple notarization accepted (no Gatekeeper warnings)
# Install dependencies
brew install ncurses openssl@3 luit
# Download and install
curl -L https://github.com/TheBeachLab/tn5250/releases/latest/download/tn5250-0.19.0-macos-arm64.zip -o /tmp/tn5250.zip
unzip /tmp/tn5250.zip -d /tmp/tn5250-bin
cp /tmp/tn5250-bin/tn5250 ~/.local/bin/tn5250
chmod +x ~/.local/bin/tn5250# Dependencies (macOS)
brew install ncurses openssl@3 cmake
# Build
git clone https://github.com/TheBeachLab/tn5250.git
cd tn5250
mkdir build && cd build
cmake .. -DCMAKE_C_FLAGS="-I$(brew --prefix ncurses)/include"
make -j4
# Binary at curses/tn5250
cp curses/tn5250 ~/.local/bin/tn5250tn5250 map=1145 env.TERM=IBM-3179-2 your.as400.host:23For ISO-8859-15 terminal compatibility (e.g. inside tmux), wrap with luit:
luit -encoding ISO-8859-15 tn5250 map=1145 env.TERM=IBM-3179-2 your.as400.host:23| Code page | Language | Map parameter |
|---|---|---|
| 37 | US English | map=37 |
| 284 | Spain | map=284 |
| 1145 | Spain + Euro | map=1145 |
| 273 | Germany | map=273 |
| 297 | France | map=297 |
| 280 | Italy | map=280 |
| 278 | Sweden/Finland | map=278 |
| 500 | International | map=500 |
| Type | Dimensions | Description |
|---|---|---|
| IBM-3179-2 | 24x80 | Standard color (default) |
| IBM-3477-FC | 27x132 | Wide mode color |
| IBM-3477-FG | 27x132 | Wide mode monochrome |
GPL-2.0 (same as upstream tn5250)
- Original project: tn5250/tn5250
- CCSID 1145 support and macOS build: Beach Lab LTD