From 65f2daa1e41f38db5e29a73af9c02d6c390b1d24 Mon Sep 17 00:00:00 2001 From: davidovski Date: Thu, 7 Apr 2022 12:01:06 +0100 Subject: added neovim and its dependencies --- repo/apps/neovim.xibuild | 26 ++++++++++++++ repo/apps/xterm.xibuild | 49 ++++++++++++++++--------- repo/skip/xf86-video-qxl.xibuild | 18 ---------- repo/system/ljx.xibuild | 19 ++++++++++ repo/system/lua-lpeg.xibuild | 50 ++++++++++++++++++++++++++ repo/system/lua-mpack.xibuild | 56 +++++++++++++++++++++++++++++ repo/system/lua.xibuild | 67 +++++++++++++++++----------------- repo/system/lua5-1.xibuild | 77 ++++++++++++++++++++++++++++++++++++++++ repo/system/luajit.xibuild | 32 +++++++++++++++++ repo/system/tree-sitter.xibuild | 22 ++++++++++++ repo/x11/bspwm.xibuild | 4 +-- repo/x11/spice-protocol.xibuild | 20 +++++++++++ repo/x11/xf86-video-qxl.xibuild | 27 ++++++++++++++ 13 files changed, 396 insertions(+), 71 deletions(-) create mode 100644 repo/apps/neovim.xibuild delete mode 100644 repo/skip/xf86-video-qxl.xibuild create mode 100644 repo/system/ljx.xibuild create mode 100644 repo/system/lua-lpeg.xibuild create mode 100644 repo/system/lua-mpack.xibuild create mode 100644 repo/system/lua5-1.xibuild create mode 100644 repo/system/luajit.xibuild create mode 100644 repo/system/tree-sitter.xibuild create mode 100644 repo/x11/spice-protocol.xibuild create mode 100644 repo/x11/xf86-video-qxl.xibuild (limited to 'repo') diff --git a/repo/apps/neovim.xibuild b/repo/apps/neovim.xibuild new file mode 100644 index 0000000..0b22d0e --- /dev/null +++ b/repo/apps/neovim.xibuild @@ -0,0 +1,26 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="libintl libluv libtermkey libuv libvterm luajit msgpack-c musl tree-sitter unibilium lua-lpeg lua-mpack" + +PKG_VER=0.6.1 +SOURCE=https://github.com/neovim/neovim/archive/v$PKG_VER.tar.gz +DESC="Vim-fork focused on extensibility and agility" + +build () { + mkdir build + cmake -B build \ + -DCMAKE_BUILD_TYPE=MinSizeRel \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DCMAKE_INSTALL_LIBDIR=lib \ + -DENABLE_JEMALLOC=FALSE \ + -DENABLE_LTO=TRUE \ + -DUSE_BUNDLED=ON \ + -DCMAKE_VERBOSE_MAKEFILE=TRUE + cmake --build build +} + + +package () { + DESTDIR="$PKG_DEST" cmake --install build +} diff --git a/repo/apps/xterm.xibuild b/repo/apps/xterm.xibuild index 69ae2ff..bceb89d 100644 --- a/repo/apps/xterm.xibuild +++ b/repo/apps/xterm.xibuild @@ -5,8 +5,8 @@ DEPS="libxft libxaw ncurses luit xbitmaps libutempter libxkbfile" DESC="X Terminal Emulator" -PKG_VER=370 -SOURCE=https://invisible-mirror.net/archives/xterm/xterm-$PKG_VER.tgz +PKG_VER=371 +SOURCE=ftp://ftp.invisible-island.net/xterm/xterm-$PKG_VER.tgz ADDITIONAL=" posix-ptys.patch " @@ -20,8 +20,37 @@ prepare () { } build () { - ./configure $XORG_CONFIG \ - --with-tty-group=tty + ./configure \ + $XORG_CONFIG \ + --prefix=/usr \ + --sysconfdir=/etc \ + --mandir=/usr/share/man \ + --infodir=/usr/share/info \ + --localstatedir=/var \ + --with-x \ + --disable-full-tgetent \ + --disable-imake \ + --enable-ansi-color \ + --enable-88-color \ + --enable-256-color \ + --enable-broken-osc \ + --enable-broken-st \ + --enable-load-vt-fonts \ + --enable-i18n \ + --enable-wide-chars \ + --enable-doublechars \ + --enable-warnings \ + --enable-tcap-query \ + --enable-logging \ + --enable-dabbrev \ + --enable-freetype \ + --enable-luit \ + --enable-mini-luit \ + --enable-narrowproto \ + --enable-exec-xterm \ + --enable-sixel-graphics \ + --with-tty-group=tty \ + --with-utempter make } @@ -31,16 +60,4 @@ package () { mkdir -p $PKG_DEST/usr/share/applications && cp *.desktop $PKG_DEST/usr/share/applications/ - - - mkdir -p $PKG_DEST/etc/X11/app-defaults - cat >> $PKG_DEST/etc/X11/app-defaults/XTerm << "EOF" -*VT100*locale: true -*VT100*faceName: Monospace -*VT100*faceSize: 10 -*backarrowKeyIsErase: true -*ptyInitialErase: true -EOF - - } diff --git a/repo/skip/xf86-video-qxl.xibuild b/repo/skip/xf86-video-qxl.xibuild deleted file mode 100644 index ca70116..0000000 --- a/repo/skip/xf86-video-qxl.xibuild +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make" -DEPS="xorg-server" - -DESC="X.org qxl video driver" - -PKG_VER=0.1.5 -SOURCE=https://www.x.org/pub/individual/driver/xf86-video-qxl-$PKG_VER.tar.bz2 - -build () { - ./configure $XORG_CONFIG - make -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/system/ljx.xibuild b/repo/system/ljx.xibuild new file mode 100644 index 0000000..c28cd7b --- /dev/null +++ b/repo/system/ljx.xibuild @@ -0,0 +1,19 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="musl" + +PKG_VER=1.3 +SOURCE=https://github.com/katlogic/ljx/archive/refs/tags/LJX-v$PKG_VER.tar.gz + +DESC="LuaJIT experimental 5.2/5.3 port" + + +build () { + make PREFIX=/usr + +} + +package () { + make install DESTDIR="$PKG_DEST" PREFIX=/usr +} diff --git a/repo/system/lua-lpeg.xibuild b/repo/system/lua-lpeg.xibuild new file mode 100644 index 0000000..f2b3b4d --- /dev/null +++ b/repo/system/lua-lpeg.xibuild @@ -0,0 +1,50 @@ +#!/bin/sh + +MAKEDEPS="make tar patch lua lua5-1" +DEPS="musl" + +PKG_VER=1.0.2 +SOURCE=http://www.inf.puc-rio.br/~roberto/lpeg/lpeg-$PKG_VER.tar.gz +DESC="Pattern-matching library for Lua" +ADDITIONAL=" + build-static-lib.patch + test-fix-setlocale.patch +" + +luaversions="5.1 5.4" + +prepare () { + apply_patches + +# lver=$(lua -v | cut -d" " -f2 | cut -d. -f-2) + sed -i -e 's/^CFLAGS =/CFLAGS +=/' \ + -e 's/^COPT =/# COPT =/' \ + makefile + + for lver in $luaversions; do + tar xf lpeg-$PKG_VER.tar.gz + mv lpeg-$PKG_VER build-$lver + done +} + +build () { + for lver in $luaversions; do + echo building for $lver + make -C build-$lver LUADIR=/usr/include/lua$lver + done +} + +package () { + for lver in $luaversions; do + cd build-$lver + install -Dm755 lpeg.so \ + $PKG_DEST/usr/lib/lua/$lver/lpeg.so + install -Dm644 re.lua \ + $PKG_DEST/usr/share/lua/$lver/re.lua + + local rockdir="$PKG_DEST/usr/lib/luarocks/rocks-$lver/lua-lpeg/$PKG_VER-1" + mkdir -p "$rockdir" + echo 'rock_manifest = {}' > "$rockdir"/rock_manifest + cd .. + done +} diff --git a/repo/system/lua-mpack.xibuild b/repo/system/lua-mpack.xibuild new file mode 100644 index 0000000..85c5195 --- /dev/null +++ b/repo/system/lua-mpack.xibuild @@ -0,0 +1,56 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="musl libmpack" + +PKG_VER=1.0.9 +SOURCE=https://github.com/libmpack/libmpack-lua/archive/$PKG_VER.tar.gz +DESC="Libmpack bindings for Lua" +ADDITIONAL=" +dont-install-busted.patch +skip-memleak-test.patch +" + +luaversions="5.1 " + +prepare () { + apply_patches + + for lver in $luaversions; do + tar xf $PKG_VER.tar.gz + mv libmpack-lua-$PKG_VER build-$lver + done + +} + +build () { + for lver in $luaversions; do + echo "building for lua $lver" + make -C build-$lver \ + FETCH=false \ + USE_SYSTEM_LUA=yes \ + USE_SYSTEM_MPACK=yes \ + LUA=lua$lver \ + LUA_IMPL=lua$lver + #LUA_INCLUDE="$(pkg-config --cflags lua$lver)" \ + #LUA_LIB="$(pkg-config --libs lua$lver)" + done + +} + +package () { + for lver in $luaversions; do + echo "building for lua $lver" + local rockdir="$PKG_DEST/usr/lib/luarocks/rocks-$lver/mpack/$PKG_VER-0" + + make -C build-$lver \ + USE_SYSTEM_LUA=yes \ + USE_SYSTEM_MPACK=yes \ + LUA_CMOD_INSTALLDIR="$(pkg-config --variable=INSTALL_CMOD lua$lver)" \ + DESTDIR="$subpkgdir" \ + install || exit 1 + + mkdir -p "$rockdir" + echo 'rock_manifest = {}' > "$rockdir"/rock_manifest + done +} diff --git a/repo/system/lua.xibuild b/repo/system/lua.xibuild index c8c992f..fdcf8ab 100644 --- a/repo/system/lua.xibuild +++ b/repo/system/lua.xibuild @@ -7,53 +7,50 @@ PKG_VER=5.4.4 SOURCE=https://www.lua.org/ftp/lua-$PKG_VER.tar.gz ADDITIONAL=" https://www.linuxfromscratch.org/patches/blfs/svn/lua-$PKG_VER-shared_library-1.patch + lua5.4.pc " + DESC="A powerful lightweight scripting language" prepare () { - cat > lua.pc << "EOF" -V=5.4 -R=5.4.4 - -prefix=/usr -INSTALL_BIN=${prefix}/bin -INSTALL_INC=${prefix}/include -INSTALL_LIB=${prefix}/lib -INSTALL_MAN=${prefix}/share/man/man1 -INSTALL_LMOD=${prefix}/share/lua/${V} -INSTALL_CMOD=${prefix}/lib/lua/${V} -exec_prefix=${prefix} -libdir=${exec_prefix}/lib -includedir=${prefix}/include - -Name: Lua -Description: An Extensible Extension Language -Version: ${R} -Requires: -Libs: -L${libdir} -llua -lm -ldl -Cflags: -I${includedir} -EOF - -patch -Np1 -i lua-$PKG_VER-shared_library-1.patch + sed -e "s|@MAJOR_VER@|${PKG_VER%.*}|g" \ + -e "s|@MINOR_VER@|${PKG_VER}|g" \ + -i lua5.4.pc + + patch -Np1 -i lua-$PKG_VER-shared_library-1.patch + cat > configure.ac <<-EOF + top_buildir=. + + AC_INIT(src/luaconf.h) + AC_PROG_LIBTOOL + AC_OUTPUT() + EOF + libtoolize --force --install && aclocal && autoconf + } build () { - make linux + ./configure \ + --prefix=/usr + cd src + CFLAGS="$CFLAGS -DLUA_USE_LINUX -DLUA_COMPAT_5_2" \ + SYSLDFLAGS="$LDFLAGS" \ + RPATH="/usr/lib" make } package () { - make INSTALL_TOP=/usr \ - DESTDIR=$PKG_DEST \ - INSTALL="install" \ - INSTALL_MAN=/usr/share/man/man1 \ - TO_LIB="liblua.so liblua.so.${PKG_VER} liblua.so.5.4.4" \ - install && - - mkdir -p $PKG_DEST/usr/share/doc/lua-$PKG_VER && + cd .. + sed -i "s/INSTALL= install -p/INSTALL= install/g" Makefile + make V=${PKG_VER%.*} \ + INSTALL_TOP="$PKG_DEST"/usr \ + INSTALL_INC="$PKG_DEST"/usr/include/lua${PKG_VER%.*} \ + INSTALL_LIB="$PKG_DEST"/usr/lib/lua${PKG_VER%.*} install + + + mkdir -p $PKG_DEST/usr/share/doc/lua-$PKG_VER for s in html css gif png; do cp doc/*.$s $PKG_DEST/usr/share/doc/lua-$PKG_VER done - - install -m644 -D lua.pc $PKG_DEST/usr/lib/pkgconfig/lua.pc + install -Dm644 lua5.4.pc "$PKG_DEST"/usr/lib/pkgconfig/lua5.4.pc } diff --git a/repo/system/lua5-1.xibuild b/repo/system/lua5-1.xibuild new file mode 100644 index 0000000..5fc5f80 --- /dev/null +++ b/repo/system/lua5-1.xibuild @@ -0,0 +1,77 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="readline" + +PKG_VER=5.1.5 +SOURCE=https://www.lua.org/ftp/lua-$PKG_VER.tar.gz + +# use alpinelinux's makefile +ADDITIONAL=" + lua-5.1-make.patch + lua-5.1-module_paths.patch + lua-5.1-readline.patch +" + +DESC="A powerful lightweight scripting language" + +prepare () { + + apply_patches + + # we want packages to find our things + sed -i 's:/usr/local:/usr:' etc/lua.pc + + # correct lua versioning + sed -i 's/\(LIB_VERSION = \).*/\16:4:1/' src/Makefile + + cat > configure.ac <<-EOF + top_buildir=. + + AC_INIT(src/luaconf.h) + AC_PROG_LIBTOOL + AC_OUTPUT() + EOF + libtoolize --force --install && aclocal && autoconf + + +} + +build () { + ./configure \ + --prefix=/usr + cd src + make CFLAGS="$CFLAGS -DLUA_USE_LINUX" \ + SYSLDFLAGS="$LDFLAGS" \ + LIB_LIBS="-lpthread -lm -ldl" \ + RPATH="/usr/lib" \ + V=${PKG_VER%.*} alpine_all +} + +package () { + cd .. + sed -i "s/INSTALL= install -p/INSTALL= install/g" Makefile + make V=$PKG_VER \ + INSTALL_TOP="$PKG_DEST/usr" \ + INSTALL_INC="$PKG_DEST/usr/include" \ + INSTALL_LIB="$PKG_DEST/usr/lib" \ + alpine_install + + install -D -m 644 etc/lua.pc "$PKG_DEST"/usr/lib/pkgconfig/lua5.1.pc + install -D -m 644 doc/lua.1 "$PKG_DEST"/usr/share/man/man1/lua5.1.1 + install -D -m 644 doc/luac.1 "$PKG_DEST"/usr/share/man/man1/luac5.1.1 + + mkdir -p "$PKG_DEST"/usr/share/doc/lua5-1/ + install -m644 doc/*.html doc/*.css doc/logo.gif doc/cover.png \ + "$PKG_DEST"/usr/share/doc/lua5-1/ + + # Create symlinks without version suffix. + ln -s lua5.1 "$PKG_DEST"/usr/bin/lua + ln -s luac5.1 "$PKG_DEST"/usr/bin/luac + ln -s lua5.1.pc "$PKG_DEST"/usr/lib/pkgconfig/lua.pc + ln -s lua5.1.1 "$PKG_DEST"/usr/share/man/man1/lua.1 + ln -s luac5.1.1 "$PKG_DEST"/usr/share/man/man1/luac.1 + + + install -m644 -D etc/lua.pc $PKG_DEST/usr/lib/pkgconfig/lua5.1.pc +} diff --git a/repo/system/luajit.xibuild b/repo/system/luajit.xibuild new file mode 100644 index 0000000..09f6015 --- /dev/null +++ b/repo/system/luajit.xibuild @@ -0,0 +1,32 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="musl lua5-1" + +PKG_VER=2.1 +SUBVER=20220310 +SOURCE=https://github.com/openresty/luajit2/archive/refs/tags/v$PKG_VER-$SUBVER.tar.gz +ADDITIONAL=" +module-paths.patch +" + +DESC="OpenResty's branch of LuaJIT" + +prepare () { + apply_patches +} + +build () { + local xcflags="-DLUAJIT_ENABLE_LUA52COMPAT -DLUAJIT_NUMMODE=2" + [ "$CARCH" = x86_64 ] && xcflags="$xcflags -msse4.2" + make amalg PREFIX=/usr XCFLAGS="$xcflags" + +} + +package () { + make install DESTDIR="$PKG_DEST" PREFIX=/usr + + install -Dm644 COPYRIGHT \ + $PKG_DEST/usr/share/licenses/luajit/COPYRIGHT + +} diff --git a/repo/system/tree-sitter.xibuild b/repo/system/tree-sitter.xibuild new file mode 100644 index 0000000..ccd2b77 --- /dev/null +++ b/repo/system/tree-sitter.xibuild @@ -0,0 +1,22 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="musl" + +PKG_VER=0.20.6 +SOURCE=https://github.com/tree-sitter/tree-sitter/archive/v$PKG_VER/tree-sitter-$PKG_VER.tar.gz +DESC="Incremental parsing system for programming tools" + +prepare () { + cargo fetch --locked +} + +build () { + make + cargo build -p tree-sitter-cli --frozen --release +} + +package () { + make DESTDIR=$PKG_DEST PREFIX=/usr install + install -D -m755 target/release/tree-sitter $PKG_DEST/usr/bin/ +} diff --git a/repo/x11/bspwm.xibuild b/repo/x11/bspwm.xibuild index b91a965..5512061 100644 --- a/repo/x11/bspwm.xibuild +++ b/repo/x11/bspwm.xibuild @@ -9,9 +9,9 @@ SOURCE=https://github.com/baskerville/bspwm/archive/refs/tags/$PKG_VER.tar.gz DESC="Tiling window manager based on binary space partitioning" build () { - make + make PREFIX=/usr } package () { - make DESTDIR=$PKG_DEST install + make PREFIX=/usr DESTDIR=$PKG_DEST install } diff --git a/repo/x11/spice-protocol.xibuild b/repo/x11/spice-protocol.xibuild new file mode 100644 index 0000000..8656080 --- /dev/null +++ b/repo/x11/spice-protocol.xibuild @@ -0,0 +1,20 @@ +#!/bin/sh + +MAKEDEPS="make" +DEPS="xorg-server" + +DESC="Spice protocol headers" + +PKG_VER=0.14.3 +SOURCE=https://www.spice-space.org/download/releases/spice-protocol-$PKG_VER.tar.xz + +build () { + mkdir build + cd build + meson --prefix=/usr .. + ninja +} + +package () { + DESTDIR=$PKG_DEST ninja install +} diff --git a/repo/x11/xf86-video-qxl.xibuild b/repo/x11/xf86-video-qxl.xibuild new file mode 100644 index 0000000..f7fd090 --- /dev/null +++ b/repo/x11/xf86-video-qxl.xibuild @@ -0,0 +1,27 @@ +#!/bin/sh + +MAKEDEPS="make spice-protocol" +DEPS="xorg-server" + +DESC="X.org qxl video driver" + +PKG_VER=0.1.5 +SOURCE=https://www.x.org/pub/individual/driver/xf86-video-qxl-$PKG_VER.tar.bz2 +ADDITIONAL=" + buildfix.patch + convert-xspice-python3.patch +" + +prepare () { + apply_patches +} + +build () { + ./configure $XORG_CONFIG + make +} + + +package () { + make DESTDIR=$PKG_DEST install +} -- cgit v1.2.1