aboutsummaryrefslogblamecommitdiffstats
path: root/community/fennel/APKBUILD
blob: 7484a17d36ee32f95f1d1f174a79124d3da57e60 (plain) (tree)
1
2
3
4
5
6
7
8
9


                                                 
            
        



                             
                                                                                            
                
                                           


                          
                            


         
                                                                              
                                                                 





                                                                 


                                                                 

                                                                        
 


                                                                
                                     


                                                
                                                                                                                                                                  
# Contributor: Will Sinatra <wpsinatra@gmail.com>
# Maintainer: Will Sinatra <wpsinatra@gmail.com>
pkgname=fennel
pkgver=0.7.0
pkgrel=0
pkgdesc="A Lua Lisp Language"
url="https://fennel-lang.org"
arch="all"
license="MIT"
source="fennel-$pkgver.tar.gz::https://git.sr.ht/~technomancy/fennel/archive/$pkgver.tar.gz"
_lua_version=5.3
makedepends="lua5.3 lua5.3-dev lua5.3-libs"
subpackages="$pkgname-doc"

check() {
	make test LUA=lua5.3
}

build() {
	make fennel-bin LUA=lua5.3 STATIC_LUA_LIB=/usr/lib/liblua-5.3.so.0.0.0
	./fennel-bin --compile src/fennel/binary.fnl > binary.lua
}

package() {
	install -Dm644 "fennelview.lua" \
			-t "$pkgdir/usr/share/lua/$_lua_version/"

	install -Dm644 "fennel.lua" \
			-t "$pkgdir/usr/share/lua/$_lua_version/"

	install -Dm644 "binary.lua" \
			-t "$pkgdir/usr/share/lua/$_lua_version/fennel/"

	install -Dm644 "fennel.1" \
			-t "$pkgdir/usr/share/man/man1/fennel.1"

	install -Dm755 "fennel-bin" \
			"$pkgdir/usr/bin/fennel"
}

sha512sums="d0497291e88337ea02d4716b029e6ebc5252170babd0c14d998a5f45a92d924f2e66e1a185bb5f1e42b32ba7a69cda6c24de7dfe432e03c91a15079da1609f06  fennel-0.7.0.tar.gz"