2022-08-05 04:19:01 +03:00
|
|
|
distributable:
|
|
|
|
url: https://ftp.gnu.org/gnu/readline/readline-{{ version.raw }}.tar.gz
|
|
|
|
strip-components: 1
|
|
|
|
|
|
|
|
versions:
|
2023-05-08 18:17:44 +03:00
|
|
|
url: https://ftp.gnu.org/gnu/readline/
|
|
|
|
match: /readline-\d+\.\d+(\.\d+)?\.tar\.gz/
|
|
|
|
strip:
|
|
|
|
- /readline-/
|
|
|
|
- /.tar.gz/
|
2022-08-05 04:19:01 +03:00
|
|
|
#TODO brew has a couple patches we should apply
|
|
|
|
|
|
|
|
dependencies:
|
2023-03-10 18:51:03 +03:00
|
|
|
invisible-island.net/ncurses: ^6
|
2022-08-05 04:19:01 +03:00
|
|
|
|
|
|
|
build:
|
2023-12-17 05:37:17 +03:00
|
|
|
script:
|
|
|
|
- ./configure --prefix={{ prefix }} --with-curses
|
|
|
|
- make --jobs {{ hw.concurrency }} install
|
|
|
|
env:
|
|
|
|
linux:
|
|
|
|
# otherwise it weirdly omits the linkage
|
|
|
|
# https://stackoverflow.com/a/65623630
|
|
|
|
LDFLAGS: '$LDFLAGS -lncursesw'
|
2022-08-05 04:19:01 +03:00
|
|
|
|
|
|
|
test:
|
2023-12-17 05:37:17 +03:00
|
|
|
- run: ldd {{prefix}}/lib/libreadline.so | grep ncurses
|
|
|
|
if: linux
|
|
|
|
- run: otool -L {{prefix}}/lib/libreadline.dylib | grep ncurses
|
|
|
|
if: darwin
|
|
|
|
- cc -lreadline -lncurses fixture.c
|
|
|
|
- |
|
2023-03-10 18:51:03 +03:00
|
|
|
test "$(echo "Hello, World!" | ./a.out)" = "test> Hello, World!
|
|
|
|
Hello, World!\\n"
|