kind: manual
depends:
- python2-core.bst
- tools.bst
- morph-utils.bst
- pcre-utils.bst
sources:
- kind: git
  url: upstream:lua
  track: baserock/5.1-morph
  ref: 948063437e0350d9ef1649ec3a76d0c24a5c8642
config:
  configure-commands:
  - sed -e 's/defined(LUA_USE_READLINE)/0/g' src/luaconf.h.orig >src/luaconf.h
  - sed -i -e '/^linux:/{n;s/-lreadline//g;s/-lhistory//g;s/-lncurses//g}' src/Makefile
  build-commands:
  - make debian_linux INSTALL_TOP="%{prefix}" RPATH="%{prefix}/lib"
  install-commands:
  - make INSTALL_TOP="%{install-root}/%{prefix}" debian_install
  - mkdir -p "%{install-root}/%{prefix}/lib/pkgconfig"
  - cp lua5.1.pc "%{install-root}/%{prefix}/lib/pkgconfig/"
