From 739c65c54cb0e957df5e9b76f93fb02554e5cac3 Mon Sep 17 00:00:00 2001 From: davidovski Date: Wed, 4 May 2022 23:52:30 +0100 Subject: moved everything to new file formatting --- repo/devel/asciidoc.xibuild | 15 -- repo/devel/asciidoc/asciidoc.xibuild | 15 ++ repo/devel/autoconf-archive.xibuild | 21 --- .../autoconf-archive/autoconf-archive.xibuild | 21 +++ repo/devel/autoconf.xibuild | 17 -- repo/devel/autoconf/autoconf.xibuild | 17 ++ repo/devel/autoconf2-13.xibuild | 30 ---- repo/devel/autoconf2-13/autoconf2-13.xibuild | 30 ++++ repo/devel/automake.xibuild | 24 --- repo/devel/automake/automake.xibuild | 24 +++ repo/devel/bc.xibuild | 21 --- repo/devel/bc/bc.xibuild | 21 +++ repo/devel/bison.xibuild | 17 -- repo/devel/bison/bison.xibuild | 17 ++ repo/devel/boost.xibuild | 23 --- .../0001-revert-cease-dependence-on-range.patch | 1 + .../boost/boost-1.57.0-python-abi_letters.patch | 62 +++++++ .../boost/boost-1.57.0-python-libpython_dep.patch | 13 ++ repo/devel/boost/boost.xibuild | 23 +++ repo/devel/boost/python-3.10.patch | 49 ++++++ repo/devel/cbindgen.xibuild | 18 -- repo/devel/cbindgen/cbindgen.xibuild | 18 ++ repo/devel/check.xibuild | 17 -- repo/devel/check/check.xibuild | 17 ++ repo/devel/clang.xibuild | 57 ------ repo/devel/clang/clang.xibuild | 57 ++++++ repo/devel/clang/patches/10-add-musl-triples.patch | 35 ++++ ...ack-protector-by-default-for-Alpine-Linux.patch | 81 +++++++++ repo/devel/cmake-extra.xibuild | 20 --- repo/devel/cmake-extra/cmake-extra.xibuild | 20 +++ repo/devel/cmake-modules.xibuild | 21 --- repo/devel/cmake-modules/cmake-modules.xibuild | 21 +++ repo/devel/cmake.xibuild | 17 -- repo/devel/cmake/cmake.xibuild | 17 ++ repo/devel/compiler-rt.xibuild | 38 ---- repo/devel/compiler-rt/compiler-rt.xibuild | 38 ++++ repo/devel/compiler-rt/link-execinfo.patch | 11 ++ repo/devel/dejagnu.xibuild | 28 --- repo/devel/dejagnu/dejagnu.xibuild | 28 +++ repo/devel/distcc.xibuild | 34 ---- ...dcc_gcc_rewrite_fqn-avoid-heap-corruption.patch | 65 +++++++ repo/devel/distcc/distcc-hardened.patch | 24 +++ repo/devel/distcc/distcc.xibuild | 34 ++++ repo/devel/distcc/gcc-10.patch | 15 ++ repo/devel/docbook-dtd.xibuild | 128 -------------- repo/devel/docbook-dtd/docbook-dtd.xibuild | 128 ++++++++++++++ repo/devel/docbook-xml.xibuild | 132 -------------- repo/devel/docbook-xml/docbook-xml.xibuild | 132 ++++++++++++++ repo/devel/docbook-xsl.xibuild | 74 -------- repo/devel/docbook-xsl/docbook-xsl.xibuild | 74 ++++++++ repo/devel/docbook4-xml.xibuild | 104 ----------- repo/devel/docbook4-xml/docbook4-xml.xibuild | 104 +++++++++++ repo/devel/expect.xibuild | 25 --- repo/devel/expect/expect.xibuild | 25 +++ repo/devel/flex.xibuild | 24 --- repo/devel/flex/flex.xibuild | 24 +++ repo/devel/gcc.xibuild | 193 --------------------- repo/devel/gcc/gcc.xibuild | 193 +++++++++++++++++++++ repo/devel/gdb.xibuild | 32 ---- repo/devel/gdb/gdb.xibuild | 32 ++++ repo/devel/git.xibuild | 19 -- repo/devel/git/git.xibuild | 19 ++ repo/devel/go.xibuild | 67 ------- repo/devel/go/go.xibuild | 67 +++++++ repo/devel/gtk-doc.xibuild | 22 --- repo/devel/gtk-doc/gtk-doc.xibuild | 22 +++ repo/devel/help2man.xibuild | 18 -- repo/devel/help2man/help2man.xibuild | 18 ++ repo/devel/icecream.xibuild | 19 -- repo/devel/icecream/icecream.xibuild | 19 ++ repo/devel/imake.xibuild | 23 --- repo/devel/imake/imake.xibuild | 23 +++ repo/devel/itstool.xibuild | 19 -- repo/devel/itstool/itstool.xibuild | 19 ++ repo/devel/libexecinfo.xibuild | 32 ---- repo/devel/libexecinfo/10-execinfo.patch | 64 +++++++ repo/devel/libexecinfo/20-define-gnu-source.patch | 24 +++ repo/devel/libexecinfo/30-linux-makefile.patch | 44 +++++ repo/devel/libexecinfo/libexecinfo.xibuild | 32 ++++ repo/devel/lld.xibuild | 29 ---- repo/devel/lld/lld.xibuild | 29 ++++ repo/devel/llvm-libunwind.xibuild | 48 ----- repo/devel/llvm-libunwind/libcxx-musl.patch | 28 +++ .../llvm-libunwind/libunwind-link-libssp.patch | 20 +++ repo/devel/llvm-libunwind/llvm-libunwind.xibuild | 48 +++++ repo/devel/llvm.xibuild | 54 ------ repo/devel/llvm/llvm.xibuild | 54 ++++++ repo/devel/m4.xibuild | 22 --- repo/devel/m4/m4.xibuild | 22 +++ repo/devel/make.xibuild | 17 -- repo/devel/make/make.xibuild | 17 ++ repo/devel/meson.xibuild | 21 --- repo/devel/meson/meson.xibuild | 21 +++ repo/devel/mpc.xibuild | 24 --- repo/devel/mpc/mpc.xibuild | 24 +++ repo/devel/nasm.xibuild | 17 -- repo/devel/nasm/nasm.xibuild | 17 ++ repo/devel/ninja.xibuild | 24 --- repo/devel/ninja/ninja.xibuild | 24 +++ repo/devel/patch.xibuild | 17 -- repo/devel/patch/patch.xibuild | 17 ++ repo/devel/pkg-config.xibuild | 24 --- repo/devel/pkg-config/pkg-config.xibuild | 24 +++ repo/devel/rustc.xibuild | 94 ---------- repo/devel/rustc/files/check-rustc | 109 ++++++++++++ ...-Prefer-libgcc_eh-over-libunwind-for-musl.patch | 24 +++ .../0007-do-not-install-libunwind-source.patch | 19 ++ .../patches/alpine-move-py-scripts-to-share.patch | 23 +++ repo/devel/rustc/patches/alpine-target.patch | 191 ++++++++++++++++++++ .../rustc/patches/install-template-shebang.patch | 10 ++ .../rustc/patches/link-musl-dynamically.patch | 17 ++ .../rustc/patches/musl-fix-linux_musl_base.patch | 23 +++ repo/devel/rustc/patches/need-rpath.patch | 62 +++++++ repo/devel/rustc/patches/need-ssp_nonshared.patch | 13 ++ repo/devel/rustc/rustc.xibuild | 94 ++++++++++ repo/devel/scdoc.xibuild | 16 -- repo/devel/scdoc/scdoc.xibuild | 16 ++ repo/devel/sgml-common.xibuild | 30 ---- repo/devel/sgml-common/sgml-common.xibuild | 30 ++++ repo/devel/strace.xibuild | 33 ---- repo/devel/strace/disable-fortify.patch | 39 +++++ repo/devel/strace/nlattr-fix.patch | 21 +++ repo/devel/strace/strace.xibuild | 33 ++++ repo/devel/swig.xibuild | 20 --- repo/devel/swig/swig.xibuild | 20 +++ repo/devel/texinfo.xibuild | 24 --- repo/devel/texinfo/texinfo.xibuild | 24 +++ repo/devel/uthash.xibuild | 15 -- repo/devel/uthash/uthash.xibuild | 15 ++ repo/devel/vala.xibuild | 23 --- repo/devel/vala/vala.xibuild | 23 +++ repo/devel/waf.xibuild | 14 -- repo/devel/waf/waf.xibuild | 14 ++ repo/devel/xmlto.xibuild | 18 -- repo/devel/xmlto/xmlto.xibuild | 18 ++ repo/devel/xorg-cf-files.xibuild | 23 --- repo/devel/xorg-cf-files/xorg-cf-files.xibuild | 23 +++ 137 files changed, 3043 insertions(+), 1956 deletions(-) delete mode 100644 repo/devel/asciidoc.xibuild create mode 100644 repo/devel/asciidoc/asciidoc.xibuild delete mode 100644 repo/devel/autoconf-archive.xibuild create mode 100644 repo/devel/autoconf-archive/autoconf-archive.xibuild delete mode 100644 repo/devel/autoconf.xibuild create mode 100644 repo/devel/autoconf/autoconf.xibuild delete mode 100644 repo/devel/autoconf2-13.xibuild create mode 100644 repo/devel/autoconf2-13/autoconf2-13.xibuild delete mode 100644 repo/devel/automake.xibuild create mode 100644 repo/devel/automake/automake.xibuild delete mode 100644 repo/devel/bc.xibuild create mode 100644 repo/devel/bc/bc.xibuild delete mode 100644 repo/devel/bison.xibuild create mode 100644 repo/devel/bison/bison.xibuild delete mode 100644 repo/devel/boost.xibuild create mode 100644 repo/devel/boost/0001-revert-cease-dependence-on-range.patch create mode 100644 repo/devel/boost/boost-1.57.0-python-abi_letters.patch create mode 100644 repo/devel/boost/boost-1.57.0-python-libpython_dep.patch create mode 100644 repo/devel/boost/boost.xibuild create mode 100644 repo/devel/boost/python-3.10.patch delete mode 100644 repo/devel/cbindgen.xibuild create mode 100644 repo/devel/cbindgen/cbindgen.xibuild delete mode 100644 repo/devel/check.xibuild create mode 100644 repo/devel/check/check.xibuild delete mode 100644 repo/devel/clang.xibuild create mode 100644 repo/devel/clang/clang.xibuild create mode 100644 repo/devel/clang/patches/10-add-musl-triples.patch create mode 100644 repo/devel/clang/patches/30-Enable-stack-protector-by-default-for-Alpine-Linux.patch delete mode 100644 repo/devel/cmake-extra.xibuild create mode 100644 repo/devel/cmake-extra/cmake-extra.xibuild delete mode 100644 repo/devel/cmake-modules.xibuild create mode 100644 repo/devel/cmake-modules/cmake-modules.xibuild delete mode 100644 repo/devel/cmake.xibuild create mode 100644 repo/devel/cmake/cmake.xibuild delete mode 100644 repo/devel/compiler-rt.xibuild create mode 100644 repo/devel/compiler-rt/compiler-rt.xibuild create mode 100644 repo/devel/compiler-rt/link-execinfo.patch delete mode 100644 repo/devel/dejagnu.xibuild create mode 100644 repo/devel/dejagnu/dejagnu.xibuild delete mode 100644 repo/devel/distcc.xibuild create mode 100644 repo/devel/distcc/dcc_gcc_rewrite_fqn-avoid-heap-corruption.patch create mode 100644 repo/devel/distcc/distcc-hardened.patch create mode 100644 repo/devel/distcc/distcc.xibuild create mode 100644 repo/devel/distcc/gcc-10.patch delete mode 100644 repo/devel/docbook-dtd.xibuild create mode 100644 repo/devel/docbook-dtd/docbook-dtd.xibuild delete mode 100644 repo/devel/docbook-xml.xibuild create mode 100644 repo/devel/docbook-xml/docbook-xml.xibuild delete mode 100644 repo/devel/docbook-xsl.xibuild create mode 100644 repo/devel/docbook-xsl/docbook-xsl.xibuild delete mode 100644 repo/devel/docbook4-xml.xibuild create mode 100644 repo/devel/docbook4-xml/docbook4-xml.xibuild delete mode 100644 repo/devel/expect.xibuild create mode 100644 repo/devel/expect/expect.xibuild delete mode 100644 repo/devel/flex.xibuild create mode 100644 repo/devel/flex/flex.xibuild delete mode 100644 repo/devel/gcc.xibuild create mode 100644 repo/devel/gcc/gcc.xibuild delete mode 100644 repo/devel/gdb.xibuild create mode 100644 repo/devel/gdb/gdb.xibuild delete mode 100644 repo/devel/git.xibuild create mode 100644 repo/devel/git/git.xibuild delete mode 100644 repo/devel/go.xibuild create mode 100644 repo/devel/go/go.xibuild delete mode 100644 repo/devel/gtk-doc.xibuild create mode 100644 repo/devel/gtk-doc/gtk-doc.xibuild delete mode 100644 repo/devel/help2man.xibuild create mode 100644 repo/devel/help2man/help2man.xibuild delete mode 100644 repo/devel/icecream.xibuild create mode 100644 repo/devel/icecream/icecream.xibuild delete mode 100644 repo/devel/imake.xibuild create mode 100644 repo/devel/imake/imake.xibuild delete mode 100644 repo/devel/itstool.xibuild create mode 100644 repo/devel/itstool/itstool.xibuild delete mode 100644 repo/devel/libexecinfo.xibuild create mode 100644 repo/devel/libexecinfo/10-execinfo.patch create mode 100644 repo/devel/libexecinfo/20-define-gnu-source.patch create mode 100644 repo/devel/libexecinfo/30-linux-makefile.patch create mode 100644 repo/devel/libexecinfo/libexecinfo.xibuild delete mode 100644 repo/devel/lld.xibuild create mode 100644 repo/devel/lld/lld.xibuild delete mode 100644 repo/devel/llvm-libunwind.xibuild create mode 100644 repo/devel/llvm-libunwind/libcxx-musl.patch create mode 100644 repo/devel/llvm-libunwind/libunwind-link-libssp.patch create mode 100644 repo/devel/llvm-libunwind/llvm-libunwind.xibuild delete mode 100644 repo/devel/llvm.xibuild create mode 100644 repo/devel/llvm/llvm.xibuild delete mode 100644 repo/devel/m4.xibuild create mode 100644 repo/devel/m4/m4.xibuild delete mode 100644 repo/devel/make.xibuild create mode 100644 repo/devel/make/make.xibuild delete mode 100644 repo/devel/meson.xibuild create mode 100644 repo/devel/meson/meson.xibuild delete mode 100644 repo/devel/mpc.xibuild create mode 100644 repo/devel/mpc/mpc.xibuild delete mode 100644 repo/devel/nasm.xibuild create mode 100644 repo/devel/nasm/nasm.xibuild delete mode 100644 repo/devel/ninja.xibuild create mode 100644 repo/devel/ninja/ninja.xibuild delete mode 100644 repo/devel/patch.xibuild create mode 100644 repo/devel/patch/patch.xibuild delete mode 100644 repo/devel/pkg-config.xibuild create mode 100644 repo/devel/pkg-config/pkg-config.xibuild delete mode 100644 repo/devel/rustc.xibuild create mode 100644 repo/devel/rustc/files/check-rustc create mode 100644 repo/devel/rustc/patches/0006-Prefer-libgcc_eh-over-libunwind-for-musl.patch create mode 100644 repo/devel/rustc/patches/0007-do-not-install-libunwind-source.patch create mode 100644 repo/devel/rustc/patches/alpine-move-py-scripts-to-share.patch create mode 100644 repo/devel/rustc/patches/alpine-target.patch create mode 100644 repo/devel/rustc/patches/install-template-shebang.patch create mode 100644 repo/devel/rustc/patches/link-musl-dynamically.patch create mode 100644 repo/devel/rustc/patches/musl-fix-linux_musl_base.patch create mode 100644 repo/devel/rustc/patches/need-rpath.patch create mode 100644 repo/devel/rustc/patches/need-ssp_nonshared.patch create mode 100644 repo/devel/rustc/rustc.xibuild delete mode 100644 repo/devel/scdoc.xibuild create mode 100644 repo/devel/scdoc/scdoc.xibuild delete mode 100644 repo/devel/sgml-common.xibuild create mode 100644 repo/devel/sgml-common/sgml-common.xibuild delete mode 100644 repo/devel/strace.xibuild create mode 100644 repo/devel/strace/disable-fortify.patch create mode 100644 repo/devel/strace/nlattr-fix.patch create mode 100644 repo/devel/strace/strace.xibuild delete mode 100644 repo/devel/swig.xibuild create mode 100644 repo/devel/swig/swig.xibuild delete mode 100644 repo/devel/texinfo.xibuild create mode 100644 repo/devel/texinfo/texinfo.xibuild delete mode 100644 repo/devel/uthash.xibuild create mode 100644 repo/devel/uthash/uthash.xibuild delete mode 100644 repo/devel/vala.xibuild create mode 100644 repo/devel/vala/vala.xibuild delete mode 100644 repo/devel/waf.xibuild create mode 100644 repo/devel/waf/waf.xibuild delete mode 100644 repo/devel/xmlto.xibuild create mode 100644 repo/devel/xmlto/xmlto.xibuild delete mode 100644 repo/devel/xorg-cf-files.xibuild create mode 100644 repo/devel/xorg-cf-files/xorg-cf-files.xibuild (limited to 'repo/devel') diff --git a/repo/devel/asciidoc.xibuild b/repo/devel/asciidoc.xibuild deleted file mode 100644 index 34202d0..0000000 --- a/repo/devel/asciidoc.xibuild +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh - -MAKEDEPS="python " -DEPS="python libxslt docbook-xsl" - -PKG_VER=10.1.1 -SOURCE=https://github.com/asciidoc-py/asciidoc-py/releases/download/$PKG_VER/asciidoc-$PKG_VER.tar.gz -DESC="Text document format for short documents, articles, books and UNIX man pages" - -package () { - pip install -t $PKG_DEST/usr/lib/python3.10/site-packages/ asciidoc - mkdir -p $PKG_DEST/usr/bin - ln -s /usr/lib/python3.10/site-packages/bin/asciidoc $PKG_DEST/usr/bin/asciidoc - ln -s /usr/lib/python3.10/site-packages/bin/a2x $PKG_DEST/usr/bin/a2x -} diff --git a/repo/devel/asciidoc/asciidoc.xibuild b/repo/devel/asciidoc/asciidoc.xibuild new file mode 100644 index 0000000..34202d0 --- /dev/null +++ b/repo/devel/asciidoc/asciidoc.xibuild @@ -0,0 +1,15 @@ +#!/bin/sh + +MAKEDEPS="python " +DEPS="python libxslt docbook-xsl" + +PKG_VER=10.1.1 +SOURCE=https://github.com/asciidoc-py/asciidoc-py/releases/download/$PKG_VER/asciidoc-$PKG_VER.tar.gz +DESC="Text document format for short documents, articles, books and UNIX man pages" + +package () { + pip install -t $PKG_DEST/usr/lib/python3.10/site-packages/ asciidoc + mkdir -p $PKG_DEST/usr/bin + ln -s /usr/lib/python3.10/site-packages/bin/asciidoc $PKG_DEST/usr/bin/asciidoc + ln -s /usr/lib/python3.10/site-packages/bin/a2x $PKG_DEST/usr/bin/a2x +} diff --git a/repo/devel/autoconf-archive.xibuild b/repo/devel/autoconf-archive.xibuild deleted file mode 100644 index ff50482..0000000 --- a/repo/devel/autoconf-archive.xibuild +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make" -DEPS="gawk grep m4 diffutils perl sh gettext" - -PKG_VER=2022.02.11 -SOURCE=https://ftpmirror.gnu.org/autoconf-archive/autoconf-archive-$PKG_VER.tar.xz -DESC="A collection of freely re-usable autoconf macros" - - -build () { - ./configure --prefix=/usr - make -} - -package () { - make DESTDIR=$PKG_DEST install - - # force these macros to use gnu grep rather than built in grep - sed -i "s/grep/ggrep/g" $PKG_DEST/usr/share/aclocal/*.m4 -} diff --git a/repo/devel/autoconf-archive/autoconf-archive.xibuild b/repo/devel/autoconf-archive/autoconf-archive.xibuild new file mode 100644 index 0000000..ff50482 --- /dev/null +++ b/repo/devel/autoconf-archive/autoconf-archive.xibuild @@ -0,0 +1,21 @@ +#!/bin/sh + +MAKEDEPS="make" +DEPS="gawk grep m4 diffutils perl sh gettext" + +PKG_VER=2022.02.11 +SOURCE=https://ftpmirror.gnu.org/autoconf-archive/autoconf-archive-$PKG_VER.tar.xz +DESC="A collection of freely re-usable autoconf macros" + + +build () { + ./configure --prefix=/usr + make +} + +package () { + make DESTDIR=$PKG_DEST install + + # force these macros to use gnu grep rather than built in grep + sed -i "s/grep/ggrep/g" $PKG_DEST/usr/share/aclocal/*.m4 +} diff --git a/repo/devel/autoconf.xibuild b/repo/devel/autoconf.xibuild deleted file mode 100644 index 8068345..0000000 --- a/repo/devel/autoconf.xibuild +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make" -DEPS="gawk m4 diffutils perl sh gettext" - -PKG_VER=2.71 -SOURCE=https://ftp.gnu.org/gnu/autoconf/autoconf-$PKG_VER.tar.xz -DESC="GNU programs for producing shell scripts that can automatically configure source code" - -build () { - ./configure --prefix=/usr --sysconfdir=/etc - make -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/autoconf/autoconf.xibuild b/repo/devel/autoconf/autoconf.xibuild new file mode 100644 index 0000000..8068345 --- /dev/null +++ b/repo/devel/autoconf/autoconf.xibuild @@ -0,0 +1,17 @@ +#!/bin/sh + +MAKEDEPS="make" +DEPS="gawk m4 diffutils perl sh gettext" + +PKG_VER=2.71 +SOURCE=https://ftp.gnu.org/gnu/autoconf/autoconf-$PKG_VER.tar.xz +DESC="GNU programs for producing shell scripts that can automatically configure source code" + +build () { + ./configure --prefix=/usr --sysconfdir=/etc + make +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/autoconf2-13.xibuild b/repo/devel/autoconf2-13.xibuild deleted file mode 100644 index abddc17..0000000 --- a/repo/devel/autoconf2-13.xibuild +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make patch" -DEPS="perl" - -PKG_VER=2.13 -SOURCE=https://ftp.gnu.org/gnu/autoconf/autoconf-$PKG_VER.tar.gz -ADDITIONAL=" - https://www.linuxfromscratch.org/patches/blfs/svn/autoconf-$PKG_VER-consolidated_fixes-1.patch - " - -DESC="GNU programs for producing shell scripts that can automatically configure source code, legacy $PKG_VER version" - -prepare() { - patch -Np1 -i autoconf-2.13-consolidated_fixes-1.patch && - mv autoconf.texi autoconf213.texi && - rm autoconf.info - -} - -build () { - ./configure --prefix=/usr --program-suffix=$PKG_VER && - make -} - -package () { - make DESTDIR=$PKG_DEST install - install -m644 autoconf213.info $PKG_DEST/usr/share/info && - install-info --info-dir=$PKG_DEST/usr/share/info autoconf213.info -} diff --git a/repo/devel/autoconf2-13/autoconf2-13.xibuild b/repo/devel/autoconf2-13/autoconf2-13.xibuild new file mode 100644 index 0000000..abddc17 --- /dev/null +++ b/repo/devel/autoconf2-13/autoconf2-13.xibuild @@ -0,0 +1,30 @@ +#!/bin/sh + +MAKEDEPS="make patch" +DEPS="perl" + +PKG_VER=2.13 +SOURCE=https://ftp.gnu.org/gnu/autoconf/autoconf-$PKG_VER.tar.gz +ADDITIONAL=" + https://www.linuxfromscratch.org/patches/blfs/svn/autoconf-$PKG_VER-consolidated_fixes-1.patch + " + +DESC="GNU programs for producing shell scripts that can automatically configure source code, legacy $PKG_VER version" + +prepare() { + patch -Np1 -i autoconf-2.13-consolidated_fixes-1.patch && + mv autoconf.texi autoconf213.texi && + rm autoconf.info + +} + +build () { + ./configure --prefix=/usr --program-suffix=$PKG_VER && + make +} + +package () { + make DESTDIR=$PKG_DEST install + install -m644 autoconf213.info $PKG_DEST/usr/share/info && + install-info --info-dir=$PKG_DEST/usr/share/info autoconf213.info +} diff --git a/repo/devel/automake.xibuild b/repo/devel/automake.xibuild deleted file mode 100644 index 8b8951f..0000000 --- a/repo/devel/automake.xibuild +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make autoconf" -DEPS="perl bash" - -PKG_VER=1.16.5 -SOURCE=https://ftp.gnu.org/gnu/automake/automake-$PKG_VER.tar.xz -DESC="A GNU tool for automatically creating Makefiles" - -build () { - ./configure --prefix=/usr -docdir=/usr/share/doc/automake-$PKG_VER - make -} - -#check () { - #make -j4 check || true -#} - -package () { - make DESTDIR=$PKG_DEST install - - # backwards compatibility? - ln -s /usr/bin/aclocal $PKG_DEST/usr/bin/aclocal-1.15 -} diff --git a/repo/devel/automake/automake.xibuild b/repo/devel/automake/automake.xibuild new file mode 100644 index 0000000..8b8951f --- /dev/null +++ b/repo/devel/automake/automake.xibuild @@ -0,0 +1,24 @@ +#!/bin/sh + +MAKEDEPS="make autoconf" +DEPS="perl bash" + +PKG_VER=1.16.5 +SOURCE=https://ftp.gnu.org/gnu/automake/automake-$PKG_VER.tar.xz +DESC="A GNU tool for automatically creating Makefiles" + +build () { + ./configure --prefix=/usr -docdir=/usr/share/doc/automake-$PKG_VER + make +} + +#check () { + #make -j4 check || true +#} + +package () { + make DESTDIR=$PKG_DEST install + + # backwards compatibility? + ln -s /usr/bin/aclocal $PKG_DEST/usr/bin/aclocal-1.15 +} diff --git a/repo/devel/bc.xibuild b/repo/devel/bc.xibuild deleted file mode 100644 index ffe43a5..0000000 --- a/repo/devel/bc.xibuild +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make " -DEPS="readline" - -PKG_VER=5.2.1 -SOURCE=https://github.com/gavinhoward/bc/releases/download/$PKG_VER/bc-$PKG_VER.tar.xz -DESC="An arbitrary precision numeric processing language" - -build () { - CC=gcc ./configure --prefix=/usr -G -O3 - make -} - -check () { - make test -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/bc/bc.xibuild b/repo/devel/bc/bc.xibuild new file mode 100644 index 0000000..ffe43a5 --- /dev/null +++ b/repo/devel/bc/bc.xibuild @@ -0,0 +1,21 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="readline" + +PKG_VER=5.2.1 +SOURCE=https://github.com/gavinhoward/bc/releases/download/$PKG_VER/bc-$PKG_VER.tar.xz +DESC="An arbitrary precision numeric processing language" + +build () { + CC=gcc ./configure --prefix=/usr -G -O3 + make +} + +check () { + make test +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/bison.xibuild b/repo/devel/bison.xibuild deleted file mode 100644 index 2f96141..0000000 --- a/repo/devel/bison.xibuild +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make " -DEPS="musl m4 sh" - -PKG_VER=3.8.1 -SOURCE=https://ftp.gnu.org/gnu/bison/bison-$PKG_VER.tar.xz -DESC="The GNU general-purpose parser generator" - -build () { - ./configure --prefix=/usr --docdir=/usr/share/doc/bison-$PKG_VER - make -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/bison/bison.xibuild b/repo/devel/bison/bison.xibuild new file mode 100644 index 0000000..2f96141 --- /dev/null +++ b/repo/devel/bison/bison.xibuild @@ -0,0 +1,17 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="musl m4 sh" + +PKG_VER=3.8.1 +SOURCE=https://ftp.gnu.org/gnu/bison/bison-$PKG_VER.tar.xz +DESC="The GNU general-purpose parser generator" + +build () { + ./configure --prefix=/usr --docdir=/usr/share/doc/bison-$PKG_VER + make +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/boost.xibuild b/repo/devel/boost.xibuild deleted file mode 100644 index b97cab7..0000000 --- a/repo/devel/boost.xibuild +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh - -NAME="boost" -DESC="Free peer-reviewed portable C++ source libraries" - -MAKEDEPS="make python which zlib icu" -DEPS="musl gcc bzip2 zlib mpi python icu" - -PKG_VER=1.79.0 -SOURCE="https://boostorg.jfrog.io/artifactory/main/release/$PKG_VER/source/boost_$(echo $PKG_VER | sed "s/\./_/g").tar.bz2" -ADDITIONAL="python-3.10.patch 0001-revert-cease-dependence-on-range.patch boost-1.57.0-python-libpython_dep.patch boost-1.57.0-python-abi_letters.patch " - -prepare () { - ./bootstrap.sh --prefix=/usr --with-python=python3 -} - -build () { - ./b2 --debug-building --no-cmake-config --toolset=gcc runtime-link=shared link=shared,static -} - -package () { - ./b2 install --prefix=$PKG_DEST/usr -} diff --git a/repo/devel/boost/0001-revert-cease-dependence-on-range.patch b/repo/devel/boost/0001-revert-cease-dependence-on-range.patch new file mode 100644 index 0000000..77b8178 --- /dev/null +++ b/repo/devel/boost/0001-revert-cease-dependence-on-range.patch @@ -0,0 +1 @@ +Too Many Requests \ No newline at end of file diff --git a/repo/devel/boost/boost-1.57.0-python-abi_letters.patch b/repo/devel/boost/boost-1.57.0-python-abi_letters.patch new file mode 100644 index 0000000..7df3ee7 --- /dev/null +++ b/repo/devel/boost/boost-1.57.0-python-abi_letters.patch @@ -0,0 +1,62 @@ +--- boost_1_57_0/tools/build/src/tools/python.jam 2013-05-21 06:14:18.000000000 +0200 ++++ boost_1_55_0/tools/build/src/tools/python.jam 2014-05-29 19:09:12.115413877 +0200 +@@ -94,7 +94,7 @@ feature.feature pythonpath : : free opti + # using python : 2.3 : /usr/local/bin/python ; + # + rule init ( version ? : cmd-or-prefix ? : includes * : libraries ? +- : condition * : extension-suffix ? ) ++ : condition * : extension-suffix ? : abi-letters ? ) + { + project.push-current $(.project) ; + +@@ -107,7 +107,7 @@ rule init ( version ? : cmd-or-prefix ? + } + } + +- configure $(version) : $(cmd-or-prefix) : $(includes) : $(libraries) : $(condition) : $(extension-suffix) ; ++ configure $(version) : $(cmd-or-prefix) : $(includes) : $(libraries) : $(condition) : $(extension-suffix) : $(abi-letters) ; + + project.pop-current ; + } +@@ -653,7 +653,7 @@ local rule system-library-dependencies ( + + # Declare a target to represent Python's library. + # +-local rule declare-libpython-target ( version ? : requirements * ) ++local rule declare-libpython-target ( version ? : requirements * : abi-letters ? ) + { + # Compute the representation of Python version in the name of Python's + # library file. +@@ -677,13 +677,13 @@ local rule declare-libpython-target ( ve + } + + # Declare it. +- lib python.lib : : python$(lib-version) $(requirements) ; ++ lib python.lib : : python$(lib-version)$(abi-letters) $(requirements) ; + } + + + # Implementation of init. + local rule configure ( version ? : cmd-or-prefix ? : includes * : libraries ? : +- condition * : extension-suffix ? ) ++ condition * : extension-suffix ? : abi-letters ? ) + { + local prefix ; + local exec-prefix ; +@@ -699,6 +699,7 @@ local rule configure ( version ? : cmd-o + extension-suffix ?= _d ; + } + extension-suffix ?= "" ; ++ abi-letters ?= "" ; + + # Normalize and dissect any version number. + local major-minor ; +@@ -922,7 +923,7 @@ local rule configure ( version ? : cmd-o + } + else + { +- declare-libpython-target $(version) : $(target-requirements) ; ++ declare-libpython-target $(version) : $(target-requirements) : $(abi-letters) ; + + # This is an evil hack. On, Windows, when Python is embedded, nothing + # seems to set up sys.path to include Python's standard library diff --git a/repo/devel/boost/boost-1.57.0-python-libpython_dep.patch b/repo/devel/boost/boost-1.57.0-python-libpython_dep.patch new file mode 100644 index 0000000..57bfc26 --- /dev/null +++ b/repo/devel/boost/boost-1.57.0-python-libpython_dep.patch @@ -0,0 +1,13 @@ +Index: boost_1_57_0/tools/build/src/tools/python.jam +=================================================================== +--- boost_1_57_0/tools/build/src/tools/python.jam (revision 50406) ++++ boost_1_57_0/tools/build/src/tools/python.jam (working copy) +@@ -994,7 +994,7 @@ + else + { + alias python_for_extensions +- : ++ : python + : $(target-requirements) + : + : $(usage-requirements) diff --git a/repo/devel/boost/boost.xibuild b/repo/devel/boost/boost.xibuild new file mode 100644 index 0000000..b97cab7 --- /dev/null +++ b/repo/devel/boost/boost.xibuild @@ -0,0 +1,23 @@ +#!/bin/sh + +NAME="boost" +DESC="Free peer-reviewed portable C++ source libraries" + +MAKEDEPS="make python which zlib icu" +DEPS="musl gcc bzip2 zlib mpi python icu" + +PKG_VER=1.79.0 +SOURCE="https://boostorg.jfrog.io/artifactory/main/release/$PKG_VER/source/boost_$(echo $PKG_VER | sed "s/\./_/g").tar.bz2" +ADDITIONAL="python-3.10.patch 0001-revert-cease-dependence-on-range.patch boost-1.57.0-python-libpython_dep.patch boost-1.57.0-python-abi_letters.patch " + +prepare () { + ./bootstrap.sh --prefix=/usr --with-python=python3 +} + +build () { + ./b2 --debug-building --no-cmake-config --toolset=gcc runtime-link=shared link=shared,static +} + +package () { + ./b2 install --prefix=$PKG_DEST/usr +} diff --git a/repo/devel/boost/python-3.10.patch b/repo/devel/boost/python-3.10.patch new file mode 100644 index 0000000..2e1d5e3 --- /dev/null +++ b/repo/devel/boost/python-3.10.patch @@ -0,0 +1,49 @@ +From e193f080c7d209516ac9b712fa0c50bb08026fa2 Mon Sep 17 00:00:00 2001 +From: Martin Jansa +Date: Tue, 19 Oct 2021 12:24:31 +0000 +Subject: [PATCH] BoostConfig.cmake: allow searching for python310 + +* accept double digits in Python3_VERSION_MINOR + +* if someone is using e.g.: + find_package(Python3 REQUIRED) + find_package(Boost REQUIRED python${Python3_VERSION_MAJOR}${Python3_VERSION_MINOR}) + + with python-3.10 then it currently fails with: + + -- Found PythonLibs: /usr/lib/libpython3.10.so (found version "3.10.0") + -- Found Python3: -native/usr/bin/python3-native/python3 (found version "3.10.0") found components: Interpreter + CMake Error at /usr/lib/cmake/Boost-1.77.0/BoostConfig.cmake:141 (find_package): + Could not find a package configuration file provided by "boost_python310" + (requested version 1.77.0) with any of the following names: + + boost_python310Config.cmake + boost_python310-config.cmake + + Add the installation prefix of "boost_python310" to CMAKE_PREFIX_PATH or + set "boost_python310_DIR" to a directory containing one of the above files. + If "boost_python310" provides a separate development package or SDK, be + sure it has been installed. + Call Stack (most recent call first): + /usr/lib/cmake/Boost-1.77.0/BoostConfig.cmake:258 (boost_find_component) + /usr/share/cmake-3.21/Modules/FindBoost.cmake:594 (find_package) + CMakeLists.txt:18 (find_package) + +Signed-off-by: Martin Jansa +--- + BoostConfig.cmake | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/BoostConfig.cmake b/BoostConfig.cmake +index fd17821..5dffa58 100644 +--- a/tools/boost_install/BoostConfig.cmake ++++ b/tools/boost_install/BoostConfig.cmake +@@ -113,7 +113,7 @@ macro(boost_find_component comp required quiet) + set(_BOOST_REQUIRED REQUIRED) + endif() + +- if("${comp}" MATCHES "^(python|numpy|mpi_python)([1-9])([0-9])$") ++ if("${comp}" MATCHES "^(python|numpy|mpi_python)([1-9])([0-9][0-9]?)$") + + # handle pythonXY and numpyXY versioned components for compatibility + diff --git a/repo/devel/cbindgen.xibuild b/repo/devel/cbindgen.xibuild deleted file mode 100644 index 8bebc3a..0000000 --- a/repo/devel/cbindgen.xibuild +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh - -NAME="cbindgen" -DESC="Tool to generate C bindings from Rust code" - -MAKEDEPS="" -DEPS="gcc " - -PKG_VER=0.20.0 -SOURCE="https://crates.io/api/v1/crates/cbindgen/$PKG_VER/download" - -build () { - cargo build --release --locked --verbose -} - -package () { - install -Dm0755 target/release/cbindgen "$PKG_DEST/usr/bin/cbindgen" -} diff --git a/repo/devel/cbindgen/cbindgen.xibuild b/repo/devel/cbindgen/cbindgen.xibuild new file mode 100644 index 0000000..8bebc3a --- /dev/null +++ b/repo/devel/cbindgen/cbindgen.xibuild @@ -0,0 +1,18 @@ +#!/bin/sh + +NAME="cbindgen" +DESC="Tool to generate C bindings from Rust code" + +MAKEDEPS="" +DEPS="gcc " + +PKG_VER=0.20.0 +SOURCE="https://crates.io/api/v1/crates/cbindgen/$PKG_VER/download" + +build () { + cargo build --release --locked --verbose +} + +package () { + install -Dm0755 target/release/cbindgen "$PKG_DEST/usr/bin/cbindgen" +} diff --git a/repo/devel/check.xibuild b/repo/devel/check.xibuild deleted file mode 100644 index 192e219..0000000 --- a/repo/devel/check.xibuild +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make" -DEPS="gawk" - -PKG_VER=0.15.2 -SOURCE=https://github.com/libcheck/check/releases/download/$PKG_VER/check-$PKG_VER.tar.gz -DESC="A unit testing framework for C" - -build () { - ./configure --prefix=/usr --disable-static - make -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/check/check.xibuild b/repo/devel/check/check.xibuild new file mode 100644 index 0000000..192e219 --- /dev/null +++ b/repo/devel/check/check.xibuild @@ -0,0 +1,17 @@ +#!/bin/sh + +MAKEDEPS="make" +DEPS="gawk" + +PKG_VER=0.15.2 +SOURCE=https://github.com/libcheck/check/releases/download/$PKG_VER/check-$PKG_VER.tar.gz +DESC="A unit testing framework for C" + +build () { + ./configure --prefix=/usr --disable-static + make +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/clang.xibuild b/repo/devel/clang.xibuild deleted file mode 100644 index 3b93ba3..0000000 --- a/repo/devel/clang.xibuild +++ /dev/null @@ -1,57 +0,0 @@ -#!/bin/sh - -MAKEDEPS="cmake llvm libxml2 ninja python python-markupsafe python-pygments" -DEPS="curl gcc libssh2 openssl" - -PKG_VER=13.0.0 -SOURCE=https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/clang-$PKG_VER.src.tar.xz -DESC="Systems programming language focused on safety, speed and concurrency" - -ADDITIONAL=" - patches/30-Enable-stack-protector-by-default-for-Alpine-Linux.patch - patches/10-add-musl-triples.patch -" - -prepare () { - apply_patches - - # link in /usr/inlcude/llvm to include - ln -s /usr/include/llvm include/llvm - # (there should be a better way to do this, since tblgen does look in /include rather than /usr/include) - -} - -build () { - mkdir build - cd build - - python_version=$(python3 -V | sed 's/.*\([0-9]\{1,\}\.[0-9]\{1,\}\)\..*/\1/') - - cmake .. -G Ninja -Wno-dev \ - -DCMAKE_BUILD_TYPE=Release \ - -DCMAKE_C_FLAGS_RELEASE_INIT="$CFLAGS -O2" \ - -DCMAKE_CXX_FLAGS_RELEASE_INIT="$CXXFLAGS" \ - -DCMAKE_EXE_LINKER_FLAGS_RELEASE_INIT="$LDFLAGS -Wl,-z,stack-size=2097152" \ - -DCMAKE_INSTALL_PREFIX=/usr \ - -DCMAKE_VERBOSE_MAKEFILE=OFF \ - -DCLANG_VENDOR=XiLinux \ - -DLLVM_EXTERNAL_LIT=/usr/bin/lit \ - -DCLANG_BUILD_EXAMPLES=OFF \ - -DCLANG_INCLUDE_DOCS=ON \ - -DCLANG_PYTHON_BINDINGS_VERSIONS="$python_version" \ - -DLLVM_BUILD_DOCS=ON \ - -DLLVM_ENABLE_SPHINX=ON \ - -DSPHINX_WARNINGS_AS_ERRORS=OFF \ - -DCLANG_INCLUDE_TESTS=ON \ - -DCLANG_PLUGIN_SUPPORT=ON \ - -DLIBCLANG_BUILD_STATIC=ON \ - -DLLVM_ENABLE_EH=ON \ - -DLLVM_ENABLE_RTTI=ON - - ninja clang-tblgen - ninja -} - -package () { - DESTDIR=$PKG_DEST ninja install -} diff --git a/repo/devel/clang/clang.xibuild b/repo/devel/clang/clang.xibuild new file mode 100644 index 0000000..3b93ba3 --- /dev/null +++ b/repo/devel/clang/clang.xibuild @@ -0,0 +1,57 @@ +#!/bin/sh + +MAKEDEPS="cmake llvm libxml2 ninja python python-markupsafe python-pygments" +DEPS="curl gcc libssh2 openssl" + +PKG_VER=13.0.0 +SOURCE=https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/clang-$PKG_VER.src.tar.xz +DESC="Systems programming language focused on safety, speed and concurrency" + +ADDITIONAL=" + patches/30-Enable-stack-protector-by-default-for-Alpine-Linux.patch + patches/10-add-musl-triples.patch +" + +prepare () { + apply_patches + + # link in /usr/inlcude/llvm to include + ln -s /usr/include/llvm include/llvm + # (there should be a better way to do this, since tblgen does look in /include rather than /usr/include) + +} + +build () { + mkdir build + cd build + + python_version=$(python3 -V | sed 's/.*\([0-9]\{1,\}\.[0-9]\{1,\}\)\..*/\1/') + + cmake .. -G Ninja -Wno-dev \ + -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_C_FLAGS_RELEASE_INIT="$CFLAGS -O2" \ + -DCMAKE_CXX_FLAGS_RELEASE_INIT="$CXXFLAGS" \ + -DCMAKE_EXE_LINKER_FLAGS_RELEASE_INIT="$LDFLAGS -Wl,-z,stack-size=2097152" \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DCMAKE_VERBOSE_MAKEFILE=OFF \ + -DCLANG_VENDOR=XiLinux \ + -DLLVM_EXTERNAL_LIT=/usr/bin/lit \ + -DCLANG_BUILD_EXAMPLES=OFF \ + -DCLANG_INCLUDE_DOCS=ON \ + -DCLANG_PYTHON_BINDINGS_VERSIONS="$python_version" \ + -DLLVM_BUILD_DOCS=ON \ + -DLLVM_ENABLE_SPHINX=ON \ + -DSPHINX_WARNINGS_AS_ERRORS=OFF \ + -DCLANG_INCLUDE_TESTS=ON \ + -DCLANG_PLUGIN_SUPPORT=ON \ + -DLIBCLANG_BUILD_STATIC=ON \ + -DLLVM_ENABLE_EH=ON \ + -DLLVM_ENABLE_RTTI=ON + + ninja clang-tblgen + ninja +} + +package () { + DESTDIR=$PKG_DEST ninja install +} diff --git a/repo/devel/clang/patches/10-add-musl-triples.patch b/repo/devel/clang/patches/10-add-musl-triples.patch new file mode 100644 index 0000000..b11ca84 --- /dev/null +++ b/repo/devel/clang/patches/10-add-musl-triples.patch @@ -0,0 +1,35 @@ +--- a/lib/Driver/ToolChains/Gnu.cpp ++++ b/lib/Driver/ToolChains/Gnu.cpp +@@ -2077,6 +2077,7 @@ + static const char *const AArch64LibDirs[] = {"/lib64", "/lib"}; + static const char *const AArch64Triples[] = { + "aarch64-none-linux-gnu", "aarch64-linux-gnu", "aarch64-redhat-linux", ++ "aarch64-linux-musl", + "aarch64-suse-linux", "aarch64-linux-android"}; + static const char *const AArch64beLibDirs[] = {"/lib"}; + static const char *const AArch64beTriples[] = {"aarch64_be-none-linux-gnu", +@@ -2086,6 +2087,8 @@ + static const char *const ARMTriples[] = {"arm-linux-gnueabi", + "arm-linux-androideabi"}; + static const char *const ARMHFTriples[] = {"arm-linux-gnueabihf", ++ "arm-linux-musleabihf", ++ "armv7l-linux-musleabihf", + "armv7hl-redhat-linux-gnueabi", + "armv6hl-suse-linux-gnueabi", + "armv7hl-suse-linux-gnueabi"}; +@@ -2105,6 +2108,7 @@ + "x86_64-redhat-linux", "x86_64-suse-linux", + "x86_64-manbo-linux-gnu", "x86_64-linux-gnu", + "x86_64-slackware-linux", "x86_64-unknown-linux", ++ "x86_64-linux-musl", + "x86_64-amazon-linux", "x86_64-linux-android"}; + static const char *const X32Triples[] = {"x86_64-linux-gnux32", + "x86_64-pc-linux-gnux32"}; +@@ -2116,6 +2120,7 @@ + "i686-redhat-linux", "i386-redhat-linux", + "i586-suse-linux", "i686-montavista-linux", + "i686-linux-android", "i686-gnu", ++ "i686-linux-musl", + }; + + static const char *const M68kLibDirs[] = {"/lib"}; diff --git a/repo/devel/clang/patches/30-Enable-stack-protector-by-default-for-Alpine-Linux.patch b/repo/devel/clang/patches/30-Enable-stack-protector-by-default-for-Alpine-Linux.patch new file mode 100644 index 0000000..f2895ce --- /dev/null +++ b/repo/devel/clang/patches/30-Enable-stack-protector-by-default-for-Alpine-Linux.patch @@ -0,0 +1,81 @@ +Based on original patchset from Jakub Jirutka +Updated by Eric Molitor +Updated by Natanael Copa +Updated by omni + +--- a/lib/Driver/ToolChains/Linux.h ++++ b/lib/Driver/ToolChains/Linux.h +@@ -11,6 +11,7 @@ + + #include "Gnu.h" + #include "clang/Driver/ToolChain.h" ++#include "clang/Basic/LangOptions.h" + + namespace clang { + namespace driver { +@@ -38,6 +39,18 @@ + CXXStdlibType GetDefaultCXXStdlibType() const override; + bool isPIEDefault() const override; + bool isNoExecStackDefault() const override; ++ ++ LangOptions::StackProtectorMode ++ GetDefaultStackProtectorLevel(bool KernelOrKext) const override { ++ StringRef VendorName = Linux::getTriple().getVendorName(); ++ if (VendorName.compare("alpine") == 0) ++ return LangOptions::SSPStrong; ++ ++ return LangOptions::SSPOff; ++ } ++ ++ ++ + bool IsMathErrnoDefault() const override; + SanitizerMask getSupportedSanitizers() const override; + void addProfileRTLibs(const llvm::opt::ArgList &Args, +--- a/test/Driver/fsanitize.c ++++ b/test/Driver/fsanitize.c +@@ -667,18 +667,17 @@ + // RUN: %clang -fno-sanitize=safe-stack -### %s 2>&1 | FileCheck %s -check-prefix=NOSP + // NOSP-NOT: "-fsanitize=safe-stack" + +-// RUN: %clang -target x86_64-linux-gnu -fsanitize=safe-stack -### %s 2>&1 | FileCheck %s -check-prefix=NO-SP ++// RUN: %clang -target x86_64-linux-gnu -fsanitize=safe-stack -### %s 2>&1 | FileCheck %s -check-prefix=SP + // RUN: %clang -target x86_64-linux-gnu -fsanitize=address,safe-stack -### %s 2>&1 | FileCheck %s -check-prefix=SP-ASAN + // RUN: %clang -target x86_64-linux-gnu -fstack-protector -fsanitize=safe-stack -### %s 2>&1 | FileCheck %s -check-prefix=SP + // RUN: %clang -target x86_64-linux-gnu -fsanitize=safe-stack -fstack-protector-all -### %s 2>&1 | FileCheck %s -check-prefix=SP +-// RUN: %clang -target arm-linux-androideabi -fsanitize=safe-stack -### %s 2>&1 | FileCheck %s -check-prefix=NO-SP +-// RUN: %clang -target aarch64-linux-android -fsanitize=safe-stack -### %s 2>&1 | FileCheck %s -check-prefix=NO-SP ++// RUN: %clang -target arm-linux-androideabi -fsanitize=safe-stack -### %s 2>&1 | FileCheck %s -check-prefix=SP ++// RUN: %clang -target aarch64-linux-android -fsanitize=safe-stack -### %s 2>&1 | FileCheck %s -check-prefix=SP + // RUN: %clang -target i386-contiki-unknown -fsanitize=safe-stack -### %s 2>&1 | FileCheck %s -check-prefix=NO-SP + // NO-SP-NOT: stack-protector + // NO-SP: "-fsanitize=safe-stack" + // SP-ASAN: error: invalid argument '-fsanitize=safe-stack' not allowed with '-fsanitize=address' + // SP: "-fsanitize=safe-stack" +-// SP: -stack-protector + // NO-SP-NOT: stack-protector + + // RUN: %clang -target powerpc64-unknown-linux-gnu -fsanitize=memory %s -### 2>&1 | FileCheck %s -check-prefix=CHECK-SANM +--- a/test/Driver/stack-protector.c ++++ b/test/Driver/stack-protector.c +@@ -35,6 +35,20 @@ + + // Test default stack protector values for Darwin platforms + ++// RUN: %clang -target x86_64-alpine-linux-musl -### %s 2>&1 | FileCheck %s -check-prefix=ALPINE ++// ALPINE: "-stack-protector" "2" ++ ++// RUN: %clang -target x86_64-alpine-linux-musl -fstack-protector -### %s 2>&1 | FileCheck %s -check-prefix=ALPINE_SPS ++// ALPINE_SPS: "-stack-protector" "2" ++ ++// RUN: %clang -target x86_64-alpine-linux-musl -fstack-protector-all -### %s 2>&1 | FileCheck %s -check-prefix=ALPINE_ALL ++// ALPINE_ALL: "-stack-protector" "3" ++// ALPINE_ALL-NOT: "-stack-protector-buffer-size" ++ ++// RUN: %clang -target x86_64-alpine-linux-musl -fno-stack-protector -### %s 2>&1 | FileCheck %s -check-prefix=ALPINE_NOSSP ++// ALPINE_NOSSP-NOT: "-stack-protector" ++// ALPINE_NOSSP-NOT: "-stack-protector-buffer-size" ++ + // RUN: %clang -target armv7k-apple-watchos2.0 -### %s 2>&1 | FileCheck %s -check-prefix=SSP_WATCHOS + // RUN: %clang -ffreestanding -target armv7k-apple-watchos2.0 -### %s 2>&1 | FileCheck %s -check-prefix=SSP_WATCHOS + // SSP_WATCHOS: "-stack-protector" "1" diff --git a/repo/devel/cmake-extra.xibuild b/repo/devel/cmake-extra.xibuild deleted file mode 100644 index a81994f..0000000 --- a/repo/devel/cmake-extra.xibuild +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/sh - -MAKEDEPS="cmake" -DEPS="cmake" - -PKG_VER=1.6 -SOURCE=https://gitlab.com/ubports/core/cmake-extras/-/archive/$PKG_VER/cmake-extras-$PKG_VER.tar.gz -DESC="A collection of add-ons for the CMake build tool" - -build () { - cmake -B build \ - -DCMAKE_BUILD_TYPE=None \ - -DCMAKE_INSTALL_PREFIX=/usr - cmake --build build - -} - -package () { - DESTDIR="$PKG_DEST" cmake --build build --target install -} diff --git a/repo/devel/cmake-extra/cmake-extra.xibuild b/repo/devel/cmake-extra/cmake-extra.xibuild new file mode 100644 index 0000000..a81994f --- /dev/null +++ b/repo/devel/cmake-extra/cmake-extra.xibuild @@ -0,0 +1,20 @@ +#!/bin/sh + +MAKEDEPS="cmake" +DEPS="cmake" + +PKG_VER=1.6 +SOURCE=https://gitlab.com/ubports/core/cmake-extras/-/archive/$PKG_VER/cmake-extras-$PKG_VER.tar.gz +DESC="A collection of add-ons for the CMake build tool" + +build () { + cmake -B build \ + -DCMAKE_BUILD_TYPE=None \ + -DCMAKE_INSTALL_PREFIX=/usr + cmake --build build + +} + +package () { + DESTDIR="$PKG_DEST" cmake --build build --target install +} diff --git a/repo/devel/cmake-modules.xibuild b/repo/devel/cmake-modules.xibuild deleted file mode 100644 index b23083d..0000000 --- a/repo/devel/cmake-modules.xibuild +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/sh - -MAKEDEPS="cmake python-sphinx" -DEPS="cmake" - -PKG_VER=5.91.0 -SOURCE=https://download.kde.org/stable/frameworks/${PKG_VER%.*}/extra-cmake-modules-$PKG_VER.tar.xz -DESC="Extra CMake modules" - -build () { - cmake -B build \ - -DCMAKE_BUILD_TYPE=None \ - -DCMAKE_INSTALL_PREFIX=/usr \ - -DSphinx_BUILD_EXECUTABLE=/usr/bin/sphinx-build - cmake --build build - -} - -package () { - DESTDIR="$PKG_DEST" cmake --build build --target install -} diff --git a/repo/devel/cmake-modules/cmake-modules.xibuild b/repo/devel/cmake-modules/cmake-modules.xibuild new file mode 100644 index 0000000..b23083d --- /dev/null +++ b/repo/devel/cmake-modules/cmake-modules.xibuild @@ -0,0 +1,21 @@ +#!/bin/sh + +MAKEDEPS="cmake python-sphinx" +DEPS="cmake" + +PKG_VER=5.91.0 +SOURCE=https://download.kde.org/stable/frameworks/${PKG_VER%.*}/extra-cmake-modules-$PKG_VER.tar.xz +DESC="Extra CMake modules" + +build () { + cmake -B build \ + -DCMAKE_BUILD_TYPE=None \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DSphinx_BUILD_EXECUTABLE=/usr/bin/sphinx-build + cmake --build build + +} + +package () { + DESTDIR="$PKG_DEST" cmake --build build --target install +} diff --git a/repo/devel/cmake.xibuild b/repo/devel/cmake.xibuild deleted file mode 100644 index 41be69c..0000000 --- a/repo/devel/cmake.xibuild +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make" -DEPS="curl libarchive jsoncpp libuv rhash" - -PKG_VER=3.22.1 -SOURCE=https://github.com/Kitware/CMake/releases/download/v$PKG_VER/cmake-$PKG_VER.tar.gz -DESC="A cross-platform open-source make system" - -build () { - ./configure --prefix=/usr - make -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/cmake/cmake.xibuild b/repo/devel/cmake/cmake.xibuild new file mode 100644 index 0000000..41be69c --- /dev/null +++ b/repo/devel/cmake/cmake.xibuild @@ -0,0 +1,17 @@ +#!/bin/sh + +MAKEDEPS="make" +DEPS="curl libarchive jsoncpp libuv rhash" + +PKG_VER=3.22.1 +SOURCE=https://github.com/Kitware/CMake/releases/download/v$PKG_VER/cmake-$PKG_VER.tar.gz +DESC="A cross-platform open-source make system" + +build () { + ./configure --prefix=/usr + make +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/compiler-rt.xibuild b/repo/devel/compiler-rt.xibuild deleted file mode 100644 index abff3dc..0000000 --- a/repo/devel/compiler-rt.xibuild +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/sh - -NAME="compiler-rt" -DESC="LLVM compiler-rt runtime libraries" - -MAKEDEPS="cmake libexecinfo" -DEPS="musl " - -PKG_VER=13.0.0 -SOURCE="https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/compiler-rt-$PKG_VER.src.tar.xz" -ADDITIONAL="link-execinfo.patch " - -prepare () { - apply_patches -} - -build () { - cmake -B build \ - -DCMAKE_INSTALL_PREFIX=/usr \ - -DCMAKE_INSTALL_LIBDIR=/usr/lib \ - -DBUILD_SHARED_LIBS=True \ - -DBUILD_STATIC_LIBS=OFF \ - -DCMAKE_C_COMPILER=clang \ - -DCMAKE_CXX_COMPILER=clang++ \ - -DCMAKE_BUILD_TYPE=MinSizeRel \ - -DCMAKE_INSTALL_PREFIX=/usr \ - -DCOMPILER_RT_INCLUDE_TESTS=OFF \ - -DCOMPILER_RT_BUILD_SANITIZERS=ON \ - -DCOMPILER_RT_BUILD_XRAY=ON \ - -DCOMPILER_RT_INSTALL_PATH="/usr/lib/clang/$PKG_VER" \ - -DLLVM_EXTERNAL_LIT="/usr/bin/lit" \ - - cmake --build build -} - -package () { - DESTDIR="$PKG_DEST" cmake --install build -} diff --git a/repo/devel/compiler-rt/compiler-rt.xibuild b/repo/devel/compiler-rt/compiler-rt.xibuild new file mode 100644 index 0000000..abff3dc --- /dev/null +++ b/repo/devel/compiler-rt/compiler-rt.xibuild @@ -0,0 +1,38 @@ +#!/bin/sh + +NAME="compiler-rt" +DESC="LLVM compiler-rt runtime libraries" + +MAKEDEPS="cmake libexecinfo" +DEPS="musl " + +PKG_VER=13.0.0 +SOURCE="https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/compiler-rt-$PKG_VER.src.tar.xz" +ADDITIONAL="link-execinfo.patch " + +prepare () { + apply_patches +} + +build () { + cmake -B build \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DCMAKE_INSTALL_LIBDIR=/usr/lib \ + -DBUILD_SHARED_LIBS=True \ + -DBUILD_STATIC_LIBS=OFF \ + -DCMAKE_C_COMPILER=clang \ + -DCMAKE_CXX_COMPILER=clang++ \ + -DCMAKE_BUILD_TYPE=MinSizeRel \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DCOMPILER_RT_INCLUDE_TESTS=OFF \ + -DCOMPILER_RT_BUILD_SANITIZERS=ON \ + -DCOMPILER_RT_BUILD_XRAY=ON \ + -DCOMPILER_RT_INSTALL_PATH="/usr/lib/clang/$PKG_VER" \ + -DLLVM_EXTERNAL_LIT="/usr/bin/lit" \ + + cmake --build build +} + +package () { + DESTDIR="$PKG_DEST" cmake --install build +} diff --git a/repo/devel/compiler-rt/link-execinfo.patch b/repo/devel/compiler-rt/link-execinfo.patch new file mode 100644 index 0000000..8da49fb --- /dev/null +++ b/repo/devel/compiler-rt/link-execinfo.patch @@ -0,0 +1,11 @@ +--- a/lib/scudo/standalone/CMakeLists.txt ++++ b/lib/scudo/standalone/CMakeLists.txt +@@ -137,6 +137,8 @@ + + append_list_if(FUCHSIA zircon SCUDO_LINK_LIBS) + ++list(APPEND SCUDO_LINK_LIBS execinfo) ++ + if(COMPILER_RT_HAS_SCUDO_STANDALONE) + add_compiler_rt_object_libraries(RTScudoStandalone + ARCHS ${SCUDO_STANDALONE_SUPPORTED_ARCH} diff --git a/repo/devel/dejagnu.xibuild b/repo/devel/dejagnu.xibuild deleted file mode 100644 index 82e443d..0000000 --- a/repo/devel/dejagnu.xibuild +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make " -DEPS="sh expect" - -PKG_VER=1.6.3 -SOURCE=https://ftp.gnu.org/gnu/dejagnu/dejagnu-$PKG_VER.tar.gz -DESC="a framework for running test suites on GNU tools" - -build () { - mkdir build - cd build - - ../configure --prefix=/usr - - makeinfo --html --no-split -o doc/dejagnu.html ../doc/dejagnu.texi - makeinfo --plaintext -o doc/dejagnu.txt ../doc/dejagnu.texi -} - -package () { - make DESTDIR=$PKG_DEST install - - install -dm755 $PKG_DEST/usr/share/doc/dejagnu-$PKG_VER - install -m644 doc/dejagnu.txt $PKG_DEST/usr/share/doc/dejagnu-$PKG_VER - install -m644 doc/dejagnu.html $PKG_DEST/usr/share/doc/dejagnu-$PKG_VER -} - - diff --git a/repo/devel/dejagnu/dejagnu.xibuild b/repo/devel/dejagnu/dejagnu.xibuild new file mode 100644 index 0000000..82e443d --- /dev/null +++ b/repo/devel/dejagnu/dejagnu.xibuild @@ -0,0 +1,28 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="sh expect" + +PKG_VER=1.6.3 +SOURCE=https://ftp.gnu.org/gnu/dejagnu/dejagnu-$PKG_VER.tar.gz +DESC="a framework for running test suites on GNU tools" + +build () { + mkdir build + cd build + + ../configure --prefix=/usr + + makeinfo --html --no-split -o doc/dejagnu.html ../doc/dejagnu.texi + makeinfo --plaintext -o doc/dejagnu.txt ../doc/dejagnu.texi +} + +package () { + make DESTDIR=$PKG_DEST install + + install -dm755 $PKG_DEST/usr/share/doc/dejagnu-$PKG_VER + install -m644 doc/dejagnu.txt $PKG_DEST/usr/share/doc/dejagnu-$PKG_VER + install -m644 doc/dejagnu.html $PKG_DEST/usr/share/doc/dejagnu-$PKG_VER +} + + diff --git a/repo/devel/distcc.xibuild b/repo/devel/distcc.xibuild deleted file mode 100644 index f333ed6..0000000 --- a/repo/devel/distcc.xibuild +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh - -MAKEDEPS="python make automake autoconf" -DEPS="gcc python popt musl-obstack" - -PKG_VER=3.4 -SOURCE=https://github.com/distcc/distcc/releases/download/v$PKG_VER/distcc-$PKG_VER.tar.gz -ADDITIONAL=" - gcc-10.patch - dcc_gcc_rewrite_fqn-avoid-heap-corruption.patch - distcc-hardened.patch -" - -DESC="Distributed compiler for C, C++ and Objective-C" - -prepare () { - apply_patches -} - - -build () { - ./configure --prefix=/usr \ - --without-libiberty \ - --disable-Werror \ - --without-gtk \ - - - make -} - - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/distcc/dcc_gcc_rewrite_fqn-avoid-heap-corruption.patch b/repo/devel/distcc/dcc_gcc_rewrite_fqn-avoid-heap-corruption.patch new file mode 100644 index 0000000..5d0a86d --- /dev/null +++ b/repo/devel/distcc/dcc_gcc_rewrite_fqn-avoid-heap-corruption.patch @@ -0,0 +1,65 @@ +commit 879b71d6e95673e58d33f6c3c341a893ee307161 +Author: Alexey Sheplyakov +Date: Sat Jul 10 22:18:14 2021 +0400 + + dcc_gcc_rewrite_fqn: avoid heap corruption + + On ALT Linux I've run into the following bug: + + distcc gcc -Wall -std=gnu89 -I. -O2 -o hello.o -c hello.c + free(): invalid next size (fast) + Aborted (core dumped) + + Apparently dcc_gcc_rewrite writes beyond the allocated memory: + + valgrind --leak-check=full -v ./distcc gcc -Wall -std=gnu89 -I. -O2 -o hello.o -c hello.c + + ==11382== ERROR SUMMARY: 53 errors from 5 contexts (suppressed: 0 from 0) + ==11382== + ==11382== 1 errors in context 1 of 5: + ==11382== Invalid write of size 1 + ==11382== at 0x4C349D8: strcat (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so) + ==11382== by 0x10D165: dcc_gcc_rewrite_fqn (compile.c:611) + ==11382== by 0x10D4B4: dcc_build_somewhere (compile.c:725) + ==11382== by 0x10DC01: dcc_build_somewhere_timed (compile.c:1014) + ==11382== by 0x10E380: main (distcc.c:352) + ==11382== Address 0x544e828 is 1 bytes after a block of size 23 alloc'd + ==11382== at 0x4C31B0F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so) + ==11382== by 0x10D087: dcc_gcc_rewrite_fqn (compile.c:588) + ==11382== by 0x10D4B4: dcc_build_somewhere (compile.c:725) + ==11382== by 0x10DC01: dcc_build_somewhere_timed (compile.c:1014) + ==11382== by 0x10E380: main (distcc.c:352) + ==11382== + ==11382== + ==11382== 1 errors in context 2 of 5: + ==11382== Invalid write of size 1 + ==11382== at 0x4C349C8: strcat (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so) + ==11382== by 0x10D165: dcc_gcc_rewrite_fqn (compile.c:611) + ==11382== by 0x10D4B4: dcc_build_somewhere (compile.c:725) + ==11382== by 0x10DC01: dcc_build_somewhere_timed (compile.c:1014) + ==11382== by 0x10E380: main (distcc.c:352) + ==11382== Address 0x544e827 is 0 bytes after a block of size 23 alloc'd + ==11382== at 0x4C31B0F: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so) + ==11382== by 0x10D087: dcc_gcc_rewrite_fqn (compile.c:588) + ==11382== by 0x10D4B4: dcc_build_somewhere (compile.c:725) + ==11382== by 0x10DC01: dcc_build_somewhere_timed (compile.c:1014) + ==11382== by 0x10E380: main (distcc.c:352) + + and ALT Linux' hardened glibc does not quite like that. + Correctly compute the `newcmd_len` to avoid the problem. + + ALTBUG: #40425 + +diff --git a/src/compile.c b/src/compile.c +index 34964566fdd6..26d7d1821501 100644 +--- a/src/compile.c ++++ b/src/compile.c +@@ -584,7 +584,7 @@ static int dcc_gcc_rewrite_fqn(char **argv) + return -ENOENT; + + +- newcmd_len = strlen(target_with_vendor) + 1 + strlen(argv[0] + 1); ++ newcmd_len = strlen(target_with_vendor) + 1 + strlen(argv[0]) + 1; + newcmd = malloc(newcmd_len); + if (!newcmd) + return -ENOMEM; diff --git a/repo/devel/distcc/distcc-hardened.patch b/repo/devel/distcc/distcc-hardened.patch new file mode 100644 index 0000000..c50b15d --- /dev/null +++ b/repo/devel/distcc/distcc-hardened.patch @@ -0,0 +1,24 @@ +From: Gordon Malm + +Make distcc client pass -D__KERNEL__ macro. Hardened GCC uses this +macro to determine if code intended to be run in-kernel is being compiled. +If the code is kernel code, certain compile flags are not applied. + +When using distcc to build kernel code (modules, etc.) without this patch, +the distccd host doesn't get passed -D__KERNEL__. Consequently, gcc on +the distccd host applies all kinds of flags that it shouldn't. + +--- distcc-2.18.3/src/strip.c ++++ distcc-2.18.3-hardened/src/strip.c +@@ -79,7 +79,10 @@ int dcc_strip_local_args(char **from, ch + /* skip through argv, copying all arguments but skipping ones that + * ought to be omitted */ + for (from_i = to_i = 0; from[from_i]; from_i++) { +- if (str_equal("-D", from[from_i]) ++ if (str_equal("-D__KERNEL__", from[from_i])) { ++ to[to_i++] = from[from_i]; ++ } ++ else if (str_equal("-D", from[from_i]) + || str_equal("-I", from[from_i]) + || str_equal("-U", from[from_i]) + || str_equal("-L", from[from_i]) diff --git a/repo/devel/distcc/distcc.xibuild b/repo/devel/distcc/distcc.xibuild new file mode 100644 index 0000000..f333ed6 --- /dev/null +++ b/repo/devel/distcc/distcc.xibuild @@ -0,0 +1,34 @@ +#!/bin/sh + +MAKEDEPS="python make automake autoconf" +DEPS="gcc python popt musl-obstack" + +PKG_VER=3.4 +SOURCE=https://github.com/distcc/distcc/releases/download/v$PKG_VER/distcc-$PKG_VER.tar.gz +ADDITIONAL=" + gcc-10.patch + dcc_gcc_rewrite_fqn-avoid-heap-corruption.patch + distcc-hardened.patch +" + +DESC="Distributed compiler for C, C++ and Objective-C" + +prepare () { + apply_patches +} + + +build () { + ./configure --prefix=/usr \ + --without-libiberty \ + --disable-Werror \ + --without-gtk \ + + + make +} + + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/distcc/gcc-10.patch b/repo/devel/distcc/gcc-10.patch new file mode 100644 index 0000000..599de51 --- /dev/null +++ b/repo/devel/distcc/gcc-10.patch @@ -0,0 +1,15 @@ +Upstream: Should be +Reason: Fixes compilation under gcc-10 which has -fno-common + +diff --git a/src/stats.c b/src/stats.c +index 35dbf7d..76bfbee 100644 +--- a/src/stats.c ++++ b/src/stats.c +@@ -82,7 +82,7 @@ struct statsdata { + char compiler[MAX_FILENAME_LEN]; + }; + +-const char *stats_text[20] = { "TCP_ACCEPT", "REJ_BAD_REQ", "REJ_OVERLOAD", ++extern const char *stats_text[20] = { "TCP_ACCEPT", "REJ_BAD_REQ", "REJ_OVERLOAD", + "COMPILE_OK", "COMPILE_ERROR", "COMPILE_TIMEOUT", "CLI_DISCONN", + "OTHER" }; diff --git a/repo/devel/docbook-dtd.xibuild b/repo/devel/docbook-dtd.xibuild deleted file mode 100644 index f751d36..0000000 --- a/repo/devel/docbook-dtd.xibuild +++ /dev/null @@ -1,128 +0,0 @@ -#!/bin/sh - -MAKEDEPS="unzip" -DEPS="libxml2 sgml-common" - -PKG_VER=4.5 -SOURCE=https://www.docbook.org/sgml/$PKG_VER/docbook-$PKG_VER.zip -DESC="Document type definitions for verification of SGML data files" - -prepare() { - sed -i -e '/ISO 8879/d' \ - -e '/gml/d' docbook.cat - -} - -package () { - install -d $PKG_DEST/usr/share/sgml/docbook/sgml-dtd-$PKG_VER && - chown -R root:root . && - - install docbook.cat $PKG_DEST/usr/share/sgml/docbook/sgml-dtd-$PKG_VER/catalog && - cp -af *.dtd *.mod *.dcl $PKG_DEST/usr/share/sgml/docbook/sgml-dtd-$PKG_VER && - - - cat >> $PKG_DEST/usr/share/sgml/docbook/sgml-dtd-$PKG_VER/catalog << "EOF" - -- Begin Single Major Version catalog changes -- - -PUBLIC "-//OASIS//DTD DocBook V4.4//EN" "docbook.dtd" -PUBLIC "-//OASIS//DTD DocBook V4.3//EN" "docbook.dtd" -PUBLIC "-//OASIS//DTD DocBook V4.2//EN" "docbook.dtd" -PUBLIC "-//OASIS//DTD DocBook V4.1//EN" "docbook.dtd" -PUBLIC "-//OASIS//DTD DocBook V4.0//EN" "docbook.dtd" - - -- End Single Major Version catalog changes -- -EOF -} - -postinstall () { - if [ ! -e /etc/xml/docbook ]; then - xmlcatalog --noout --create /etc/xml/docbook - fi - xmlcatalog --noout --add "public" \ - "-//OASIS//DTD DocBook XML V4.5//EN" \ - "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//DTD DocBook XML CALS Table Model V4.5//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5/calstblx.dtd" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//DTD XML Exchange Table Model 19990315//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5/soextblx.dtd" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ELEMENTS DocBook XML Information Pool V4.5//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5/dbpoolx.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ELEMENTS DocBook XML Document Hierarchy V4.5//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5/dbhierx.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ELEMENTS DocBook XML HTML Tables V4.5//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5/htmltblx.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ENTITIES DocBook XML Notations V4.5//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5/dbnotnx.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ENTITIES DocBook XML Character Entities V4.5//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5/dbcentx.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ENTITIES DocBook XML Additional General Entities V4.5//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5/dbgenent.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "rewriteSystem" \ - "http://www.oasis-open.org/docbook/xml/4.5" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5" \ - /etc/xml/docbook && - xmlcatalog --noout --add "rewriteURI" \ - "http://www.oasis-open.org/docbook/xml/4.5" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5" \ - /etc/xml/docbook - if [ ! -e /etc/xml/catalog ]; then - xmlcatalog --noout --create /etc/xml/catalog - fi - xmlcatalog --noout --add "delegatePublic" \ - "-//OASIS//ENTITIES DocBook XML" \ - "file:///etc/xml/docbook" \ - /etc/xml/catalog && - xmlcatalog --noout --add "delegatePublic" \ - "-//OASIS//DTD DocBook XML" \ - "file:///etc/xml/docbook" \ - /etc/xml/catalog && - xmlcatalog --noout --add "delegateSystem" \ - "http://www.oasis-open.org/docbook/" \ - "file:///etc/xml/docbook" \ - /etc/xml/catalog && - xmlcatalog --noout --add "delegateURI" \ - "http://www.oasis-open.org/docbook/" \ - "file:///etc/xml/docbook" \ - /etc/xml/catalog - for DTDVERSION in 4.1.2 4.2 4.3 4.4; do - xmlcatalog --noout --add "public" \ - "-//OASIS//DTD DocBook XML V$DTDVERSION//EN" \ - "http://www.oasis-open.org/docbook/xml/$DTDVERSION/docbookx.dtd" \ - /etc/xml/docbook - xmlcatalog --noout --add "rewriteSystem" \ - "http://www.oasis-open.org/docbook/xml/$DTDVERSION" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5" \ - /etc/xml/docbook - xmlcatalog --noout --add "rewriteURI" \ - "http://www.oasis-open.org/docbook/xml/$DTDVERSION" \ - "file:///usr/share/xml/docbook/xml-dtd-4.5" \ - /etc/xml/docbook - xmlcatalog --noout --add "delegateSystem" \ - "http://www.oasis-open.org/docbook/xml/$DTDVERSION/" \ - "file:///etc/xml/docbook" \ - /etc/xml/catalog - xmlcatalog --noout --add "delegateURI" \ - "http://www.oasis-open.org/docbook/xml/$DTDVERSION/" \ - "file:///etc/xml/docbook" \ - /etc/xml/catalog -done - -} - diff --git a/repo/devel/docbook-dtd/docbook-dtd.xibuild b/repo/devel/docbook-dtd/docbook-dtd.xibuild new file mode 100644 index 0000000..f751d36 --- /dev/null +++ b/repo/devel/docbook-dtd/docbook-dtd.xibuild @@ -0,0 +1,128 @@ +#!/bin/sh + +MAKEDEPS="unzip" +DEPS="libxml2 sgml-common" + +PKG_VER=4.5 +SOURCE=https://www.docbook.org/sgml/$PKG_VER/docbook-$PKG_VER.zip +DESC="Document type definitions for verification of SGML data files" + +prepare() { + sed -i -e '/ISO 8879/d' \ + -e '/gml/d' docbook.cat + +} + +package () { + install -d $PKG_DEST/usr/share/sgml/docbook/sgml-dtd-$PKG_VER && + chown -R root:root . && + + install docbook.cat $PKG_DEST/usr/share/sgml/docbook/sgml-dtd-$PKG_VER/catalog && + cp -af *.dtd *.mod *.dcl $PKG_DEST/usr/share/sgml/docbook/sgml-dtd-$PKG_VER && + + + cat >> $PKG_DEST/usr/share/sgml/docbook/sgml-dtd-$PKG_VER/catalog << "EOF" + -- Begin Single Major Version catalog changes -- + +PUBLIC "-//OASIS//DTD DocBook V4.4//EN" "docbook.dtd" +PUBLIC "-//OASIS//DTD DocBook V4.3//EN" "docbook.dtd" +PUBLIC "-//OASIS//DTD DocBook V4.2//EN" "docbook.dtd" +PUBLIC "-//OASIS//DTD DocBook V4.1//EN" "docbook.dtd" +PUBLIC "-//OASIS//DTD DocBook V4.0//EN" "docbook.dtd" + + -- End Single Major Version catalog changes -- +EOF +} + +postinstall () { + if [ ! -e /etc/xml/docbook ]; then + xmlcatalog --noout --create /etc/xml/docbook + fi + xmlcatalog --noout --add "public" \ + "-//OASIS//DTD DocBook XML V4.5//EN" \ + "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//DTD DocBook XML CALS Table Model V4.5//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5/calstblx.dtd" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//DTD XML Exchange Table Model 19990315//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5/soextblx.dtd" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ELEMENTS DocBook XML Information Pool V4.5//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5/dbpoolx.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ELEMENTS DocBook XML Document Hierarchy V4.5//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5/dbhierx.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ELEMENTS DocBook XML HTML Tables V4.5//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5/htmltblx.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ENTITIES DocBook XML Notations V4.5//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5/dbnotnx.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ENTITIES DocBook XML Character Entities V4.5//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5/dbcentx.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ENTITIES DocBook XML Additional General Entities V4.5//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5/dbgenent.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "rewriteSystem" \ + "http://www.oasis-open.org/docbook/xml/4.5" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5" \ + /etc/xml/docbook && + xmlcatalog --noout --add "rewriteURI" \ + "http://www.oasis-open.org/docbook/xml/4.5" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5" \ + /etc/xml/docbook + if [ ! -e /etc/xml/catalog ]; then + xmlcatalog --noout --create /etc/xml/catalog + fi + xmlcatalog --noout --add "delegatePublic" \ + "-//OASIS//ENTITIES DocBook XML" \ + "file:///etc/xml/docbook" \ + /etc/xml/catalog && + xmlcatalog --noout --add "delegatePublic" \ + "-//OASIS//DTD DocBook XML" \ + "file:///etc/xml/docbook" \ + /etc/xml/catalog && + xmlcatalog --noout --add "delegateSystem" \ + "http://www.oasis-open.org/docbook/" \ + "file:///etc/xml/docbook" \ + /etc/xml/catalog && + xmlcatalog --noout --add "delegateURI" \ + "http://www.oasis-open.org/docbook/" \ + "file:///etc/xml/docbook" \ + /etc/xml/catalog + for DTDVERSION in 4.1.2 4.2 4.3 4.4; do + xmlcatalog --noout --add "public" \ + "-//OASIS//DTD DocBook XML V$DTDVERSION//EN" \ + "http://www.oasis-open.org/docbook/xml/$DTDVERSION/docbookx.dtd" \ + /etc/xml/docbook + xmlcatalog --noout --add "rewriteSystem" \ + "http://www.oasis-open.org/docbook/xml/$DTDVERSION" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5" \ + /etc/xml/docbook + xmlcatalog --noout --add "rewriteURI" \ + "http://www.oasis-open.org/docbook/xml/$DTDVERSION" \ + "file:///usr/share/xml/docbook/xml-dtd-4.5" \ + /etc/xml/docbook + xmlcatalog --noout --add "delegateSystem" \ + "http://www.oasis-open.org/docbook/xml/$DTDVERSION/" \ + "file:///etc/xml/docbook" \ + /etc/xml/catalog + xmlcatalog --noout --add "delegateURI" \ + "http://www.oasis-open.org/docbook/xml/$DTDVERSION/" \ + "file:///etc/xml/docbook" \ + /etc/xml/catalog +done + +} + diff --git a/repo/devel/docbook-xml.xibuild b/repo/devel/docbook-xml.xibuild deleted file mode 100644 index 56efc6c..0000000 --- a/repo/devel/docbook-xml.xibuild +++ /dev/null @@ -1,132 +0,0 @@ -#!/bin/sh - -MAKEDEPS="" -DEPS="libxml2" - -PKG_VER=5.1 -SOURCE=https://docbook.org/xml/$PKG_VER/docbook-v$PKG_VER-os.zip -DESC="A widely used XML scheme for writing documentation and help" - -package () { - install -dm755 $PKG_DEST/usr/share/xml/docbook/schema/sch/$PKG_VER && - install -dm755 $PKG_DEST/usr/share/xml/docbook/schema/rng/$PKG_VER && - install -m644 schemas/rng/* $PKG_DEST/usr/share/xml/docbook/schema/rng/$PKG_VER && - install -m644 schemas/sch/* $PKG_DEST/usr/share/xml/docbook/schema/sch/$PKG_VER && - install -m755 tools/db4-entities.pl $PKG_DEST/usr/bin && - install -dm755 $PKG_DEST/usr/share/xml/docbook/stylesheet/docbook5 && - install -m644 tools/db4-upgrade.xsl \ - $PKG_DEST/usr/share/xml/docbook/stylesheet/docbook5 -} - -postinstall () { - mkdir -p /etc/xml - if [ ! -e /etc/xml/docbook-$PKG_VER ]; then - xmlcatalog --noout --create /etc/xml/docbook-$PKG_VER - fi && - - xmlcatalog --noout --add "uri" \ - "http://www.oasis-open.org/docbook/xml/$PKG_VER/rng/docbook.rng" \ - "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbook.rng" \ - /etc/xml/docbook-$PKG_VER && - xmlcatalog --noout --add "uri" \ - "http://docbook.org/xml/$PKG_VER/rng/docbook.rng" \ - "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbook.rng" \ - /etc/xml/docbook-$PKG_VER && - xmlcatalog --noout --add "uri" \ - "http://www.oasis-open.org/docbook/xml/$PKG_VER/rng/docbookxi.rng" \ - "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbookxi.rng" \ - /etc/xml/docbook-$PKG_VER && - xmlcatalog --noout --add "uri" \ - "http://docbook.org/xml/$PKG_VER/rng/docbookxi.rng" \ - "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbookxi.rng" \ - /etc/xml/docbook-$PKG_VER && - xmlcatalog --noout --add "uri" \ - "http://www.oasis-open.org/docbook/xml/$PKG_VER/rnc/docbook.rnc" \ - "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbook.rnc" \ - /etc/xml/docbook-$PKG_VER && - xmlcatalog --noout --add "uri" \ - "http://docbook.org/xml/$PKG_VER/rng/docbook.rnc" \ - "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbook.rnc" \ - /etc/xml/docbook-$PKG_VER && - xmlcatalog --noout --add "uri" \ - "http://www.oasis-open.org/docbook/xml/$PKG_VER/rnc/docbookxi.rnc" \ - "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbookxi.rnc" \ - /etc/xml/docbook-$PKG_VER && - xmlcatalog --noout --add "uri" \ - "http://docbook.org/xml/$PKG_VER/rng/docbookxi.rnc" \ - "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbookxi.rnc" \ - /etc/xml/docbook-$PKG_VER && - - xmlcatalog --noout --add "uri" \ - "http://www.oasis-open.org/docbook/xml/$PKG_VER/sch/docbook.sch" \ - "file:///usr/share/xml/docbook/schema/sch/$PKG_VER/docbook.sch" \ - /etc/xml/docbook-$PKG_VER && - xmlcatalog --noout --add "uri" \ - "http://docbook.org/xml/$PKG_VER/sch/docbook.sch" \ - "file:///usr/share/xml/docbook/schema/sch/$PKG_VER/docbook.sch" \ - /etc/xml/docbook-$PKG_VER - - xmlcatalog --noout --create /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && - - xmlcatalog --noout --add "uri" \ - "http://docbook.org/xml/$PKG_VER/schemas/rng/docbook.schemas/rng" \ - "docbook.schemas/rng" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && - xmlcatalog --noout --add "uri" \ - "http://www.oasis-open.org/docbook/xml/$PKG_VER/schemas/rng/docbook.schemas/rng" \ - "docbook.schemas/rng" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && - xmlcatalog --noout --add "uri" \ - "http://docbook.org/xml/$PKG_VER/schemas/rng/docbookxi.schemas/rng" \ - "docbookxi.schemas/rng" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && - xmlcatalog --noout --add "uri" \ - "http://www.oasis-open.org/docbook/xml/$PKG_VER/schemas/rng/docbookxi.schemas/rng" \ - "docbookxi.schemas/rng" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && - xmlcatalog --noout --add "uri" \ - "http://docbook.org/xml/$PKG_VER/schemas/rng/docbook.rnc" \ - "docbook.rnc" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && - xmlcatalog --noout --add "uri" \ - "http://www.oasis-open.org/docbook/xml/$PKG_VER/schemas/rng/docbook.rnc" \ - "docbook.rnc" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && - xmlcatalog --noout --add "uri" \ - "http://docbook.org/xml/$PKG_VER/schemas/rng/docbookxi.rnc" \ - "docbookxi.rnc" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && - xmlcatalog --noout --add "uri" \ - "http://www.oasis-open.org/docbook/xml/$PKG_VER/schemas/rng/docbookxi.rnc" \ - "docbookxi.rnc" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml - xmlcatalog --noout --create /usr/share/xml/docbook/schema/sch/$PKG_VER/catalog.xml && - - xmlcatalog --noout --add "uri" \ - "http://docbook.org/xml/$PKG_VER/schemas/sch/docbook.schemas/sch" \ - "docbook.schemas/sch" /usr/share/xml/docbook/schema/sch/$PKG_VER/catalog.xml && - xmlcatalog --noout --add "uri" \ - "http://www.oasis-open.org/docbook/xml/$PKG_VER/schemas/sch/docbook.schemas/sch" \ - "docbook.schemas/sch" /usr/share/xml/docbook/schema/sch/$PKG_VER/catalog.xml - - if [ ! -e /etc/xml/catalog ]; then - xmlcatalog --noout --create /etc/xml/catalog - fi && - xmlcatalog --noout --add "delegatePublic" \ - "-//OASIS//DTD DocBook XML $PKG_VER//EN" \ - "file:///usr/share/xml/docbook/schema/dtd/$PKG_VER/catalog.xml" \ - /etc/xml/catalog && - xmlcatalog --noout --add "delegateSystem" \ - "http://docbook.org/xml/$PKG_VER/dtd/" \ - "file:///usr/share/xml/docbook/schema/dtd/$PKG_VER/catalog.xml" \ - /etc/xml/catalog && - xmlcatalog --noout --add "delegateURI" \ - "http://docbook.org/xml/$PKG_VER/dtd/" \ - "file:///usr/share/xml/docbook/schema/dtd/$PKG_VER/catalog.xml" \ - /etc/xml/catalog && - xmlcatalog --noout --add "delegateURI" \ - "http://docbook.org/xml/$PKG_VER/rng/" \ - "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml" \ - /etc/xml/catalog && - xmlcatalog --noout --add "delegateURI" \ - "http://docbook.org/xml/$PKG_VER/sch/" \ - "file:///usr/share/xml/docbook/schema/sch/$PKG_VER/catalog.xml" \ - /etc/xml/catalog && - xmlcatalog --noout --add "delegateURI" \ - "http://docbook.org/xml/$PKG_VER/xsd/" \ - "file:///usr/share/xml/docbook/schema/xsd/$PKG_VER/catalog.xml" \ - /etc/xml/catalog -} - diff --git a/repo/devel/docbook-xml/docbook-xml.xibuild b/repo/devel/docbook-xml/docbook-xml.xibuild new file mode 100644 index 0000000..56efc6c --- /dev/null +++ b/repo/devel/docbook-xml/docbook-xml.xibuild @@ -0,0 +1,132 @@ +#!/bin/sh + +MAKEDEPS="" +DEPS="libxml2" + +PKG_VER=5.1 +SOURCE=https://docbook.org/xml/$PKG_VER/docbook-v$PKG_VER-os.zip +DESC="A widely used XML scheme for writing documentation and help" + +package () { + install -dm755 $PKG_DEST/usr/share/xml/docbook/schema/sch/$PKG_VER && + install -dm755 $PKG_DEST/usr/share/xml/docbook/schema/rng/$PKG_VER && + install -m644 schemas/rng/* $PKG_DEST/usr/share/xml/docbook/schema/rng/$PKG_VER && + install -m644 schemas/sch/* $PKG_DEST/usr/share/xml/docbook/schema/sch/$PKG_VER && + install -m755 tools/db4-entities.pl $PKG_DEST/usr/bin && + install -dm755 $PKG_DEST/usr/share/xml/docbook/stylesheet/docbook5 && + install -m644 tools/db4-upgrade.xsl \ + $PKG_DEST/usr/share/xml/docbook/stylesheet/docbook5 +} + +postinstall () { + mkdir -p /etc/xml + if [ ! -e /etc/xml/docbook-$PKG_VER ]; then + xmlcatalog --noout --create /etc/xml/docbook-$PKG_VER + fi && + + xmlcatalog --noout --add "uri" \ + "http://www.oasis-open.org/docbook/xml/$PKG_VER/rng/docbook.rng" \ + "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbook.rng" \ + /etc/xml/docbook-$PKG_VER && + xmlcatalog --noout --add "uri" \ + "http://docbook.org/xml/$PKG_VER/rng/docbook.rng" \ + "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbook.rng" \ + /etc/xml/docbook-$PKG_VER && + xmlcatalog --noout --add "uri" \ + "http://www.oasis-open.org/docbook/xml/$PKG_VER/rng/docbookxi.rng" \ + "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbookxi.rng" \ + /etc/xml/docbook-$PKG_VER && + xmlcatalog --noout --add "uri" \ + "http://docbook.org/xml/$PKG_VER/rng/docbookxi.rng" \ + "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbookxi.rng" \ + /etc/xml/docbook-$PKG_VER && + xmlcatalog --noout --add "uri" \ + "http://www.oasis-open.org/docbook/xml/$PKG_VER/rnc/docbook.rnc" \ + "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbook.rnc" \ + /etc/xml/docbook-$PKG_VER && + xmlcatalog --noout --add "uri" \ + "http://docbook.org/xml/$PKG_VER/rng/docbook.rnc" \ + "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbook.rnc" \ + /etc/xml/docbook-$PKG_VER && + xmlcatalog --noout --add "uri" \ + "http://www.oasis-open.org/docbook/xml/$PKG_VER/rnc/docbookxi.rnc" \ + "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbookxi.rnc" \ + /etc/xml/docbook-$PKG_VER && + xmlcatalog --noout --add "uri" \ + "http://docbook.org/xml/$PKG_VER/rng/docbookxi.rnc" \ + "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/docbookxi.rnc" \ + /etc/xml/docbook-$PKG_VER && + + xmlcatalog --noout --add "uri" \ + "http://www.oasis-open.org/docbook/xml/$PKG_VER/sch/docbook.sch" \ + "file:///usr/share/xml/docbook/schema/sch/$PKG_VER/docbook.sch" \ + /etc/xml/docbook-$PKG_VER && + xmlcatalog --noout --add "uri" \ + "http://docbook.org/xml/$PKG_VER/sch/docbook.sch" \ + "file:///usr/share/xml/docbook/schema/sch/$PKG_VER/docbook.sch" \ + /etc/xml/docbook-$PKG_VER + + xmlcatalog --noout --create /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && + + xmlcatalog --noout --add "uri" \ + "http://docbook.org/xml/$PKG_VER/schemas/rng/docbook.schemas/rng" \ + "docbook.schemas/rng" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && + xmlcatalog --noout --add "uri" \ + "http://www.oasis-open.org/docbook/xml/$PKG_VER/schemas/rng/docbook.schemas/rng" \ + "docbook.schemas/rng" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && + xmlcatalog --noout --add "uri" \ + "http://docbook.org/xml/$PKG_VER/schemas/rng/docbookxi.schemas/rng" \ + "docbookxi.schemas/rng" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && + xmlcatalog --noout --add "uri" \ + "http://www.oasis-open.org/docbook/xml/$PKG_VER/schemas/rng/docbookxi.schemas/rng" \ + "docbookxi.schemas/rng" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && + xmlcatalog --noout --add "uri" \ + "http://docbook.org/xml/$PKG_VER/schemas/rng/docbook.rnc" \ + "docbook.rnc" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && + xmlcatalog --noout --add "uri" \ + "http://www.oasis-open.org/docbook/xml/$PKG_VER/schemas/rng/docbook.rnc" \ + "docbook.rnc" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && + xmlcatalog --noout --add "uri" \ + "http://docbook.org/xml/$PKG_VER/schemas/rng/docbookxi.rnc" \ + "docbookxi.rnc" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml && + xmlcatalog --noout --add "uri" \ + "http://www.oasis-open.org/docbook/xml/$PKG_VER/schemas/rng/docbookxi.rnc" \ + "docbookxi.rnc" /usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml + xmlcatalog --noout --create /usr/share/xml/docbook/schema/sch/$PKG_VER/catalog.xml && + + xmlcatalog --noout --add "uri" \ + "http://docbook.org/xml/$PKG_VER/schemas/sch/docbook.schemas/sch" \ + "docbook.schemas/sch" /usr/share/xml/docbook/schema/sch/$PKG_VER/catalog.xml && + xmlcatalog --noout --add "uri" \ + "http://www.oasis-open.org/docbook/xml/$PKG_VER/schemas/sch/docbook.schemas/sch" \ + "docbook.schemas/sch" /usr/share/xml/docbook/schema/sch/$PKG_VER/catalog.xml + + if [ ! -e /etc/xml/catalog ]; then + xmlcatalog --noout --create /etc/xml/catalog + fi && + xmlcatalog --noout --add "delegatePublic" \ + "-//OASIS//DTD DocBook XML $PKG_VER//EN" \ + "file:///usr/share/xml/docbook/schema/dtd/$PKG_VER/catalog.xml" \ + /etc/xml/catalog && + xmlcatalog --noout --add "delegateSystem" \ + "http://docbook.org/xml/$PKG_VER/dtd/" \ + "file:///usr/share/xml/docbook/schema/dtd/$PKG_VER/catalog.xml" \ + /etc/xml/catalog && + xmlcatalog --noout --add "delegateURI" \ + "http://docbook.org/xml/$PKG_VER/dtd/" \ + "file:///usr/share/xml/docbook/schema/dtd/$PKG_VER/catalog.xml" \ + /etc/xml/catalog && + xmlcatalog --noout --add "delegateURI" \ + "http://docbook.org/xml/$PKG_VER/rng/" \ + "file:///usr/share/xml/docbook/schema/rng/$PKG_VER/catalog.xml" \ + /etc/xml/catalog && + xmlcatalog --noout --add "delegateURI" \ + "http://docbook.org/xml/$PKG_VER/sch/" \ + "file:///usr/share/xml/docbook/schema/sch/$PKG_VER/catalog.xml" \ + /etc/xml/catalog && + xmlcatalog --noout --add "delegateURI" \ + "http://docbook.org/xml/$PKG_VER/xsd/" \ + "file:///usr/share/xml/docbook/schema/xsd/$PKG_VER/catalog.xml" \ + /etc/xml/catalog +} + diff --git a/repo/devel/docbook-xsl.xibuild b/repo/devel/docbook-xsl.xibuild deleted file mode 100644 index f5d576d..0000000 --- a/repo/devel/docbook-xsl.xibuild +++ /dev/null @@ -1,74 +0,0 @@ -#!/bin/sh - -MAKEDEPS="patch" -DEPS="libxml2 libxslt docbook-xml" - -PKG_VER=1.79.2 -SOURCE=https://github.com/docbook/xslt10-stylesheets/releases/download/release/$PKG_VER/docbook-xsl-nons-$PKG_VER.tar.bz2 -ADDITIONAL=" - https://www.linuxfromscratch.org/patches/blfs/svn/docbook-xsl-nons-$PKG_VER-stack_fix-1.patch -" - -DESC="XML stylesheets for Docbook-xml transformations" - -prepare() { - patch -Np1 -i docbook-xsl-nons-$PKG_VER-stack_fix-1.patch - -} - -package () { - install -m755 -d $PKG_DEST/usr/share/xml/docbook/xsl-stylesheets-nons-$PKG_VER && - - cp -R VERSION assembly common eclipse epub epub3 extensions fo \ - highlighting html htmlhelp images javahelp lib manpages params \ - profiling roundtrip slides template tests tools webhelp website \ - xhtml xhtml-1_1 xhtml5 \ - $PKG_DEST/usr/share/xml/docbook/xsl-stylesheets-nons-$PKG_VER && - - ln -s VERSION $PKG_DEST/usr/share/xml/docbook/xsl-stylesheets-nons-$PKG_VER/VERSION.xsl && - - install -m644 -D README \ - $PKG_DEST/usr/share/doc/docbook-xsl-nons-$PKG_VER/README.txt && - install -m644 RELEASE-NOTES* NEWS* \ - $PKG_DEST/usr/share/doc/docbook-xsl-nons-$PKG_VER - - - } - -postinstall () { - if [ ! -d /etc/xml ]; then install -m755 -d /etc/xml; fi && - if [ ! -f /etc/xml/catalog ]; then - xmlcatalog --noout --create /etc/xml/catalog - fi && - - xmlcatalog --noout --add "rewriteSystem" \ - "https://cdn.docbook.org/release/xsl-nons/1.79.2" \ - "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ - /etc/xml/catalog && - - xmlcatalog --noout --add "rewriteURI" \ - "https://cdn.docbook.org/release/xsl-nons/1.79.2" \ - "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ - /etc/xml/catalog && - - xmlcatalog --noout --add "rewriteSystem" \ - "https://cdn.docbook.org/release/xsl-nons/current" \ - "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ - /etc/xml/catalog && - - xmlcatalog --noout --add "rewriteURI" \ - "https://cdn.docbook.org/release/xsl-nons/current" \ - "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ - /etc/xml/catalog && - - xmlcatalog --noout --add "rewriteSystem" \ - "http://docbook.sourceforge.net/release/xsl/current" \ - "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ - /etc/xml/catalog && - - xmlcatalog --noout --add "rewriteURI" \ - "http://docbook.sourceforge.net/release/xsl/current" \ - "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ - /etc/xml/catalog -} - diff --git a/repo/devel/docbook-xsl/docbook-xsl.xibuild b/repo/devel/docbook-xsl/docbook-xsl.xibuild new file mode 100644 index 0000000..f5d576d --- /dev/null +++ b/repo/devel/docbook-xsl/docbook-xsl.xibuild @@ -0,0 +1,74 @@ +#!/bin/sh + +MAKEDEPS="patch" +DEPS="libxml2 libxslt docbook-xml" + +PKG_VER=1.79.2 +SOURCE=https://github.com/docbook/xslt10-stylesheets/releases/download/release/$PKG_VER/docbook-xsl-nons-$PKG_VER.tar.bz2 +ADDITIONAL=" + https://www.linuxfromscratch.org/patches/blfs/svn/docbook-xsl-nons-$PKG_VER-stack_fix-1.patch +" + +DESC="XML stylesheets for Docbook-xml transformations" + +prepare() { + patch -Np1 -i docbook-xsl-nons-$PKG_VER-stack_fix-1.patch + +} + +package () { + install -m755 -d $PKG_DEST/usr/share/xml/docbook/xsl-stylesheets-nons-$PKG_VER && + + cp -R VERSION assembly common eclipse epub epub3 extensions fo \ + highlighting html htmlhelp images javahelp lib manpages params \ + profiling roundtrip slides template tests tools webhelp website \ + xhtml xhtml-1_1 xhtml5 \ + $PKG_DEST/usr/share/xml/docbook/xsl-stylesheets-nons-$PKG_VER && + + ln -s VERSION $PKG_DEST/usr/share/xml/docbook/xsl-stylesheets-nons-$PKG_VER/VERSION.xsl && + + install -m644 -D README \ + $PKG_DEST/usr/share/doc/docbook-xsl-nons-$PKG_VER/README.txt && + install -m644 RELEASE-NOTES* NEWS* \ + $PKG_DEST/usr/share/doc/docbook-xsl-nons-$PKG_VER + + + } + +postinstall () { + if [ ! -d /etc/xml ]; then install -m755 -d /etc/xml; fi && + if [ ! -f /etc/xml/catalog ]; then + xmlcatalog --noout --create /etc/xml/catalog + fi && + + xmlcatalog --noout --add "rewriteSystem" \ + "https://cdn.docbook.org/release/xsl-nons/1.79.2" \ + "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ + /etc/xml/catalog && + + xmlcatalog --noout --add "rewriteURI" \ + "https://cdn.docbook.org/release/xsl-nons/1.79.2" \ + "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ + /etc/xml/catalog && + + xmlcatalog --noout --add "rewriteSystem" \ + "https://cdn.docbook.org/release/xsl-nons/current" \ + "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ + /etc/xml/catalog && + + xmlcatalog --noout --add "rewriteURI" \ + "https://cdn.docbook.org/release/xsl-nons/current" \ + "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ + /etc/xml/catalog && + + xmlcatalog --noout --add "rewriteSystem" \ + "http://docbook.sourceforge.net/release/xsl/current" \ + "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ + /etc/xml/catalog && + + xmlcatalog --noout --add "rewriteURI" \ + "http://docbook.sourceforge.net/release/xsl/current" \ + "/usr/share/xml/docbook/xsl-stylesheets-nons-1.79.2" \ + /etc/xml/catalog +} + diff --git a/repo/devel/docbook4-xml.xibuild b/repo/devel/docbook4-xml.xibuild deleted file mode 100644 index 36faa98..0000000 --- a/repo/devel/docbook4-xml.xibuild +++ /dev/null @@ -1,104 +0,0 @@ -#!/bin/sh - -MAKEDEPS="unzip" -DEPS="libxml2 sgml-common" - -PKG_VER=4.5 -SOURCE=https://www.docbook.org/xml/$PKG_VER/docbook-xml-$PKG_VER.zip -DESC="A widely used XML scheme for writing documentation and help" - -VERSIONS="4.5 4.4 4.3 4.2 4.1" - -ADDITIONAL=" - https://www.docbook.org/xml/4.4/docbook-xml-4.4.zip - https://www.docbook.org/xml/4.3/docbook-xml-4.3.zip - https://www.docbook.org/xml/4.2/docbook-xml-4.2.zip - https://www.docbook.org/xml/4.1/docbook-xml-4.1.zip -" - -package () { - for v in $VERSIONS; do - mkdir docbook-xml-$v - cd docbook-xml-$v - unzip -o ../docbook-xml-$v.zip - install -m755 -d $PKG_DEST/usr/share/xml/docbook/xml-dtd-$v && - install -m755 -d $PKG_DEST/etc/xml && - chown -R root:root . && - cp -af docbook.cat *.dtd ent/ *.mod \ - $PKG_DEST/usr/share/xml/docbook/xml-dtd-$v - - cd .. - done -} - -postinstall () { - for v in $VERSIONS; do - if [ ! -e /etc/xml/docbook ]; then - xmlcatalog --noout --create /etc/xml/docbook - fi - xmlcatalog --noout --add "public" \ - "-//OASIS//DTD DocBook XML V$v//EN" \ - "http://www.oasis-open.org/docbook/xml/$v/docbookx.dtd" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//DTD DocBook XML CALS Table Model V$v//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-$v/calstblx.dtd" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//DTD XML Exchange Table Model 19990315//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-$v/soextblx.dtd" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ELEMENTS DocBook XML Information Pool V$v//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-$v/dbpoolx.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ELEMENTS DocBook XML Document Hierarchy V$v//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-$v/dbhierx.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ELEMENTS DocBook XML HTML Tables V$v//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-$v/htmltblx.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ENTITIES DocBook XML Notations V$v//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-$v/dbnotnx.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ENTITIES DocBook XML Character Entities V$v//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-$v/dbcentx.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "public" \ - "-//OASIS//ENTITIES DocBook XML Additional General Entities V$v//EN" \ - "file:///usr/share/xml/docbook/xml-dtd-$v/dbgenent.mod" \ - /etc/xml/docbook && - xmlcatalog --noout --add "rewriteSystem" \ - "http://www.oasis-open.org/docbook/xml/$v" \ - "file:///usr/share/xml/docbook/xml-dtd-$v" \ - /etc/xml/docbook && - xmlcatalog --noout --add "rewriteURI" \ - "http://www.oasis-open.org/docbook/xml/$v" \ - "file:///usr/share/xml/docbook/xml-dtd-$v" \ - /etc/xml/docbook - if [ ! -e /etc/xml/catalog ]; then - xmlcatalog --noout --create /etc/xml/catalog - fi - xmlcatalog --noout --add "delegatePublic" \ - "-//OASIS//ENTITIES DocBook XML" \ - "file:///etc/xml/docbook" \ - /etc/xml/catalog && - xmlcatalog --noout --add "delegatePublic" \ - "-//OASIS//DTD DocBook XML" \ - "file:///etc/xml/docbook" \ - /etc/xml/catalog && - xmlcatalog --noout --add "delegateSystem" \ - "http://www.oasis-open.org/docbook/" \ - "file:///etc/xml/docbook" \ - /etc/xml/catalog && - xmlcatalog --noout --add "delegateURI" \ - "http://www.oasis-open.org/docbook/" \ - "file:///etc/xml/docbook" \ - /etc/xml/catalog - done -} - diff --git a/repo/devel/docbook4-xml/docbook4-xml.xibuild b/repo/devel/docbook4-xml/docbook4-xml.xibuild new file mode 100644 index 0000000..36faa98 --- /dev/null +++ b/repo/devel/docbook4-xml/docbook4-xml.xibuild @@ -0,0 +1,104 @@ +#!/bin/sh + +MAKEDEPS="unzip" +DEPS="libxml2 sgml-common" + +PKG_VER=4.5 +SOURCE=https://www.docbook.org/xml/$PKG_VER/docbook-xml-$PKG_VER.zip +DESC="A widely used XML scheme for writing documentation and help" + +VERSIONS="4.5 4.4 4.3 4.2 4.1" + +ADDITIONAL=" + https://www.docbook.org/xml/4.4/docbook-xml-4.4.zip + https://www.docbook.org/xml/4.3/docbook-xml-4.3.zip + https://www.docbook.org/xml/4.2/docbook-xml-4.2.zip + https://www.docbook.org/xml/4.1/docbook-xml-4.1.zip +" + +package () { + for v in $VERSIONS; do + mkdir docbook-xml-$v + cd docbook-xml-$v + unzip -o ../docbook-xml-$v.zip + install -m755 -d $PKG_DEST/usr/share/xml/docbook/xml-dtd-$v && + install -m755 -d $PKG_DEST/etc/xml && + chown -R root:root . && + cp -af docbook.cat *.dtd ent/ *.mod \ + $PKG_DEST/usr/share/xml/docbook/xml-dtd-$v + + cd .. + done +} + +postinstall () { + for v in $VERSIONS; do + if [ ! -e /etc/xml/docbook ]; then + xmlcatalog --noout --create /etc/xml/docbook + fi + xmlcatalog --noout --add "public" \ + "-//OASIS//DTD DocBook XML V$v//EN" \ + "http://www.oasis-open.org/docbook/xml/$v/docbookx.dtd" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//DTD DocBook XML CALS Table Model V$v//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-$v/calstblx.dtd" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//DTD XML Exchange Table Model 19990315//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-$v/soextblx.dtd" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ELEMENTS DocBook XML Information Pool V$v//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-$v/dbpoolx.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ELEMENTS DocBook XML Document Hierarchy V$v//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-$v/dbhierx.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ELEMENTS DocBook XML HTML Tables V$v//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-$v/htmltblx.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ENTITIES DocBook XML Notations V$v//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-$v/dbnotnx.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ENTITIES DocBook XML Character Entities V$v//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-$v/dbcentx.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "public" \ + "-//OASIS//ENTITIES DocBook XML Additional General Entities V$v//EN" \ + "file:///usr/share/xml/docbook/xml-dtd-$v/dbgenent.mod" \ + /etc/xml/docbook && + xmlcatalog --noout --add "rewriteSystem" \ + "http://www.oasis-open.org/docbook/xml/$v" \ + "file:///usr/share/xml/docbook/xml-dtd-$v" \ + /etc/xml/docbook && + xmlcatalog --noout --add "rewriteURI" \ + "http://www.oasis-open.org/docbook/xml/$v" \ + "file:///usr/share/xml/docbook/xml-dtd-$v" \ + /etc/xml/docbook + if [ ! -e /etc/xml/catalog ]; then + xmlcatalog --noout --create /etc/xml/catalog + fi + xmlcatalog --noout --add "delegatePublic" \ + "-//OASIS//ENTITIES DocBook XML" \ + "file:///etc/xml/docbook" \ + /etc/xml/catalog && + xmlcatalog --noout --add "delegatePublic" \ + "-//OASIS//DTD DocBook XML" \ + "file:///etc/xml/docbook" \ + /etc/xml/catalog && + xmlcatalog --noout --add "delegateSystem" \ + "http://www.oasis-open.org/docbook/" \ + "file:///etc/xml/docbook" \ + /etc/xml/catalog && + xmlcatalog --noout --add "delegateURI" \ + "http://www.oasis-open.org/docbook/" \ + "file:///etc/xml/docbook" \ + /etc/xml/catalog + done +} + diff --git a/repo/devel/expect.xibuild b/repo/devel/expect.xibuild deleted file mode 100644 index c2dd0d8..0000000 --- a/repo/devel/expect.xibuild +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make" -DEPS="tcl" - -PKG_VER=5.45.4 -SOURCE=https://sourceforge.net/projects/expect/files/Expect/$PKG_VER/expect$PKG_VER.tar.gz/download -DESC="tools for automating interactive applications" - -build () { - # note: --with-tcl, we might want to make a way to use the tcl that we've compiled in another package - ./configure --prefix=/usr --with-tcl=/usr/lib --enable-shared --mandir=/usr/share/man --with-tclinclude=/usr/include - make -} - -check () { - make test -} - -package () { - make DESTDIR=$PKG_DEST install - cp libexpect*.so $PKG_DEST/usr/lib -} - - diff --git a/repo/devel/expect/expect.xibuild b/repo/devel/expect/expect.xibuild new file mode 100644 index 0000000..c2dd0d8 --- /dev/null +++ b/repo/devel/expect/expect.xibuild @@ -0,0 +1,25 @@ +#!/bin/sh + +MAKEDEPS="make" +DEPS="tcl" + +PKG_VER=5.45.4 +SOURCE=https://sourceforge.net/projects/expect/files/Expect/$PKG_VER/expect$PKG_VER.tar.gz/download +DESC="tools for automating interactive applications" + +build () { + # note: --with-tcl, we might want to make a way to use the tcl that we've compiled in another package + ./configure --prefix=/usr --with-tcl=/usr/lib --enable-shared --mandir=/usr/share/man --with-tclinclude=/usr/include + make +} + +check () { + make test +} + +package () { + make DESTDIR=$PKG_DEST install + cp libexpect*.so $PKG_DEST/usr/lib +} + + diff --git a/repo/devel/flex.xibuild b/repo/devel/flex.xibuild deleted file mode 100644 index abf55f4..0000000 --- a/repo/devel/flex.xibuild +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make help2man" -DEPS="musl m4 sh" - -PKG_VER=2.6.4 -SOURCE=https://github.com/westes/flex/releases/download/v$PKG_VER/flex-$PKG_VER.tar.gz -DESC="a utility for generating programs that recognize patterns in text" - -build () { - ./configure --prefix=/usr --docdir=/usr/share/doc/flex --disable-static - make -} - -check () { - make check -} - -package () { - make DESTDIR=$PKG_DEST install - ln -s flex $PKG_DEST/usr/bin/lex -} - - diff --git a/repo/devel/flex/flex.xibuild b/repo/devel/flex/flex.xibuild new file mode 100644 index 0000000..abf55f4 --- /dev/null +++ b/repo/devel/flex/flex.xibuild @@ -0,0 +1,24 @@ +#!/bin/sh + +MAKEDEPS="make help2man" +DEPS="musl m4 sh" + +PKG_VER=2.6.4 +SOURCE=https://github.com/westes/flex/releases/download/v$PKG_VER/flex-$PKG_VER.tar.gz +DESC="a utility for generating programs that recognize patterns in text" + +build () { + ./configure --prefix=/usr --docdir=/usr/share/doc/flex --disable-static + make +} + +check () { + make check +} + +package () { + make DESTDIR=$PKG_DEST install + ln -s flex $PKG_DEST/usr/bin/lex +} + + diff --git a/repo/devel/gcc.xibuild b/repo/devel/gcc.xibuild deleted file mode 100644 index e0176cb..0000000 --- a/repo/devel/gcc.xibuild +++ /dev/null @@ -1,193 +0,0 @@ -#!/bin/sh - -MAKEDEPS="grep make dejagnu flex" -DEPS="zstd musl binutils mpc mpfr gmp" - - -PKG_VER=11.2.0 -SOURCE=https://ftp.gnu.org/gnu/gcc/gcc-$PKG_VER/gcc-$PKG_VER.tar.xz - -ISL_VER=0.24 -PATCH_SRC="https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/patches/gcc-alpine" - -ADDITIONAL=" - https://libisl.sourceforge.io/isl-$ISL_VER.tar.xz - - $PATCH_SRC/0001-posix_memalign.patch - $PATCH_SRC/0003-Turn-on-Wl-z-relro-z-now-by-default.patch - $PATCH_SRC/0004-Turn-on-D_FORTIFY_SOURCE-2-by-default-for-C-C-ObjC-O.patch - $PATCH_SRC/0006-Enable-Wformat-and-Wformat-security-by-default.patch - $PATCH_SRC/0007-Enable-Wtrampolines-by-default.patch - $PATCH_SRC/0009-Ensure-that-msgfmt-doesn-t-encounter-problems-during.patch - $PATCH_SRC/0010-Don-t-declare-asprintf-if-defined-as-a-macro.patch - $PATCH_SRC/0012-libitm-disable-FORTIFY.patch - $PATCH_SRC/0013-libgcc_s.patch - $PATCH_SRC/0015-libffi-use-__linux__-instead-of-__gnu_linux__-for-mu.patch - $PATCH_SRC/0016-dlang-update-zlib-binding.patch - $PATCH_SRC/0017-dlang-fix-fcntl-on-mips-add-libucontext-dep.patch - $PATCH_SRC/0018-ada-fix-shared-linking.patch - $PATCH_SRC/0019-build-fix-CXXFLAGS_FOR_BUILD-passing.patch - $PATCH_SRC/0020-add-fortify-headers-paths.patch - $PATCH_SRC/0023-Pure-64-bit-MIPS.patch - $PATCH_SRC/0024-use-pure-64-bit-configuration-where-appropriate.patch - $PATCH_SRC/0025-always-build-libgcc_eh.a.patch - $PATCH_SRC/0027-ada-musl-support-fixes.patch - $PATCH_SRC/0028-gcc-go-Use-_off_t-type-instead-of-_loff_t.patch - $PATCH_SRC/0029-gcc-go-Don-t-include-sys-user.h.patch - $PATCH_SRC/0030-gcc-go-Fix-ucontext_t-on-PPC64.patch - $PATCH_SRC/0031-gcc-go-Fix-handling-of-signal-34-on-musl.patch - $PATCH_SRC/0032-gcc-go-Use-int64-type-as-offset-argument-for-mmap.patch - $PATCH_SRC/0035-gcc-go-Prefer-_off_t-over-_off64_t.patch - $PATCH_SRC/0036-gcc-go-undef-SETCONTEXT_CLOBBERS_TLS-in-proc.c.patch - $PATCH_SRC/0037-gcc-go-link-to-libucontext.patch - $PATCH_SRC/0038-gcc-go-Disable-printing-of-unaccessible-ppc64-struct.patch - $PATCH_SRC/0041-Use-generic-errstr.go-implementation-on-musl.patch - $PATCH_SRC/0042-Disable-ssp-on-nostdlib-nodefaultlibs-and-ffreestand.patch - $PATCH_SRC/0043-configure-Add-enable-autolink-libatomic-use-in-LINK_.patch - $PATCH_SRC/0021-Alpine-musl-package-provides-libssp_nonshared.a.-We-.patch - - - https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/files/musl/getconf.1 - https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/files/musl/getconf.c - https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/files/musl/getent.1 - https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/files/musl/getent.c - https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/files/musl/iconv.c -" - -DESC="The GNU Compiler Collection - C and C++ frontends" - -prepare () { - export languages="c,c++,lto" - - case $(uname -m) in - x86_64) export TRUPLE="x86_64-linux-musl" - export EXTRA_CONFIG=" --with-arch=x86-64" - ;; - i686) export TRUPLE="i686-linux-musl" - export EXTRA_CONFIG=" --with-arch=pentium3 --with-tune=pentium-m" - ;; - armv7l) export TRUPLE="armv7l-linux-musleabihf" - export EXTRA_CONFIG=" --with-arch=armv7-a --with-tune=generic-armv7-a --with-fpu=vfpv3-d16 --with-float=hard --with-abi=aapcs-linux --with-mode=thumb" - ;; - armv6l) export TRUPLE="armv6l-linux-musleabihf" - export EXTRA_CONFIG=" --with-arch=armv6zk --with-tune=arm1176jzf-s --with-fpu=vfp --with-float=hard --with-abi=aapcs-linux" - ;; - aarch64) export TRUPLE="aarch64-linux-musleabihf" - export EXTRA_CONFIG=" --with-arch=armv8-a --with-abi=lp64 --enable-fix-cortex-a53-835769 --enable-fix-cortex-a53-843419" - sed -i '/m64=/s/lib64/lib/' gcc/config/aarch64/t-aarch64-linux - ;; - esac - - tar xf isl-$ISL_VER.tar.xz - mv isl-$ISL_VER isl - - apply_patches -} - -build () { - mkdir build - cd build - - export NOFF="--disable-libstdcxx-pch - --disable-nls - --disable-multilib - --disable-bootstrap - --disable-symvers - --disable-libsanitizer - --disable-libmpx - --disable-libmudflap - --disable-fixed-point - --disable-sjlj-exceptions - --disable-werror " - - # Enable graphite - export XCONFIG="--with-ppl=yes --with-cloog=yes " - - # Enable features for x86_64 - export XTRA86="--with-arch=x86-64 " - - # Enable features - export FON="--enable-threads=posix - --enable-clocale=generic - --enable-tls - --enable-libstdcxx-time - --enable-fully-dynamic-string - --enable-linker-build-id - --enable-checking=release - --enable-cloog-backend - --enable-__cxa_atexit - --enable-lto - --enable-plugins - --with-system-zlib - --with-linker-hash-style=gnu " - #export FON+="--with-isl " - - # Configure source - SED=sed libat_cv_have_ifunc=no \ - ../configure --prefix=/usr \ - --mandir=/usr/share/man \ - --infodir=/usr/share/info \ - --with-pkgversion="XiLinux $PKG_VER" \ - --enable-checking=release \ - --disable-fixed-point \ - --disable-libstdcxx-pch \ - --disable-multilib \ - --disable-nls \ - --disable-werror \ - --enable-__cxa_atexit \ - --enable-default-pie \ - --enable-cloog-backend \ - --enable-languages=$languages \ - --with-system-zlib \ - --target=${TRUPLE} \ - $NOFF $XTRA86 $XCONFIG $FON && - - make && - - cd .. && - cc getent.c -o getent && - cc getconf.c -o getconf && - cc iconv.c -o iconv -} - -check () { - cd build - if id -u tester; then - chown -R tester . - su tester -c "PATH=$PATH make $MAKEFLAGS -k check" || true - ../contrib/test_summary | grep -A7 Summ || true - fi - cd .. -} - - -package () { - install -dm755 $PKG_DEST/usr/bin - install -dm755 $PKG_DEST/usr/share/man - install -dm755 $PKG_DEST/usr/lib/bfd-plugins - - cd build - make DESTDIR=$PKG_DEST install - cd .. - - cp getent $PKG_DEST/usr/bin/ - cp getconf $PKG_DEST/usr/bin/ - cp iconv $PKG_DEST/usr/bin/ - cp getent.1 $PKG_DEST/usr/share/man/man1/ - cp getconf.1 $PKG_DEST/usr/share/man/man1/ - - ln -s ../bin/cpp $PKG_DEST/usr/lib - ln -s gcc $PKG_DEST/usr/bin/cc - - ln -sf ../../libexec/gcc/$(gcc -dumpmachine)/$PKG_VER/liblto_plugin.so \ - $PKG_VER/usr/lib/bfd-plugins/ - - mkdir -p $PKG_DEST/usr/share/gdb/auto-load/usr/lib - #mv $PKG_DEST/usr/lib/*gdb.py $PKG_DEST/usr/share/gdb/auto-load/usr/lib - - for p in gcov gcc-ar gcc gcc-ranlib c++ g++ gcc-nm lto-dump gcov-tools gcov-dump cpp; do - ln -s $TRUPLE-$p $PKG_DEST/usr/bin/$p - done - - -} diff --git a/repo/devel/gcc/gcc.xibuild b/repo/devel/gcc/gcc.xibuild new file mode 100644 index 0000000..e0176cb --- /dev/null +++ b/repo/devel/gcc/gcc.xibuild @@ -0,0 +1,193 @@ +#!/bin/sh + +MAKEDEPS="grep make dejagnu flex" +DEPS="zstd musl binutils mpc mpfr gmp" + + +PKG_VER=11.2.0 +SOURCE=https://ftp.gnu.org/gnu/gcc/gcc-$PKG_VER/gcc-$PKG_VER.tar.xz + +ISL_VER=0.24 +PATCH_SRC="https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/patches/gcc-alpine" + +ADDITIONAL=" + https://libisl.sourceforge.io/isl-$ISL_VER.tar.xz + + $PATCH_SRC/0001-posix_memalign.patch + $PATCH_SRC/0003-Turn-on-Wl-z-relro-z-now-by-default.patch + $PATCH_SRC/0004-Turn-on-D_FORTIFY_SOURCE-2-by-default-for-C-C-ObjC-O.patch + $PATCH_SRC/0006-Enable-Wformat-and-Wformat-security-by-default.patch + $PATCH_SRC/0007-Enable-Wtrampolines-by-default.patch + $PATCH_SRC/0009-Ensure-that-msgfmt-doesn-t-encounter-problems-during.patch + $PATCH_SRC/0010-Don-t-declare-asprintf-if-defined-as-a-macro.patch + $PATCH_SRC/0012-libitm-disable-FORTIFY.patch + $PATCH_SRC/0013-libgcc_s.patch + $PATCH_SRC/0015-libffi-use-__linux__-instead-of-__gnu_linux__-for-mu.patch + $PATCH_SRC/0016-dlang-update-zlib-binding.patch + $PATCH_SRC/0017-dlang-fix-fcntl-on-mips-add-libucontext-dep.patch + $PATCH_SRC/0018-ada-fix-shared-linking.patch + $PATCH_SRC/0019-build-fix-CXXFLAGS_FOR_BUILD-passing.patch + $PATCH_SRC/0020-add-fortify-headers-paths.patch + $PATCH_SRC/0023-Pure-64-bit-MIPS.patch + $PATCH_SRC/0024-use-pure-64-bit-configuration-where-appropriate.patch + $PATCH_SRC/0025-always-build-libgcc_eh.a.patch + $PATCH_SRC/0027-ada-musl-support-fixes.patch + $PATCH_SRC/0028-gcc-go-Use-_off_t-type-instead-of-_loff_t.patch + $PATCH_SRC/0029-gcc-go-Don-t-include-sys-user.h.patch + $PATCH_SRC/0030-gcc-go-Fix-ucontext_t-on-PPC64.patch + $PATCH_SRC/0031-gcc-go-Fix-handling-of-signal-34-on-musl.patch + $PATCH_SRC/0032-gcc-go-Use-int64-type-as-offset-argument-for-mmap.patch + $PATCH_SRC/0035-gcc-go-Prefer-_off_t-over-_off64_t.patch + $PATCH_SRC/0036-gcc-go-undef-SETCONTEXT_CLOBBERS_TLS-in-proc.c.patch + $PATCH_SRC/0037-gcc-go-link-to-libucontext.patch + $PATCH_SRC/0038-gcc-go-Disable-printing-of-unaccessible-ppc64-struct.patch + $PATCH_SRC/0041-Use-generic-errstr.go-implementation-on-musl.patch + $PATCH_SRC/0042-Disable-ssp-on-nostdlib-nodefaultlibs-and-ffreestand.patch + $PATCH_SRC/0043-configure-Add-enable-autolink-libatomic-use-in-LINK_.patch + $PATCH_SRC/0021-Alpine-musl-package-provides-libssp_nonshared.a.-We-.patch + + + https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/files/musl/getconf.1 + https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/files/musl/getconf.c + https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/files/musl/getent.1 + https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/files/musl/getent.c + https://raw.githubusercontent.com/dslm4515/Musl-LFS/master/files/musl/iconv.c +" + +DESC="The GNU Compiler Collection - C and C++ frontends" + +prepare () { + export languages="c,c++,lto" + + case $(uname -m) in + x86_64) export TRUPLE="x86_64-linux-musl" + export EXTRA_CONFIG=" --with-arch=x86-64" + ;; + i686) export TRUPLE="i686-linux-musl" + export EXTRA_CONFIG=" --with-arch=pentium3 --with-tune=pentium-m" + ;; + armv7l) export TRUPLE="armv7l-linux-musleabihf" + export EXTRA_CONFIG=" --with-arch=armv7-a --with-tune=generic-armv7-a --with-fpu=vfpv3-d16 --with-float=hard --with-abi=aapcs-linux --with-mode=thumb" + ;; + armv6l) export TRUPLE="armv6l-linux-musleabihf" + export EXTRA_CONFIG=" --with-arch=armv6zk --with-tune=arm1176jzf-s --with-fpu=vfp --with-float=hard --with-abi=aapcs-linux" + ;; + aarch64) export TRUPLE="aarch64-linux-musleabihf" + export EXTRA_CONFIG=" --with-arch=armv8-a --with-abi=lp64 --enable-fix-cortex-a53-835769 --enable-fix-cortex-a53-843419" + sed -i '/m64=/s/lib64/lib/' gcc/config/aarch64/t-aarch64-linux + ;; + esac + + tar xf isl-$ISL_VER.tar.xz + mv isl-$ISL_VER isl + + apply_patches +} + +build () { + mkdir build + cd build + + export NOFF="--disable-libstdcxx-pch + --disable-nls + --disable-multilib + --disable-bootstrap + --disable-symvers + --disable-libsanitizer + --disable-libmpx + --disable-libmudflap + --disable-fixed-point + --disable-sjlj-exceptions + --disable-werror " + + # Enable graphite + export XCONFIG="--with-ppl=yes --with-cloog=yes " + + # Enable features for x86_64 + export XTRA86="--with-arch=x86-64 " + + # Enable features + export FON="--enable-threads=posix + --enable-clocale=generic + --enable-tls + --enable-libstdcxx-time + --enable-fully-dynamic-string + --enable-linker-build-id + --enable-checking=release + --enable-cloog-backend + --enable-__cxa_atexit + --enable-lto + --enable-plugins + --with-system-zlib + --with-linker-hash-style=gnu " + #export FON+="--with-isl " + + # Configure source + SED=sed libat_cv_have_ifunc=no \ + ../configure --prefix=/usr \ + --mandir=/usr/share/man \ + --infodir=/usr/share/info \ + --with-pkgversion="XiLinux $PKG_VER" \ + --enable-checking=release \ + --disable-fixed-point \ + --disable-libstdcxx-pch \ + --disable-multilib \ + --disable-nls \ + --disable-werror \ + --enable-__cxa_atexit \ + --enable-default-pie \ + --enable-cloog-backend \ + --enable-languages=$languages \ + --with-system-zlib \ + --target=${TRUPLE} \ + $NOFF $XTRA86 $XCONFIG $FON && + + make && + + cd .. && + cc getent.c -o getent && + cc getconf.c -o getconf && + cc iconv.c -o iconv +} + +check () { + cd build + if id -u tester; then + chown -R tester . + su tester -c "PATH=$PATH make $MAKEFLAGS -k check" || true + ../contrib/test_summary | grep -A7 Summ || true + fi + cd .. +} + + +package () { + install -dm755 $PKG_DEST/usr/bin + install -dm755 $PKG_DEST/usr/share/man + install -dm755 $PKG_DEST/usr/lib/bfd-plugins + + cd build + make DESTDIR=$PKG_DEST install + cd .. + + cp getent $PKG_DEST/usr/bin/ + cp getconf $PKG_DEST/usr/bin/ + cp iconv $PKG_DEST/usr/bin/ + cp getent.1 $PKG_DEST/usr/share/man/man1/ + cp getconf.1 $PKG_DEST/usr/share/man/man1/ + + ln -s ../bin/cpp $PKG_DEST/usr/lib + ln -s gcc $PKG_DEST/usr/bin/cc + + ln -sf ../../libexec/gcc/$(gcc -dumpmachine)/$PKG_VER/liblto_plugin.so \ + $PKG_VER/usr/lib/bfd-plugins/ + + mkdir -p $PKG_DEST/usr/share/gdb/auto-load/usr/lib + #mv $PKG_DEST/usr/lib/*gdb.py $PKG_DEST/usr/share/gdb/auto-load/usr/lib + + for p in gcov gcc-ar gcc gcc-ranlib c++ g++ gcc-nm lto-dump gcov-tools gcov-dump cpp; do + ln -s $TRUPLE-$p $PKG_DEST/usr/bin/$p + done + + +} diff --git a/repo/devel/gdb.xibuild b/repo/devel/gdb.xibuild deleted file mode 100644 index 31d9b7c..0000000 --- a/repo/devel/gdb.xibuild +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make expat guile ncurses python xz texinfo" -DEPS="python-six doxygen gcc guile rustc python valgrind systemtap" - -PKG_VER=11.2 -SOURCE=https://ftp.gnu.org/gnu/gdb/gdb-$PKG_VER.tar.xz -DESC="The GNU debugger" - -build () { - mkdir build && - cd build && - - ../configure --prefix=/usr \ - --with-system-readline \ - --with-python=/usr/bin/python3 && - make - -} - -#check () { -# cd gdb/testsuite && -# make site.exp && -# echo "set gdb_test_timeout 120" >> site.exp && -# runtest -# cd ../.. -# -#} - -package () { - make -C gdb DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/gdb/gdb.xibuild b/repo/devel/gdb/gdb.xibuild new file mode 100644 index 0000000..31d9b7c --- /dev/null +++ b/repo/devel/gdb/gdb.xibuild @@ -0,0 +1,32 @@ +#!/bin/sh + +MAKEDEPS="make expat guile ncurses python xz texinfo" +DEPS="python-six doxygen gcc guile rustc python valgrind systemtap" + +PKG_VER=11.2 +SOURCE=https://ftp.gnu.org/gnu/gdb/gdb-$PKG_VER.tar.xz +DESC="The GNU debugger" + +build () { + mkdir build && + cd build && + + ../configure --prefix=/usr \ + --with-system-readline \ + --with-python=/usr/bin/python3 && + make + +} + +#check () { +# cd gdb/testsuite && +# make site.exp && +# echo "set gdb_test_timeout 120" >> site.exp && +# runtest +# cd ../.. +# +#} + +package () { + make -C gdb DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/git.xibuild b/repo/devel/git.xibuild deleted file mode 100644 index ab8e273..0000000 --- a/repo/devel/git.xibuild +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh - -MAKEDEPS="grep python make xmlto cmake" -DEPS="curl perl openssl pcre2 grep shadow zlib openssh" - -PKG_VER=2.34.1 -SOURCE=https://www.kernel.org/pub/software/scm/git/git-$PKG_VER.tar.xz -DESC="The free and open source, distributed version control system" - -build () { - ./configure --prefix=/usr \ - --with-gitconfig=/etc/gitconfig \ - --with-python=python3 && - make -} - -package () { - make perllibdir=/usr/lib/perl5/5.34/site_perl DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/git/git.xibuild b/repo/devel/git/git.xibuild new file mode 100644 index 0000000..ab8e273 --- /dev/null +++ b/repo/devel/git/git.xibuild @@ -0,0 +1,19 @@ +#!/bin/sh + +MAKEDEPS="grep python make xmlto cmake" +DEPS="curl perl openssl pcre2 grep shadow zlib openssh" + +PKG_VER=2.34.1 +SOURCE=https://www.kernel.org/pub/software/scm/git/git-$PKG_VER.tar.xz +DESC="The free and open source, distributed version control system" + +build () { + ./configure --prefix=/usr \ + --with-gitconfig=/etc/gitconfig \ + --with-python=python3 && + make +} + +package () { + make perllibdir=/usr/lib/perl5/5.34/site_perl DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/go.xibuild b/repo/devel/go.xibuild deleted file mode 100644 index 9a5f1b7..0000000 --- a/repo/devel/go.xibuild +++ /dev/null @@ -1,67 +0,0 @@ -#!/bin/sh - -# Ensure we have gcc-go -MAKEDEPS="make gcc" -DEPS="" - -PKG_VER=1.17.7 -SOURCE=https://go.dev/dl/go$PKG_VER.src.tar.gz - -BOOTSTRAP="go1.4-bootstrap-20171003" -ADDITIONAL=" - https://dl.google.com/go/$BOOTSTRAP.tar.gz -" - -DESC="Core compiler tools for the Go programming language" - -prepare () { - export TMPDIR=/tmp - tar -xvf $BOOTSTRAP.tar.gz - mv go $BOOTSTRAP -} - -build () { - export sourceroot=$(pwd) - export GOARCH=amd64 - export GOAMD64=v1 # make sure we're building for the right x86-64 version - export GOOS="linux" - - cd $BOOTSTRAP - cd src - echo "~~~~BUILDING BOOTSTRAP" - CGO_ENABLED=0 ./make.bash -v - - cd $sourceroot - export GOROOT_FINAL=/usr/lib/go - export GOROOT_BOOTSTRAP="$(pwd)/$BOOTSTRAP" - - echo "~~~~BUILDING GOLANG" - cd src - if [ ! -z "${GOROOT_BOOTSTRAP}" ]; then - ./bootstrap.bash -v - fi - ./make.bash -v - cd .. -} - -package () { - install -d "$PKG_DEST/usr/bin" "$PKG_DEST/usr/lib/go" "$PKG_DEST/usr/share/doc/go" \ - "$PKG_DEST/usr/lib/go/pkg/linux_amd64_"dynlink \ - "$PKG_DEST/usr/lib/go/pkg/linux_amd64_"race - - cp -a bin pkg src lib misc api test "$PKG_DEST/usr/lib/go" - cp -r doc/* "$PKG_DEST/usr/share/doc/go" - - ln -sf /usr/lib/go/bin/go "$PKG_DEST/usr/bin/go" - ln -sf /usr/lib/go/bin/gofmt "$PKG_DEST/usr/bin/gofmt" - ln -sf /usr/share/doc/go "$PKG_DEST/usr/lib/go/doc" - - install -Dm644 VERSION "$PKG_DEST/usr/lib/go/VERSION" - - rm -rf "$PKG_DEST/usr/lib/go/pkg/bootstrap" "$PKG_DEST/usr/lib/go/pkg/tool/*/api" - - # TODO: Figure out if really needed - rm -rf "$PKG_DEST"/usr/lib/go/pkg/obj/go-build/* - - install -Dm644 LICENSE "$PKG_DEST/usr/share/licenses/$pkgname/LICENSE" -} diff --git a/repo/devel/go/go.xibuild b/repo/devel/go/go.xibuild new file mode 100644 index 0000000..9a5f1b7 --- /dev/null +++ b/repo/devel/go/go.xibuild @@ -0,0 +1,67 @@ +#!/bin/sh + +# Ensure we have gcc-go +MAKEDEPS="make gcc" +DEPS="" + +PKG_VER=1.17.7 +SOURCE=https://go.dev/dl/go$PKG_VER.src.tar.gz + +BOOTSTRAP="go1.4-bootstrap-20171003" +ADDITIONAL=" + https://dl.google.com/go/$BOOTSTRAP.tar.gz +" + +DESC="Core compiler tools for the Go programming language" + +prepare () { + export TMPDIR=/tmp + tar -xvf $BOOTSTRAP.tar.gz + mv go $BOOTSTRAP +} + +build () { + export sourceroot=$(pwd) + export GOARCH=amd64 + export GOAMD64=v1 # make sure we're building for the right x86-64 version + export GOOS="linux" + + cd $BOOTSTRAP + cd src + echo "~~~~BUILDING BOOTSTRAP" + CGO_ENABLED=0 ./make.bash -v + + cd $sourceroot + export GOROOT_FINAL=/usr/lib/go + export GOROOT_BOOTSTRAP="$(pwd)/$BOOTSTRAP" + + echo "~~~~BUILDING GOLANG" + cd src + if [ ! -z "${GOROOT_BOOTSTRAP}" ]; then + ./bootstrap.bash -v + fi + ./make.bash -v + cd .. +} + +package () { + install -d "$PKG_DEST/usr/bin" "$PKG_DEST/usr/lib/go" "$PKG_DEST/usr/share/doc/go" \ + "$PKG_DEST/usr/lib/go/pkg/linux_amd64_"dynlink \ + "$PKG_DEST/usr/lib/go/pkg/linux_amd64_"race + + cp -a bin pkg src lib misc api test "$PKG_DEST/usr/lib/go" + cp -r doc/* "$PKG_DEST/usr/share/doc/go" + + ln -sf /usr/lib/go/bin/go "$PKG_DEST/usr/bin/go" + ln -sf /usr/lib/go/bin/gofmt "$PKG_DEST/usr/bin/gofmt" + ln -sf /usr/share/doc/go "$PKG_DEST/usr/lib/go/doc" + + install -Dm644 VERSION "$PKG_DEST/usr/lib/go/VERSION" + + rm -rf "$PKG_DEST/usr/lib/go/pkg/bootstrap" "$PKG_DEST/usr/lib/go/pkg/tool/*/api" + + # TODO: Figure out if really needed + rm -rf "$PKG_DEST"/usr/lib/go/pkg/obj/go-build/* + + install -Dm644 LICENSE "$PKG_DEST/usr/share/licenses/$pkgname/LICENSE" +} diff --git a/repo/devel/gtk-doc.xibuild b/repo/devel/gtk-doc.xibuild deleted file mode 100644 index 074eca0..0000000 --- a/repo/devel/gtk-doc.xibuild +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make " -DEPS="docbook4-xml docbook-dtd docbook-xsl itstool libxslt" - -PKG_VER=1.33.2 -SOURCE=https://download.gnome.org/sources/gtk-doc/${PKG_VER%.*}/gtk-doc-$PKG_VER.tar.xz -DESC="Documentation tool for public library API" - -prepare () { - autoreconf -fiv -} -build () { - ./configure --prefix=/usr && - make -} - -package () { - make DESTDIR=$PKG_DEST install -} - - diff --git a/repo/devel/gtk-doc/gtk-doc.xibuild b/repo/devel/gtk-doc/gtk-doc.xibuild new file mode 100644 index 0000000..074eca0 --- /dev/null +++ b/repo/devel/gtk-doc/gtk-doc.xibuild @@ -0,0 +1,22 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="docbook4-xml docbook-dtd docbook-xsl itstool libxslt" + +PKG_VER=1.33.2 +SOURCE=https://download.gnome.org/sources/gtk-doc/${PKG_VER%.*}/gtk-doc-$PKG_VER.tar.xz +DESC="Documentation tool for public library API" + +prepare () { + autoreconf -fiv +} +build () { + ./configure --prefix=/usr && + make +} + +package () { + make DESTDIR=$PKG_DEST install +} + + diff --git a/repo/devel/help2man.xibuild b/repo/devel/help2man.xibuild deleted file mode 100644 index 6d91935..0000000 --- a/repo/devel/help2man.xibuild +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make " -DEPS="sh" - -PKG_VER=1.48.5 -SOURCE=http://mirror.koddos.net/gnu/help2man/help2man-$PKG_VER.tar.xz -DESC="A tool for automatically generating simple manual pages from program output" - -build () { - ./configure --prefix=/usr - make -} - -package () { - make DESTDIR=$PKG_DEST install -} - diff --git a/repo/devel/help2man/help2man.xibuild b/repo/devel/help2man/help2man.xibuild new file mode 100644 index 0000000..6d91935 --- /dev/null +++ b/repo/devel/help2man/help2man.xibuild @@ -0,0 +1,18 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="sh" + +PKG_VER=1.48.5 +SOURCE=http://mirror.koddos.net/gnu/help2man/help2man-$PKG_VER.tar.xz +DESC="A tool for automatically generating simple manual pages from program output" + +build () { + ./configure --prefix=/usr + make +} + +package () { + make DESTDIR=$PKG_DEST install +} + diff --git a/repo/devel/icecream.xibuild b/repo/devel/icecream.xibuild deleted file mode 100644 index 713f16e..0000000 --- a/repo/devel/icecream.xibuild +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh - -MAKEDEPS="python make " -DEPS="gcc python libcap-ng lzo libarchive" - -SOURCE=https://github.com/icecc/icecream/releases/download/1.3.1/icecc-1.3.1.tar.xz - -DESC="A build distribution service based on distcc" - - -build () { - ./configure --prefix=/usr - make -} - - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/icecream/icecream.xibuild b/repo/devel/icecream/icecream.xibuild new file mode 100644 index 0000000..713f16e --- /dev/null +++ b/repo/devel/icecream/icecream.xibuild @@ -0,0 +1,19 @@ +#!/bin/sh + +MAKEDEPS="python make " +DEPS="gcc python libcap-ng lzo libarchive" + +SOURCE=https://github.com/icecc/icecream/releases/download/1.3.1/icecc-1.3.1.tar.xz + +DESC="A build distribution service based on distcc" + + +build () { + ./configure --prefix=/usr + make +} + + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/imake.xibuild b/repo/devel/imake.xibuild deleted file mode 100644 index 2828071..0000000 --- a/repo/devel/imake.xibuild +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh - -NAME="imake" -DESC="X Windows make utility" - -MAKEDEPS="make " -DEPS="musl " - -PKG_VER=1.0.8 -SOURCE="https://ftp.x.org/pub/individual/util/imake-$PKG_VER.tar.bz2" - -build () { - ./configure \ - --prefix=/usr \ - --bindir=/usr/bin \ - --sysconfdir=/etc \ - --disable-static - make -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/imake/imake.xibuild b/repo/devel/imake/imake.xibuild new file mode 100644 index 0000000..2828071 --- /dev/null +++ b/repo/devel/imake/imake.xibuild @@ -0,0 +1,23 @@ +#!/bin/sh + +NAME="imake" +DESC="X Windows make utility" + +MAKEDEPS="make " +DEPS="musl " + +PKG_VER=1.0.8 +SOURCE="https://ftp.x.org/pub/individual/util/imake-$PKG_VER.tar.bz2" + +build () { + ./configure \ + --prefix=/usr \ + --bindir=/usr/bin \ + --sysconfdir=/etc \ + --disable-static + make +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/itstool.xibuild b/repo/devel/itstool.xibuild deleted file mode 100644 index 721c5a7..0000000 --- a/repo/devel/itstool.xibuild +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make " -DEPS="docbook-xml" - -PKG_VER=2.0.7 -SOURCE=http://files.itstool.org/itstool/itstool-2.0.7.tar.bz2 -DESC="Extract messages from XML files and output PO template files" - -build () { - PYTHON=/usr/bin/python3 ./configure --prefix=/usr && - make -} - -package () { - make DESTDIR=$PKG_DEST install -} - - diff --git a/repo/devel/itstool/itstool.xibuild b/repo/devel/itstool/itstool.xibuild new file mode 100644 index 0000000..721c5a7 --- /dev/null +++ b/repo/devel/itstool/itstool.xibuild @@ -0,0 +1,19 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="docbook-xml" + +PKG_VER=2.0.7 +SOURCE=http://files.itstool.org/itstool/itstool-2.0.7.tar.bz2 +DESC="Extract messages from XML files and output PO template files" + +build () { + PYTHON=/usr/bin/python3 ./configure --prefix=/usr && + make +} + +package () { + make DESTDIR=$PKG_DEST install +} + + diff --git a/repo/devel/libexecinfo.xibuild b/repo/devel/libexecinfo.xibuild deleted file mode 100644 index 67e1002..0000000 --- a/repo/devel/libexecinfo.xibuild +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh - -NAME="libexecinfo" -DESC="A quick-n-dirty BSD licensed clone of the GNU libc backtrace facility." - -MAKEDEPS="make " -DEPS="musl " - -PKG_VER=1.1 -SOURCE="http://distcache.freebsd.org/local-distfiles/itetcu/libexecinfo-$PKG_VER.tar.bz2" -ADDITIONAL="30-linux-makefile.patch 20-define-gnu-source.patch 10-execinfo.patch " - -prepare () { - apply_patches -} - -build () { - export CFLAGS="${CFLAGS} -fno-omit-frame-pointer" - make PREFIX=/usr -} - -package () { - install -D -m755 execinfo.h \ - "$PKG_DEST"/usr/include/execinfo.h - install -D -m755 stacktraverse.h \ - "$PKG_DEST"/usr/include/stacktraverse.h - install -D -m755 libexecinfo.so.1 \ - "$PKG_DEST"/usr/lib/libexecinfo.so.1 - ln -s /usr/lib/libexecinfo.so.1 \ - "$PKG_DEST"/usr/lib/libexecinfo.so - -} diff --git a/repo/devel/libexecinfo/10-execinfo.patch b/repo/devel/libexecinfo/10-execinfo.patch new file mode 100644 index 0000000..44db530 --- /dev/null +++ b/repo/devel/libexecinfo/10-execinfo.patch @@ -0,0 +1,64 @@ +--- a/execinfo.c.orig ++++ b/execinfo.c +@@ -69,7 +69,8 @@ + char ** + backtrace_symbols(void *const *buffer, int size) + { +- int i, clen, alen, offset; ++ size_t clen, alen; ++ int i, offset; + char **rval; + char *cp; + Dl_info info; +@@ -78,7 +79,6 @@ + rval = malloc(clen); + if (rval == NULL) + return NULL; +- (char **)cp = &(rval[size]); + for (i = 0; i < size; i++) { + if (dladdr(buffer[i], &info) != 0) { + if (info.dli_sname == NULL) +@@ -92,14 +92,14 @@ + 2 + /* " <" */ + strlen(info.dli_sname) + /* "function" */ + 1 + /* "+" */ +- D10(offset) + /* "offset */ ++ 10 + /* "offset */ + 5 + /* "> at " */ + strlen(info.dli_fname) + /* "filename" */ + 1; /* "\0" */ + rval = realloc_safe(rval, clen + alen); + if (rval == NULL) + return NULL; +- snprintf(cp, alen, "%p <%s+%d> at %s", ++ snprintf((char *) rval + clen, alen, "%p <%s+%d> at %s", + buffer[i], info.dli_sname, offset, info.dli_fname); + } else { + alen = 2 + /* "0x" */ +@@ -108,12 +108,15 @@ + rval = realloc_safe(rval, clen + alen); + if (rval == NULL) + return NULL; +- snprintf(cp, alen, "%p", buffer[i]); ++ snprintf((char *) rval + clen, alen, "%p", buffer[i]); + } +- rval[i] = cp; +- cp += alen; ++ rval[i] = (char *) clen; ++ clen += alen; + } + ++ for (i = 0; i < size; i++) ++ rval[i] += (long) rval; ++ + return rval; + } + +@@ -155,6 +158,6 @@ + return; + snprintf(buf, len, "%p\n", buffer[i]); + } +- write(fd, buf, len - 1); ++ write(fd, buf, strlen(buf)); + } + } diff --git a/repo/devel/libexecinfo/20-define-gnu-source.patch b/repo/devel/libexecinfo/20-define-gnu-source.patch new file mode 100644 index 0000000..7255ecd --- /dev/null +++ b/repo/devel/libexecinfo/20-define-gnu-source.patch @@ -0,0 +1,24 @@ +--- a/execinfo.c.orig ++++ b/execinfo.c +@@ -26,6 +26,7 @@ + * $Id: execinfo.c,v 1.3 2004/07/19 05:21:09 sobomax Exp $ + */ + ++#define _GNU_SOURCE + #include + #include + #include +--- a/stacktraverse.c.orig ++++ b/stacktraverse.c +@@ -1,3 +1,4 @@ ++#define _GNU_SOURCE + #include + + #include "stacktraverse.h" +--- a/test.c.orig ++++ b/test.c +@@ -1,3 +1,4 @@ ++#define _GNU_SOURCE + #include + #include + diff --git a/repo/devel/libexecinfo/30-linux-makefile.patch b/repo/devel/libexecinfo/30-linux-makefile.patch new file mode 100644 index 0000000..6bc8a89 --- /dev/null +++ b/repo/devel/libexecinfo/30-linux-makefile.patch @@ -0,0 +1,44 @@ +--- a/Makefile.orig ++++ b/Makefile +@@ -23,24 +23,25 @@ + # SUCH DAMAGE. + # + # $Id: Makefile,v 1.3 2004/07/19 05:19:55 sobomax Exp $ ++# ++# Linux Makefile by Matt Smith , 2011/01/04 + +-LIB= execinfo ++CC=cc ++AR=ar ++EXECINFO_CFLAGS=$(CFLAGS) -O2 -pipe -fno-strict-aliasing -std=gnu99 -fstack-protector -c ++EXECINFO_LDFLAGS=$(LDFLAGS) + +-SRCS= stacktraverse.c stacktraverse.h execinfo.c execinfo.h ++all: static dynamic + +-INCS= execinfo.h ++static: ++ $(CC) $(EXECINFO_CFLAGS) $(EXECINFO_LDFLAGS) stacktraverse.c ++ $(CC) $(EXECINFO_CFLAGS) $(EXECINFO_LDFLAGS) execinfo.c ++ $(AR) rcs libexecinfo.a stacktraverse.o execinfo.o + +-SHLIB_MAJOR= 1 +-SHLIB_MINOR= 0 ++dynamic: ++ $(CC) -fpic -DPIC $(EXECINFO_CFLAGS) $(EXECINFO_LDFLAGS) stacktraverse.c -o stacktraverse.So ++ $(CC) -fpic -DPIC $(EXECINFO_CFLAGS) $(EXECINFO_LDFLAGS) execinfo.c -o execinfo.So ++ $(CC) -shared -Wl,-soname,libexecinfo.so.1 -o libexecinfo.so.1 stacktraverse.So execinfo.So + +-NOPROFILE= yes +- +-DPADD= ${LIBM} +-LDADD= -lm +- +-#WARNS?= 4 +- +-#stacktraverse.c: gen.py +-# ./gen.py > stacktraverse.c +- +-.include ++clean: ++ rm -rf *.o *.So *.a *.so diff --git a/repo/devel/libexecinfo/libexecinfo.xibuild b/repo/devel/libexecinfo/libexecinfo.xibuild new file mode 100644 index 0000000..67e1002 --- /dev/null +++ b/repo/devel/libexecinfo/libexecinfo.xibuild @@ -0,0 +1,32 @@ +#!/bin/sh + +NAME="libexecinfo" +DESC="A quick-n-dirty BSD licensed clone of the GNU libc backtrace facility." + +MAKEDEPS="make " +DEPS="musl " + +PKG_VER=1.1 +SOURCE="http://distcache.freebsd.org/local-distfiles/itetcu/libexecinfo-$PKG_VER.tar.bz2" +ADDITIONAL="30-linux-makefile.patch 20-define-gnu-source.patch 10-execinfo.patch " + +prepare () { + apply_patches +} + +build () { + export CFLAGS="${CFLAGS} -fno-omit-frame-pointer" + make PREFIX=/usr +} + +package () { + install -D -m755 execinfo.h \ + "$PKG_DEST"/usr/include/execinfo.h + install -D -m755 stacktraverse.h \ + "$PKG_DEST"/usr/include/stacktraverse.h + install -D -m755 libexecinfo.so.1 \ + "$PKG_DEST"/usr/lib/libexecinfo.so.1 + ln -s /usr/lib/libexecinfo.so.1 \ + "$PKG_DEST"/usr/lib/libexecinfo.so + +} diff --git a/repo/devel/lld.xibuild b/repo/devel/lld.xibuild deleted file mode 100644 index c2dff7f..0000000 --- a/repo/devel/lld.xibuild +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/sh - -NAME="lld" -DESC="The LLVM Linker" - -MAKEDEPS="cmake llvm-libunwind" -DEPS="musl llvm " - -PKG_VER=13.0.0 -SOURCE="https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/lld-$PKG_VER.src.tar.xz" - -build () { - cmake -B build \ - -DCMAKE_BUILD_TYPE=MinSizeRel \ - -DCMAKE_VERBOSE_MAKEFILE=OFF \ - -DCMAKE_C_FLAGS_MINSIZEREL_INIT="$CFLAGS" \ - -DCMAKE_CXX_FLAGS_MINSIZEREL_INIT="$CXXFLAGS" \ - -DCMAKE_EXE_LINKER_FLAGS_MINSIZEREL_INIT="$LDFLAGS -Wl,-z,stack-size=2097152" \ - -DCMAKE_INSTALL_PREFIX=/usr \ - -DCMAKE_SKIP_INSTALL_RPATH=ON \ - -DLLVM_INCLUDE_TESTS=ON \ - -DLLVM_EXTERNAL_LIT=/usr/bin/lit - cmake --build build -} - -package () { - DESTDIR="$PKG_DEST" cmake --install build - install -Dm 644 docs/ld.lld.1 $PKG_DEST/usr/share/man/man1/ -} diff --git a/repo/devel/lld/lld.xibuild b/repo/devel/lld/lld.xibuild new file mode 100644 index 0000000..c2dff7f --- /dev/null +++ b/repo/devel/lld/lld.xibuild @@ -0,0 +1,29 @@ +#!/bin/sh + +NAME="lld" +DESC="The LLVM Linker" + +MAKEDEPS="cmake llvm-libunwind" +DEPS="musl llvm " + +PKG_VER=13.0.0 +SOURCE="https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/lld-$PKG_VER.src.tar.xz" + +build () { + cmake -B build \ + -DCMAKE_BUILD_TYPE=MinSizeRel \ + -DCMAKE_VERBOSE_MAKEFILE=OFF \ + -DCMAKE_C_FLAGS_MINSIZEREL_INIT="$CFLAGS" \ + -DCMAKE_CXX_FLAGS_MINSIZEREL_INIT="$CXXFLAGS" \ + -DCMAKE_EXE_LINKER_FLAGS_MINSIZEREL_INIT="$LDFLAGS -Wl,-z,stack-size=2097152" \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DCMAKE_SKIP_INSTALL_RPATH=ON \ + -DLLVM_INCLUDE_TESTS=ON \ + -DLLVM_EXTERNAL_LIT=/usr/bin/lit + cmake --build build +} + +package () { + DESTDIR="$PKG_DEST" cmake --install build + install -Dm 644 docs/ld.lld.1 $PKG_DEST/usr/share/man/man1/ +} diff --git a/repo/devel/llvm-libunwind.xibuild b/repo/devel/llvm-libunwind.xibuild deleted file mode 100644 index 9c61c31..0000000 --- a/repo/devel/llvm-libunwind.xibuild +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/sh - -NAME="llvm-libunwind" -DESC="LLVM version of libunwind library" - -MAKEDEPS="cmake " -DEPS="musl " - -PKG_VER=13.0.0 -SOURCE="https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/libunwind-$PKG_VER.src.tar.xz" - -ADDITIONAL=" - https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/llvm-$PKG_VER.src.tar.xz - https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/libcxx-$PKG_VER.src.tar.xz - libunwind-link-libssp.patch - libcxx-musl.patch -" - -prepare () { - tar xvf libunwind-$PKG_VER.src.tar.xz - tar xvf llvm-$PKG_VER.src.tar.xz - tar xvf libcxx-$PKG_VER.src.tar.xz - mv libunwind-$PKG_VER.src libunwind - mv llvm-$PKG_VER.src llvm - mv libcxx-$PKG_VER.src libcxx - - apply_patches -} - -build () { - cmake -B build -G Ninja -S libunwind \ - -DCMAKE_BUILD_TYPE=MinSizeRel \ - -DCMAKE_C_FLAGS_MINSIZEREL_INIT="$CFLAGS" \ - -DCMAKE_CXX_FLAGS_MINSIZEREL_INIT="$CXXFLAGS" \ - -DCMAKE_EXE_LINKER_FLAGS_MINSIZEREL_INIT="$LDFLAGS" \ - -DCMAKE_INSTALL_PREFIX=/usr \ - -DLIBUNWIND_HAS_NODEFAULTLIBS_FLAG=OFF \ - -DLIBUNWIND_STANDALONE_BUILD=ON - cmake --build build -} - -package () { - DESTDIR="$PKG_DEST" cmake --install build - mkdir -p "$PKG_DEST"/usr/include/mach-o - cp libunwind/include/*.h "$PKG_DEST"/usr/include/ - cp libunwind/include/mach-o/*.h "$PKG_DEST"/usr/include/mach-o/ - -} diff --git a/repo/devel/llvm-libunwind/libcxx-musl.patch b/repo/devel/llvm-libunwind/libcxx-musl.patch new file mode 100644 index 0000000..358d4a3 --- /dev/null +++ b/repo/devel/llvm-libunwind/libcxx-musl.patch @@ -0,0 +1,28 @@ +Patch-Source: https://github.com/void-linux/void-packages/blob/74f16232621ca8dfb6d244beff1df35a6df1647f/srcpkgs/llvm12/patches/libcxx-musl.patch + +--- a/libcxx/include/locale ++++ b/libcxx/include/locale +@@ -742,7 +742,11 @@ __num_get_signed_integral(const char* __a, const char* __a_end, + typename remove_reference::type __save_errno = errno; + errno = 0; + char *__p2; ++#if defined(__linux__) && !defined(__GLIBC__) ++ long long __ll = strtoll(__a, &__p2, __base); ++#else + long long __ll = strtoll_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE); ++#endif + typename remove_reference::type __current_errno = errno; + if (__current_errno == 0) + errno = __save_errno; +@@ -782,7 +786,11 @@ __num_get_unsigned_integral(const char* __a, const char* __a_end, + typename remove_reference::type __save_errno = errno; + errno = 0; + char *__p2; ++#if defined(__linux__) && !defined(__GLIBC__) ++ unsigned long long __ll = strtoull(__a, &__p2, __base); ++#else + unsigned long long __ll = strtoull_l(__a, &__p2, __base, _LIBCPP_GET_C_LOCALE); ++#endif + typename remove_reference::type __current_errno = errno; + if (__current_errno == 0) + errno = __save_errno; diff --git a/repo/devel/llvm-libunwind/libunwind-link-libssp.patch b/repo/devel/llvm-libunwind/libunwind-link-libssp.patch new file mode 100644 index 0000000..ae819fe --- /dev/null +++ b/repo/devel/llvm-libunwind/libunwind-link-libssp.patch @@ -0,0 +1,20 @@ +--- a/libunwind/src/CMakeLists.txt ++++ b/libunwind/src/CMakeLists.txt +@@ -129,7 +129,7 @@ + else() + target_compile_options(unwind_shared PRIVATE -fno-rtti) + endif() +- target_link_libraries(unwind_shared PRIVATE ${LIBUNWIND_LIBRARIES}) ++ target_link_libraries(unwind_shared PRIVATE ${LIBUNWIND_LIBRARIES} -lssp_nonshared) + set_target_properties(unwind_shared + PROPERTIES + CXX_EXTENSIONS OFF +@@ -157,7 +157,7 @@ + else() + target_compile_options(unwind_static PRIVATE -fno-rtti) + endif() +- target_link_libraries(unwind_static PRIVATE ${LIBUNWIND_LIBRARIES}) ++ target_link_libraries(unwind_static PRIVATE ${LIBUNWIND_LIBRARIES} -lssp_nonshared) + set_target_properties(unwind_static + PROPERTIES + CXX_EXTENSIONS OFF diff --git a/repo/devel/llvm-libunwind/llvm-libunwind.xibuild b/repo/devel/llvm-libunwind/llvm-libunwind.xibuild new file mode 100644 index 0000000..9c61c31 --- /dev/null +++ b/repo/devel/llvm-libunwind/llvm-libunwind.xibuild @@ -0,0 +1,48 @@ +#!/bin/sh + +NAME="llvm-libunwind" +DESC="LLVM version of libunwind library" + +MAKEDEPS="cmake " +DEPS="musl " + +PKG_VER=13.0.0 +SOURCE="https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/libunwind-$PKG_VER.src.tar.xz" + +ADDITIONAL=" + https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/llvm-$PKG_VER.src.tar.xz + https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/libcxx-$PKG_VER.src.tar.xz + libunwind-link-libssp.patch + libcxx-musl.patch +" + +prepare () { + tar xvf libunwind-$PKG_VER.src.tar.xz + tar xvf llvm-$PKG_VER.src.tar.xz + tar xvf libcxx-$PKG_VER.src.tar.xz + mv libunwind-$PKG_VER.src libunwind + mv llvm-$PKG_VER.src llvm + mv libcxx-$PKG_VER.src libcxx + + apply_patches +} + +build () { + cmake -B build -G Ninja -S libunwind \ + -DCMAKE_BUILD_TYPE=MinSizeRel \ + -DCMAKE_C_FLAGS_MINSIZEREL_INIT="$CFLAGS" \ + -DCMAKE_CXX_FLAGS_MINSIZEREL_INIT="$CXXFLAGS" \ + -DCMAKE_EXE_LINKER_FLAGS_MINSIZEREL_INIT="$LDFLAGS" \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DLIBUNWIND_HAS_NODEFAULTLIBS_FLAG=OFF \ + -DLIBUNWIND_STANDALONE_BUILD=ON + cmake --build build +} + +package () { + DESTDIR="$PKG_DEST" cmake --install build + mkdir -p "$PKG_DEST"/usr/include/mach-o + cp libunwind/include/*.h "$PKG_DEST"/usr/include/ + cp libunwind/include/mach-o/*.h "$PKG_DEST"/usr/include/mach-o/ + +} diff --git a/repo/devel/llvm.xibuild b/repo/devel/llvm.xibuild deleted file mode 100644 index f1eaf13..0000000 --- a/repo/devel/llvm.xibuild +++ /dev/null @@ -1,54 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make ninja cmake libedit libffi libxml2 ncurses python-setuptools python-sphinx" -DEPS="perl zlib libffi libedit ncurses" - -PKG_VER=13.0.0 -SOURCE=https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/llvm-$PKG_VER.src.tar.xz -DESC="Collection of modular and reusable compiler and toolchain technologies" - -package () { - grep -rl '#!.*python' | xargs sed -i '1s/python$/python3/' -} - -build () { - mkdir build - cd build - CC=gcc CXX=g++ \ - cmake \ - -DCMAKE_BUILD_TYPE=Release \ - -DCMAKE_INSTALL_PREFIX=/usr \ - -DLLVM_BINUTILS_INCDIR=/usr/include \ - -DLLVM_BUILD_DOCS=OFF \ - -DLLVM_BUILD_EXAMPLES=OFF \ - -DLLVM_BUILD_EXTERNAL_COMPILER_RT=ON \ - -DLLVM_BUILD_LLVM_DYLIB=ON \ - -DLLVM_BUILD_TESTS=ON \ - -DLLVM_DEFAULT_TARGET_TRIPLE="x86_64-linux-musl" \ - -DLLVM_ENABLE_ASSERTIONS=OFF \ - -DLLVM_ENABLE_FFI=ON \ - -DLLVM_ENABLE_LIBCXX=OFF \ - -DLLVM_ENABLE_PIC=ON \ - -DLLVM_ENABLE_RTTI=ON \ - -DLLVM_ENABLE_SPHINX=OFF \ - -DLLVM_ENABLE_TERMINFO=ON \ - -DLLVM_ENABLE_ZLIB=ON \ - -DLLVM_HOST_TRIPLE="x86_64-linux-musl" \ - -DLLVM_INCLUDE_EXAMPLES=OFF \ - -DLLVM_INSTALL_UTILS=ON \ - -DLLVM_LINK_LLVM_DYLIB=ON \ - -DLLVM_APPEND_VC_REV=OFF \ - -Wno-dev -G Ninja .. && - ninja llvm-tblgen && - ninja && - cd .. - - python3 utils/lit/setup.py build -} - -package () { - DESTDIR=$PKG_DEST ninja -C build install - - cd build - python3 ../utils/lit/setup.py install --prefix=/usr --root=$PKG_DEST -} diff --git a/repo/devel/llvm/llvm.xibuild b/repo/devel/llvm/llvm.xibuild new file mode 100644 index 0000000..f1eaf13 --- /dev/null +++ b/repo/devel/llvm/llvm.xibuild @@ -0,0 +1,54 @@ +#!/bin/sh + +MAKEDEPS="make ninja cmake libedit libffi libxml2 ncurses python-setuptools python-sphinx" +DEPS="perl zlib libffi libedit ncurses" + +PKG_VER=13.0.0 +SOURCE=https://github.com/llvm/llvm-project/releases/download/llvmorg-$PKG_VER/llvm-$PKG_VER.src.tar.xz +DESC="Collection of modular and reusable compiler and toolchain technologies" + +package () { + grep -rl '#!.*python' | xargs sed -i '1s/python$/python3/' +} + +build () { + mkdir build + cd build + CC=gcc CXX=g++ \ + cmake \ + -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DLLVM_BINUTILS_INCDIR=/usr/include \ + -DLLVM_BUILD_DOCS=OFF \ + -DLLVM_BUILD_EXAMPLES=OFF \ + -DLLVM_BUILD_EXTERNAL_COMPILER_RT=ON \ + -DLLVM_BUILD_LLVM_DYLIB=ON \ + -DLLVM_BUILD_TESTS=ON \ + -DLLVM_DEFAULT_TARGET_TRIPLE="x86_64-linux-musl" \ + -DLLVM_ENABLE_ASSERTIONS=OFF \ + -DLLVM_ENABLE_FFI=ON \ + -DLLVM_ENABLE_LIBCXX=OFF \ + -DLLVM_ENABLE_PIC=ON \ + -DLLVM_ENABLE_RTTI=ON \ + -DLLVM_ENABLE_SPHINX=OFF \ + -DLLVM_ENABLE_TERMINFO=ON \ + -DLLVM_ENABLE_ZLIB=ON \ + -DLLVM_HOST_TRIPLE="x86_64-linux-musl" \ + -DLLVM_INCLUDE_EXAMPLES=OFF \ + -DLLVM_INSTALL_UTILS=ON \ + -DLLVM_LINK_LLVM_DYLIB=ON \ + -DLLVM_APPEND_VC_REV=OFF \ + -Wno-dev -G Ninja .. && + ninja llvm-tblgen && + ninja && + cd .. + + python3 utils/lit/setup.py build +} + +package () { + DESTDIR=$PKG_DEST ninja -C build install + + cd build + python3 ../utils/lit/setup.py install --prefix=/usr --root=$PKG_DEST +} diff --git a/repo/devel/m4.xibuild b/repo/devel/m4.xibuild deleted file mode 100644 index e6ccf14..0000000 --- a/repo/devel/m4.xibuild +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make help2man" -DEPS="musl sh" - -PKG_VER=1.4.19 -SOURCE=https://ftp.gnu.org/gnu/m4/m4-$PKG_VER.tar.xz -DESC="The gnu m4 macro processor" - - -build () { - ./configure --prefix=/usr - make -} - -check () { - make check || true -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/m4/m4.xibuild b/repo/devel/m4/m4.xibuild new file mode 100644 index 0000000..e6ccf14 --- /dev/null +++ b/repo/devel/m4/m4.xibuild @@ -0,0 +1,22 @@ +#!/bin/sh + +MAKEDEPS="make help2man" +DEPS="musl sh" + +PKG_VER=1.4.19 +SOURCE=https://ftp.gnu.org/gnu/m4/m4-$PKG_VER.tar.xz +DESC="The gnu m4 macro processor" + + +build () { + ./configure --prefix=/usr + make +} + +check () { + make check || true +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/make.xibuild b/repo/devel/make.xibuild deleted file mode 100644 index bb4412f..0000000 --- a/repo/devel/make.xibuild +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -MAKEDEPS="musl" -DEPS="" - -PKG_VER=4.3 -SOURCE=https://ftp.gnu.org/gnu/make/make-$PKG_VER.tar.gz -DESC="GNU make utility" - -build () { - ./configure --prefix=/usr - make -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/make/make.xibuild b/repo/devel/make/make.xibuild new file mode 100644 index 0000000..bb4412f --- /dev/null +++ b/repo/devel/make/make.xibuild @@ -0,0 +1,17 @@ +#!/bin/sh + +MAKEDEPS="musl" +DEPS="" + +PKG_VER=4.3 +SOURCE=https://ftp.gnu.org/gnu/make/make-$PKG_VER.tar.gz +DESC="GNU make utility" + +build () { + ./configure --prefix=/usr + make +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/meson.xibuild b/repo/devel/meson.xibuild deleted file mode 100644 index f445bc4..0000000 --- a/repo/devel/meson.xibuild +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/sh - -MAKEDEPS="python" -DEPS="python ninja" - -PKG_VER=0.59 -SOURCE=https://github.com/mesonbuild/meson -BRANCH=$PKG_VER - -DESC="High productivity build system" - -build () { - python setup.py build -} - -package () { - python setup.py install --root=$PKG_DEST - - install -Dm644 data/shell-completions/bash/meson $PKG_DEST/usr/share/bash-completion/completions/meson - install -Dm644 data/shell-completions/zsh/_meson $PKG_DEST/usr/share/zsh/site-functions/_meson -} diff --git a/repo/devel/meson/meson.xibuild b/repo/devel/meson/meson.xibuild new file mode 100644 index 0000000..f445bc4 --- /dev/null +++ b/repo/devel/meson/meson.xibuild @@ -0,0 +1,21 @@ +#!/bin/sh + +MAKEDEPS="python" +DEPS="python ninja" + +PKG_VER=0.59 +SOURCE=https://github.com/mesonbuild/meson +BRANCH=$PKG_VER + +DESC="High productivity build system" + +build () { + python setup.py build +} + +package () { + python setup.py install --root=$PKG_DEST + + install -Dm644 data/shell-completions/bash/meson $PKG_DEST/usr/share/bash-completion/completions/meson + install -Dm644 data/shell-completions/zsh/_meson $PKG_DEST/usr/share/zsh/site-functions/_meson +} diff --git a/repo/devel/mpc.xibuild b/repo/devel/mpc.xibuild deleted file mode 100644 index f9c9477..0000000 --- a/repo/devel/mpc.xibuild +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make " -DEPS="mpfr" - -PKG_VER=1.2.1 -SOURCE=http://www.multiprecision.org/downloads/mpc-$PKG_VER.tar.gz -DESC="Library for the arithmetic of complex numbers with arbitrarily high precision" - -build () { - ./configure --prefix=/usr --disable-static --docdir=/usr/share/doc/mpc-$PKG_VER - - make - make html -} - -check () { - make check -} - -package () { - make DESTDIR=$PKG_DEST install - make DESTDIR=$PKG_DEST install-html -} diff --git a/repo/devel/mpc/mpc.xibuild b/repo/devel/mpc/mpc.xibuild new file mode 100644 index 0000000..f9c9477 --- /dev/null +++ b/repo/devel/mpc/mpc.xibuild @@ -0,0 +1,24 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="mpfr" + +PKG_VER=1.2.1 +SOURCE=http://www.multiprecision.org/downloads/mpc-$PKG_VER.tar.gz +DESC="Library for the arithmetic of complex numbers with arbitrarily high precision" + +build () { + ./configure --prefix=/usr --disable-static --docdir=/usr/share/doc/mpc-$PKG_VER + + make + make html +} + +check () { + make check +} + +package () { + make DESTDIR=$PKG_DEST install + make DESTDIR=$PKG_DEST install-html +} diff --git a/repo/devel/nasm.xibuild b/repo/devel/nasm.xibuild deleted file mode 100644 index b8d7fd6..0000000 --- a/repo/devel/nasm.xibuild +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make" -DEPS="musl" - -PKG_VER=2.15.05 -SOURCE=https://www.nasm.us/pub/nasm/releasebuilds/$PKG_VER/nasm-$PKG_VER.tar.xz -DESC="80x86 assembler designed for portability and modularity" - -build () { - ./configure --prefix=/usr && - make -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/nasm/nasm.xibuild b/repo/devel/nasm/nasm.xibuild new file mode 100644 index 0000000..b8d7fd6 --- /dev/null +++ b/repo/devel/nasm/nasm.xibuild @@ -0,0 +1,17 @@ +#!/bin/sh + +MAKEDEPS="make" +DEPS="musl" + +PKG_VER=2.15.05 +SOURCE=https://www.nasm.us/pub/nasm/releasebuilds/$PKG_VER/nasm-$PKG_VER.tar.xz +DESC="80x86 assembler designed for portability and modularity" + +build () { + ./configure --prefix=/usr && + make +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/ninja.xibuild b/repo/devel/ninja.xibuild deleted file mode 100644 index 8ae4868..0000000 --- a/repo/devel/ninja.xibuild +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh - -MAKEDEPS="python" -DEPS="musl" - -PKG_VER=1.10.2 -SOURCE=https://github.com/ninja-build/ninja/archive/refs/tags/v$PKG_VER.tar.gz -DESC="Small build system with a focus on speed" - -build () { - python configure.py --bootstrap -} - -check () { - ./ninja ninja_test -} - -package () { - mkdir -p $PKG_DEST/usr/bin - mkdir -p $PKG_DEST/usr/share/{bash-completion/completions,zsh/site-functions} - install -m755 ninja $PKG_DEST/usr/bin/ - install -Dm644 misc/bash-completion $PKG_DEST/usr/share/bash-completion/completions/ninja - install -Dm644 misc/zsh-completion $PKG_DEST/usr/share/zsh/site-functions/_ninja -} diff --git a/repo/devel/ninja/ninja.xibuild b/repo/devel/ninja/ninja.xibuild new file mode 100644 index 0000000..8ae4868 --- /dev/null +++ b/repo/devel/ninja/ninja.xibuild @@ -0,0 +1,24 @@ +#!/bin/sh + +MAKEDEPS="python" +DEPS="musl" + +PKG_VER=1.10.2 +SOURCE=https://github.com/ninja-build/ninja/archive/refs/tags/v$PKG_VER.tar.gz +DESC="Small build system with a focus on speed" + +build () { + python configure.py --bootstrap +} + +check () { + ./ninja ninja_test +} + +package () { + mkdir -p $PKG_DEST/usr/bin + mkdir -p $PKG_DEST/usr/share/{bash-completion/completions,zsh/site-functions} + install -m755 ninja $PKG_DEST/usr/bin/ + install -Dm644 misc/bash-completion $PKG_DEST/usr/share/bash-completion/completions/ninja + install -Dm644 misc/zsh-completion $PKG_DEST/usr/share/zsh/site-functions/_ninja +} diff --git a/repo/devel/patch.xibuild b/repo/devel/patch.xibuild deleted file mode 100644 index 015aeeb..0000000 --- a/repo/devel/patch.xibuild +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make " -DEPS="musl attr" - -PKG_VER=2.7 -SOURCE=https://ftp.gnu.org/gnu/patch/patch-$PKG_VER.tar.xz -DESC="A utility to apply patch files to a file" - -build () { - ./configure --prefix=/usr - make -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/patch/patch.xibuild b/repo/devel/patch/patch.xibuild new file mode 100644 index 0000000..015aeeb --- /dev/null +++ b/repo/devel/patch/patch.xibuild @@ -0,0 +1,17 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="musl attr" + +PKG_VER=2.7 +SOURCE=https://ftp.gnu.org/gnu/patch/patch-$PKG_VER.tar.xz +DESC="A utility to apply patch files to a file" + +build () { + ./configure --prefix=/usr + make +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/pkg-config.xibuild b/repo/devel/pkg-config.xibuild deleted file mode 100644 index 3db8dfd..0000000 --- a/repo/devel/pkg-config.xibuild +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make" -DEPS="musl" - -PKG_VER=0.29.2 -SOURCE=https://pkg-config.freedesktop.org/releases/pkg-config-$PKG_VER.tar.gz -DESC="Package compiler and linker metadata toolkit" - -build () { - ./configure --prefix=/usr \ - --with-internal-glib \ - --disable-host-tool \ - --docdir=/usr/share/doc/pkg-config-$PKG_VER - make -} - -check () { - make check -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/pkg-config/pkg-config.xibuild b/repo/devel/pkg-config/pkg-config.xibuild new file mode 100644 index 0000000..3db8dfd --- /dev/null +++ b/repo/devel/pkg-config/pkg-config.xibuild @@ -0,0 +1,24 @@ +#!/bin/sh + +MAKEDEPS="make" +DEPS="musl" + +PKG_VER=0.29.2 +SOURCE=https://pkg-config.freedesktop.org/releases/pkg-config-$PKG_VER.tar.gz +DESC="Package compiler and linker metadata toolkit" + +build () { + ./configure --prefix=/usr \ + --with-internal-glib \ + --disable-host-tool \ + --docdir=/usr/share/doc/pkg-config-$PKG_VER + make +} + +check () { + make check +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/rustc.xibuild b/repo/devel/rustc.xibuild deleted file mode 100644 index 758dafe..0000000 --- a/repo/devel/rustc.xibuild +++ /dev/null @@ -1,94 +0,0 @@ -#!/bin/sh - -MAKEDEPS="cmake llvm clang llvm-ar" -DEPS="curl libssh2 openssl" - -PKG_VER=1.58.1 -SOURCE=https://static.rust-lang.org/dist/rustc-$PKG_VER-src.tar.gz -DESC="Systems programming language focused on safety, speed and concurrency" - -ADDITIONAL=" - patches/0006-Prefer-libgcc_eh-over-libunwind-for-musl.patch - patches/0007-do-not-install-libunwind-source.patch - patches/install-template-shebang.patch - patches/link-musl-dynamically.patch - patches/musl-fix-linux_musl_base.patch - patches/need-rpath.patch - patches/need-ssp_nonshared.patch -" - -prepare () { - apply_patches - sed -i /LD_LIBRARY_PATH/d src/bootstrap/bootstrap.py - sed -i 's/\("files":{\)[^}]*/\1/' vendor/libc/.cargo-checksum.json - -} - -build () { - target=x86_64-unknown-linux-musl - build=x86_64-unknown-linux-musl - ./configure \ - --build="$build" \ - --host="$target" \ - --target="$target" \ - --prefix="/usr" \ - --release-channel="stable" \ - --llvm-root="/usr/lib/" \ - --disable-docs \ - --enable-extended \ - --tools="analysis,cargo,src,rustfmt" \ - --enable-llvm-link-shared \ - --enable-option-checking \ - --enable-locked-deps \ - --enable-vendor \ - --set="rust.musl-root=/usr" \ - --set="rust.codegen-units=1" \ - --set="rust.codegen-units-std=1" \ - --set="rust.parallel-compiler=true" \ - --set="target.$target.llvm-config=/usr/bin/llvm-config" \ - --set="target.$target.musl-root=/usr" \ - --set="target.$target.crt-static=false" \ - --set="target.$target.cc=clang" \ - --set="target.$target.cxx=clang++" \ - --set="target.$target.ar=llvm-ar" \ - --set="target.$target.linker=clang" \ - --set="target.$build.musl-root=/usr" \ - --set="target.$build.crt-static=false" \ - --set="target.$build.cc=clang" \ - --set="target.$build.cxx=clang++" \ - --set="target.$build.ar=llvm-ar" \ - --set="target.$build.linker=clang" - - sed 's/#deny-warnings = .*/deny-warnings = false/' -i config.toml - sed 's|deny(warnings,|deny(|' -i src/bootstrap/lib.rs - - python ./x.py dist -v --jobs $JOBS - -} - -package () { - export LIBSSH2_SYS_USE_PKG_CONFIG=1 && - DESTDIR=${PWD}/install python3 ./x.py install && - unset LIBSSH2_SYS_USE_PKG_CONFIG - - chown -R root:root install && - cp -a install/* $PKG_DEST - - mkdir -p $PKG_DEST/etc/profile.d/ - cat > $PKG_DEST/etc/profile.d/rustc.sh << "EOF" -# Begin /etc/profile.d/rustc.sh - -pathprepend /opt/rustc/bin PATH - -# End /etc/profile.d/rustc.sh -EOF - mkdir -p $PKG_DEST/etc/ld.so.conf.d -cat >> $PKG_DEST/etc/ld.so.conf.d/rustc.conf << EOF -# Begin rustc addition - -/opt/rustc/lib - -# End rustc addition -EOF - -} diff --git a/repo/devel/rustc/files/check-rustc b/repo/devel/rustc/files/check-rustc new file mode 100644 index 0000000..d4b85be --- /dev/null +++ b/repo/devel/rustc/files/check-rustc @@ -0,0 +1,109 @@ +#!/bin/sh +# vim: set ts=4: +set -eu + +RUSTC="$1" +TMPDIR="$(pwd)/.tmp-${0##*/}-$RANDOM" +failed=0 + +unset RUST_BACKTRACE +unset RUSTC_CRT_STATIC + + +_rustc() { + printf '\n$ rustc %s\n' "$*" + "$RUSTC" "$@" +} + +die() { + printf '\033[1;31mERROR:\033[0m %s\n' "$1" >&2 # bold red + exit 1 +} + +fail() { + printf '\033[1;31mFAIL:\033[0m %s\n' "$1" >&2 # bold red + failed=$(( failed + 1 )) +} + +assert_dynamic() { + readelf -l "$1" | grep -Fqw INTERP \ + && readelf -d "$1" | grep -Fqw NEEDED || { + fail "$1 is not a dynamic executable!" + readelf -ld "$1" + } +} + +assert_ok() { + "$1" || fail "$1 exited with status $?" +} + +assert_panic() { + local status=0 + "$1" || status=$? && [ "$status" = 101 ] \ + || fail "$1 exited with status $status, but expected 101" +} + +assert_pie() { + readelf -d "$1" | grep -Fw FLAGS_1 | grep -Fqw PIE || { + fail "$1 is not a PIE executable!" + readelf -d "$1" + } +} + +assert_static() { + test -f "$1" \ + && ! readelf -l "$1" | grep -Fqw INTERP \ + && ! readelf -d "$1" | grep -Fqw NEEDED || { + fail "$1 is not a static executable!" + readelf -ld "$1" + } +} + + +#-------------------- M a i n -------------------- + +test -d "$TMPDIR" && die "$TMPDIR already exists!" +mkdir -p "$TMPDIR" +trap "rm -R '$TMPDIR'" EXIT + +cd "$TMPDIR" + +cat >> hello_world.rs <<-EOF + fn main() { + println!("Hello, world!"); + } +EOF + +_rustc hello_world.rs +assert_ok ./hello_world +assert_dynamic hello_world +assert_pie hello_world +rm -f hello_world + +_rustc -C target-feature=-crt-static hello_world.rs +assert_ok ./hello_world +assert_dynamic hello_world +assert_pie hello_world +rm -f hello_world + +_rustc -C target-feature=+crt-static hello_world.rs +assert_ok ./hello_world +assert_static hello_world +assert_pie hello_world +rm -f hello_world + + +cat >> panic.rs <<-EOF + fn main() { + panic!("This should panic"); + } +EOF + +_rustc -C target-feature=-crt-static panic.rs +assert_panic ./panic + +_rustc -C target-feature=+crt-static panic.rs +assert_panic ./panic + + +[ "$failed" -eq 0 ] || die "$failed assertion(s) has failed" diff --git a/repo/devel/rustc/patches/0006-Prefer-libgcc_eh-over-libunwind-for-musl.patch b/repo/devel/rustc/patches/0006-Prefer-libgcc_eh-over-libunwind-for-musl.patch new file mode 100644 index 0000000..30cb66f --- /dev/null +++ b/repo/devel/rustc/patches/0006-Prefer-libgcc_eh-over-libunwind-for-musl.patch @@ -0,0 +1,24 @@ +Additions for build.rs by q66, necessary for our musl setup. + +From 1eb558f246269606c6d8d73824ef6b44fa10764e Mon Sep 17 00:00:00 2001 +From: Samuel Holland +Date: Sat, 9 Sep 2017 00:14:16 -0500 +Subject: [PATCH 06/16] Prefer libgcc_eh over libunwind for musl + +--- + src/libunwind/lib.rs | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/libunwind/lib.rs b/src/libunwind/lib.rs +index 9182e349b19..0377fbb58fc 100644 +--- a/library/unwind/src/lib.rs ++++ b/library/unwind/src/lib.rs +@@ -51,7 +51,7 @@ + #[link(name = "unwind", cfg(not(target_feature = "crt-static")))] + extern "C" {} + } else { +- #[link(name = "unwind", kind = "static", modifiers = "-bundle", cfg(target_feature = "crt-static"))] ++ #[link(name = "gcc_eh", cfg(target_feature = "crt-static"))] + #[link(name = "gcc_s", cfg(not(target_feature = "crt-static")))] + extern "C" {} + } diff --git a/repo/devel/rustc/patches/0007-do-not-install-libunwind-source.patch b/repo/devel/rustc/patches/0007-do-not-install-libunwind-source.patch new file mode 100644 index 0000000..e8ff8b7 --- /dev/null +++ b/repo/devel/rustc/patches/0007-do-not-install-libunwind-source.patch @@ -0,0 +1,19 @@ +From: Dominic Meiser +Date: Tue, 22 Dec 2020 23:31:28 +0100 +Subject: [PATCH] Do not install libunwind source + +This was added in rustc 1.48, but is incompatible with the Alpine Linux package since it removes all bundled +dependencies prior to building. + +diff -Naur rustc-1.48.0-src.orig/src/bootstrap/dist.rs rustc-1.48.0-src/src/bootstrap/dist.rs +--- rustc-1.48.0-src.orig/src/bootstrap/dist.rs 2020-12-22 16:39:30.504249113 +0100 ++++ rustc-1.48.0-src/src/bootstrap/dist.rs 2020-12-22 16:42:08.663006830 +0100 +@@ -1016,7 +1016,7 @@ + copy_src_dirs( + builder, + &builder.src, +- &["library", "src/llvm-project/libunwind"], ++ &["library"], + &[ + // not needed and contains symlinks which rustup currently + // chokes on when unpacking. diff --git a/repo/devel/rustc/patches/alpine-move-py-scripts-to-share.patch b/repo/devel/rustc/patches/alpine-move-py-scripts-to-share.patch new file mode 100644 index 0000000..21be36f --- /dev/null +++ b/repo/devel/rustc/patches/alpine-move-py-scripts-to-share.patch @@ -0,0 +1,23 @@ +--- a/src/etc/rust-gdb ++++ b/src/etc/rust-gdb +@@ -12,7 +12,7 @@ + + # Find out where the pretty printer Python module is + RUSTC_SYSROOT="$("$RUSTC" --print=sysroot)" +-GDB_PYTHON_MODULE_DIRECTORY="$RUSTC_SYSROOT/lib/rustlib/etc" ++GDB_PYTHON_MODULE_DIRECTORY="$RUSTC_SYSROOT/share/rust/etc" + + # Run GDB with the additional arguments that load the pretty printers + # Set the environment variable `RUST_GDB` to overwrite the call to a + # Set the environment variable `RUST_GDB` to overwrite the call to a +--- a/src/etc/rust-lldb ++++ b/src/etc/rust-lldb +@@ -8,7 +8,7 @@ + + # Find out where to look for the pretty printer Python module + RUSTC_SYSROOT=$(rustc --print sysroot) +-RUST_LLDB="$RUSTC_SYSROOT/lib/rustlib/$host/bin/lldb" ++RUST_LLDB="$RUSTC_SYSROOT/share/rust/etc" + + lldb=lldb + if [ -f "$RUST_LLDB" ]; then diff --git a/repo/devel/rustc/patches/alpine-target.patch b/repo/devel/rustc/patches/alpine-target.patch new file mode 100644 index 0000000..2392cdd --- /dev/null +++ b/repo/devel/rustc/patches/alpine-target.patch @@ -0,0 +1,191 @@ +From: Shiz +Updated by Rasmus Thomsen on 28th of July 2019 +Updated again by Ariadne Conill on 31 October 2020 +Date: Thu, 20 Aug 2017 01:52:36 +0200 +Last-Updated: Sat, 28 Oct 2017 20:23:00 +0200 +Subject: [PATCH] Add Alpine targets + +This adds `$arch-alpine-linux-musl` targets to Rust to encode our toolchain +and distribution-specific quirks instead of polluting the main musl target of +`$arch-unknown-linux-musl`. + +--- /dev/null ++++ rustc-1.48.0-src/compiler/rustc_target/src/spec/aarch64_alpine_linux_musl.rs +@@ -0,0 +1,13 @@ ++use crate::spec::Target; ++ ++pub fn target() -> Target { ++ let mut base = super::aarch64_unknown_linux_musl::target(); ++ ++ base.llvm_target = "aarch64-alpine-linux-musl".to_string(); ++ base.options.vendor = "alpine".to_string(); ++ base.options.crt_static_default = false; ++ base.options.static_position_independent_executables = true; ++ base.options.need_rpath = true; ++ ++ base ++} +--- /dev/null ++++ rustc-1.48.0-src/compiler/rustc_target/src/spec/armv6_alpine_linux_musleabihf.rs +@@ -0,0 +1,13 @@ ++use crate::spec::Target; ++ ++pub fn target() -> Target { ++ let mut base = super::arm_unknown_linux_musleabihf::target(); ++ ++ base.llvm_target = "armv6-alpine-linux-musleabihf".to_string(); ++ base.options.vendor = "alpine".to_string(); ++ base.options.crt_static_default = false; ++ base.options.static_position_independent_executables = true; ++ base.options.need_rpath = true; ++ ++ base ++} +--- /dev/null ++++ rustc-1.48.0-src/compiler/rustc_target/src/spec/armv7_alpine_linux_musleabihf.rs +@@ -0,0 +1,13 @@ ++use crate::spec::Target; ++ ++pub fn target() -> Target { ++ let mut base = super::armv7_unknown_linux_musleabihf::target(); ++ ++ base.llvm_target = "armv7-alpine-linux-musleabihf".to_string(); ++ base.options.vendor = "alpine".to_string(); ++ base.options.crt_static_default = false; ++ base.options.static_position_independent_executables = true; ++ base.options.need_rpath = true; ++ ++ base ++} +--- /dev/null ++++ rustc-1.48.0-src/compiler/rustc_target/src/spec/i586_alpine_linux_musl.rs +@@ -0,0 +1,14 @@ ++use crate::spec::Target; ++ ++pub fn target() -> Target { ++ let mut base = super::i686_unknown_linux_musl::target(); ++ ++ base.options.cpu = "pentium4".to_string(); ++ base.llvm_target = "i586-alpine-linux-musl".to_string(); ++ base.options.vendor = "alpine".to_string(); ++ base.options.crt_static_default = false; ++ base.options.static_position_independent_executables = true; ++ base.options.need_rpath = true; ++ ++ base ++} +--- rustc-1.48.0-src.orig/compiler/rustc_target/src/spec/mod.rs ++++ rustc-1.48.0-src/compiler/rustc_target/src/spec/mod.rs +@@ -490,6 +490,16 @@ + } + + supported_targets! { ++ ("i586-alpine-linux-musl", i586_alpine_linux_musl), ++ ("x86_64-alpine-linux-musl", x86_64_alpine_linux_musl), ++ ("aarch64-alpine-linux-musl", aarch64_alpine_linux_musl), ++ ("armv6-alpine-linux-musleabihf", armv6_alpine_linux_musleabihf), ++ ("armv7-alpine-linux-musleabihf", armv7_alpine_linux_musleabihf), ++ ("powerpc-alpine-linux-musl", powerpc_alpine_linux_musl), ++ ("powerpc64-alpine-linux-musl", powerpc64_alpine_linux_musl), ++ ("powerpc64le-alpine-linux-musl", powerpc64le_alpine_linux_musl), ++ ("s390x-alpine-linux-musl", s390x_alpine_linux_musl), ++ ("riscv64-alpine-linux-musl", riscv64_alpine_linux_musl), + ("x86_64-unknown-linux-gnu", x86_64_unknown_linux_gnu), + ("x86_64-unknown-linux-gnux32", x86_64_unknown_linux_gnux32), + ("i686-unknown-linux-gnu", i686_unknown_linux_gnu), +--- /dev/null ++++ rustc-1.48.0-src/compiler/rustc_target/src/spec/powerpc64_alpine_linux_musl.rs +@@ -0,0 +1,13 @@ ++use crate::spec::Target; ++ ++pub fn target() -> Target { ++ let mut base = super::powerpc64_unknown_linux_musl::target(); ++ ++ base.llvm_target = "powerpc64-alpine-linux-musl".to_string(); ++ base.options.vendor = "alpine".to_string(); ++ base.options.crt_static_default = false; ++ base.options.static_position_independent_executables = true; ++ base.options.need_rpath = true; ++ ++ base ++} +--- /dev/null ++++ rustc-1.48.0-src/compiler/rustc_target/src/spec/powerpc64le_alpine_linux_musl.rs +@@ -0,0 +1,13 @@ ++use crate::spec::Target; ++ ++pub fn target() -> Target { ++ let mut base = super::powerpc64le_unknown_linux_musl::target(); ++ ++ base.llvm_target = "powerpc64le-alpine-linux-musl".to_string(); ++ base.options.vendor = "alpine".to_string(); ++ base.options.crt_static_default = false; ++ base.options.static_position_independent_executables = true; ++ base.options.need_rpath = true; ++ ++ base ++} +--- /dev/null ++++ rustc-1.48.0-src/compiler/rustc_target/src/spec/powerpc_alpine_linux_musl.rs +@@ -0,0 +1,13 @@ ++use crate::spec::Target; ++ ++pub fn target() -> Target { ++ let mut base = super::powerpc_unknown_linux_musl::target(); ++ ++ base.llvm_target = "powerpc-alpine-linux-musl".to_string(); ++ base.options.vendor = "alpine".to_string(); ++ base.options.crt_static_default = false; ++ base.options.static_position_independent_executables = true; ++ base.options.need_rpath = true; ++ ++ base ++} +--- /dev/null ++++ rustc-1.48.0-src/compiler/rustc_target/src/spec/s390x_alpine_linux_musl.rs +@@ -0,0 +1,13 @@ ++use crate::spec::Target; ++ ++pub fn target() -> Target { ++ let mut base = super::s390x_unknown_linux_musl::target(); ++ ++ base.llvm_target = "s390x-alpine-linux-musl".to_string(); ++ base.options.vendor = "alpine".to_string(); ++ base.options.crt_static_default = false; ++ base.options.static_position_independent_executables = true; ++ base.options.need_rpath = true; ++ ++ base ++} +--- /dev/null ++++ rustc-1.48.0-src/compiler/rustc_target/src/spec/x86_64_alpine_linux_musl.rs +@@ -0,0 +1,13 @@ ++use crate::spec::Target; ++ ++pub fn target() -> Target { ++ let mut base = super::x86_64_unknown_linux_musl::target(); ++ ++ base.llvm_target = "x86_64-alpine-linux-musl".to_string(); ++ base.options.vendor = "alpine".to_string(); ++ base.options.crt_static_default = false; ++ base.options.static_position_independent_executables = true; ++ base.options.need_rpath = true; ++ ++ base ++} +--- /dev/null ++++ rustc-1.52.1-src/compiler/rustc_target/src/spec/riscv64_alpine_linux_musl.rs +@@ -0,0 +1,13 @@ ++use crate::spec::Target; ++ ++pub fn target() -> Target { ++ let mut base = super::riscv64gc_unknown_linux_musl::target(); ++ ++ base.llvm_target = "riscv64-alpine-linux-musl".to_string(); ++ base.options.vendor = "alpine".to_string(); ++ base.options.crt_static_default = false; ++ base.options.static_position_independent_executables = true; ++ base.options.need_rpath = true; ++ ++ base ++} diff --git a/repo/devel/rustc/patches/install-template-shebang.patch b/repo/devel/rustc/patches/install-template-shebang.patch new file mode 100644 index 0000000..e81b579 --- /dev/null +++ b/repo/devel/rustc/patches/install-template-shebang.patch @@ -0,0 +1,10 @@ +The script seems to be POSIX-sh (+ local) compatible. + +--- a/src/tools/rust-installer/install-template.sh ++++ b/src/tools/rust-installer/install-template.sh +@@ -1,4 +1,4 @@ +-#!/bin/bash ++#!/bin/sh + # Copyright 2014 The Rust Project Developers. See the COPYRIGHT + # file at the top-level directory of this distribution and at + # http://rust-lang.org/COPYRIGHT. diff --git a/repo/devel/rustc/patches/link-musl-dynamically.patch b/repo/devel/rustc/patches/link-musl-dynamically.patch new file mode 100644 index 0000000..55d02a3 --- /dev/null +++ b/repo/devel/rustc/patches/link-musl-dynamically.patch @@ -0,0 +1,17 @@ +--- rustc-1.58.0-src.orig/vendor/libc/src/unix/mod.rs ++++ rustc-1.58.0-src/vendor/libc/src/unix/mod.rs +@@ -329,11 +329,11 @@ + #[link(name = "c", cfg(not(target_feature = "crt-static")))] + extern {} + } else if #[cfg(target_env = "musl")] { ++ #[link(name = "c")] ++ extern {} + #[cfg_attr(feature = "rustc-dep-of-std", +- link(name = "c", kind = "static", modifiers = "-bundle", ++ link(name = "gcc", kind = "static", modifiers = "-bundle", + cfg(target_feature = "crt-static")))] +- #[cfg_attr(feature = "rustc-dep-of-std", +- link(name = "c", cfg(not(target_feature = "crt-static"))))] + extern {} + } else if #[cfg(target_os = "emscripten")] { + #[link(name = "c")] diff --git a/repo/devel/rustc/patches/musl-fix-linux_musl_base.patch b/repo/devel/rustc/patches/musl-fix-linux_musl_base.patch new file mode 100644 index 0000000..1771ffe --- /dev/null +++ b/repo/devel/rustc/patches/musl-fix-linux_musl_base.patch @@ -0,0 +1,23 @@ +From: Jakub Jirutka +Date: Sat, 08 Aug 2016 15:06:00 +0200 +Subject: [PATCH] Fix linux_musl_base for native musl host + +See https://github.com/rust-lang/rust/pull/40113 + +--- a/compiler/rustc_target/src/spec/linux_musl_base.rs ++++ b/compiler/rustc_target/src/spec/linux_musl_base.rs +@@ -5,12 +5,9 @@ + let mut base = super::linux_base::opts(); + + base.env = "musl".to_string(); +- base.pre_link_objects_fallback = crt_objects::pre_musl_fallback(); +- base.post_link_objects_fallback = crt_objects::post_musl_fallback(); +- base.crt_objects_fallback = Some(CrtObjectsFallback::Musl); + + // These targets statically link libc by default +- base.crt_static_default = true; ++ base.crt_static_default = false; + + base + } + diff --git a/repo/devel/rustc/patches/need-rpath.patch b/repo/devel/rustc/patches/need-rpath.patch new file mode 100644 index 0000000..5ab8377 --- /dev/null +++ b/repo/devel/rustc/patches/need-rpath.patch @@ -0,0 +1,62 @@ +From: Shiz +Date: Thu, 20 Aug 2017 01:48:22 +0200 +Subject: [PATCH] Add need_rpath target option to force RPATH generation + +This adds a `need_rpath` option to the target options in order to implicitly +have the equivalent of `-C rpath` specified by default for final products +(executables and dynamic libraries), so that RPATHs are always added. + +We have to skip this step in the bootstrap phase as it does its own manual +RPATH additions, but unfortunately there's no clean way to detect this. +As such, we have to resort to checking the `RUSTC_BOOTSTRAP` variable. +Hacky hacky! + +--- a/compiler/rustc_target/src/spec/mod.rs ++++ b/compiler/rustc_target/src/spec/mod.rs +@@ -379,6 +379,8 @@ + pub allows_weak_linkage: bool, + /// Whether the linker support rpaths or not. Defaults to false. + pub has_rpath: bool, ++ /// Whether to force rpath support on by default. Defaults to false. ++ pub need_rpath: bool, + /// Whether to disable linking to the default libraries, typically corresponds + /// to `-nodefaultlibs`. Defaults to true. + pub no_default_libraries: bool, +@@ -519,6 +519,7 @@ + linker_is_gnu: false, + allows_weak_linkage: true, + has_rpath: false, ++ need_rpath: false, + no_default_libraries: true, + position_independent_executables: false, + static_position_independent_executables: false, +@@ -776,6 +776,7 @@ + key!(linker_is_gnu, bool); + key!(allows_weak_linkage, bool); + key!(has_rpath, bool); ++ key!(need_rpath, bool); + key!(no_default_libraries, bool); + key!(position_independent_executables, bool); + key!(static_position_independent_executables, bool); +@@ -980,6 +980,7 @@ + target_option_val!(linker_is_gnu); + target_option_val!(allows_weak_linkage); + target_option_val!(has_rpath); ++ target_option_val!(need_rpath); + target_option_val!(no_default_libraries); + target_option_val!(position_independent_executables); + target_option_val!(static_position_independent_executables); +--- a/compiler/rustc_codegen_ssa/src/back/link.rs.orig ++++ b/compiler/rustc_codegen_ssa/src/back/link.rs +@@ -1675,7 +1675,10 @@ + // FIXME (#2397): At some point we want to rpath our guesses as to + // where extern libraries might live, based on the + // add_lib_search_paths +- if sess.opts.cg.rpath { ++ // XXX: hacky hacky ++ let bootstrap = env::var("RUSTC_BOOTSTRAP").is_ok(); ++ if !bootstrap && !sess.crt_static(None) && ++ (sess.opts.cg.rpath || sess.target.options.need_rpath) { + let libs = codegen_results + .crate_info + .used_crates diff --git a/repo/devel/rustc/patches/need-ssp_nonshared.patch b/repo/devel/rustc/patches/need-ssp_nonshared.patch new file mode 100644 index 0000000..f1adf20 --- /dev/null +++ b/repo/devel/rustc/patches/need-ssp_nonshared.patch @@ -0,0 +1,13 @@ +--- a/library/std/src/sys/unix/mod.rs.orig 2021-02-11 18:34:14.479832268 +0100 ++++ b/library/std/src/sys/unix/mod.rs 2021-02-11 18:38:28.078987749 +0100 +@@ -243,6 +243,9 @@ + #[link(name = "log")] + #[link(name = "gcc")] + extern "C" {} ++ } else if #[cfg(all(target_os = "linux", target_env = "musl"))] { ++ #[link(name = "ssp_nonshared")] ++ extern "C" {} + } else if #[cfg(target_os = "freebsd")] { + #[link(name = "execinfo")] + #[link(name = "pthread")] + diff --git a/repo/devel/rustc/rustc.xibuild b/repo/devel/rustc/rustc.xibuild new file mode 100644 index 0000000..758dafe --- /dev/null +++ b/repo/devel/rustc/rustc.xibuild @@ -0,0 +1,94 @@ +#!/bin/sh + +MAKEDEPS="cmake llvm clang llvm-ar" +DEPS="curl libssh2 openssl" + +PKG_VER=1.58.1 +SOURCE=https://static.rust-lang.org/dist/rustc-$PKG_VER-src.tar.gz +DESC="Systems programming language focused on safety, speed and concurrency" + +ADDITIONAL=" + patches/0006-Prefer-libgcc_eh-over-libunwind-for-musl.patch + patches/0007-do-not-install-libunwind-source.patch + patches/install-template-shebang.patch + patches/link-musl-dynamically.patch + patches/musl-fix-linux_musl_base.patch + patches/need-rpath.patch + patches/need-ssp_nonshared.patch +" + +prepare () { + apply_patches + sed -i /LD_LIBRARY_PATH/d src/bootstrap/bootstrap.py + sed -i 's/\("files":{\)[^}]*/\1/' vendor/libc/.cargo-checksum.json + +} + +build () { + target=x86_64-unknown-linux-musl + build=x86_64-unknown-linux-musl + ./configure \ + --build="$build" \ + --host="$target" \ + --target="$target" \ + --prefix="/usr" \ + --release-channel="stable" \ + --llvm-root="/usr/lib/" \ + --disable-docs \ + --enable-extended \ + --tools="analysis,cargo,src,rustfmt" \ + --enable-llvm-link-shared \ + --enable-option-checking \ + --enable-locked-deps \ + --enable-vendor \ + --set="rust.musl-root=/usr" \ + --set="rust.codegen-units=1" \ + --set="rust.codegen-units-std=1" \ + --set="rust.parallel-compiler=true" \ + --set="target.$target.llvm-config=/usr/bin/llvm-config" \ + --set="target.$target.musl-root=/usr" \ + --set="target.$target.crt-static=false" \ + --set="target.$target.cc=clang" \ + --set="target.$target.cxx=clang++" \ + --set="target.$target.ar=llvm-ar" \ + --set="target.$target.linker=clang" \ + --set="target.$build.musl-root=/usr" \ + --set="target.$build.crt-static=false" \ + --set="target.$build.cc=clang" \ + --set="target.$build.cxx=clang++" \ + --set="target.$build.ar=llvm-ar" \ + --set="target.$build.linker=clang" + + sed 's/#deny-warnings = .*/deny-warnings = false/' -i config.toml + sed 's|deny(warnings,|deny(|' -i src/bootstrap/lib.rs + + python ./x.py dist -v --jobs $JOBS + +} + +package () { + export LIBSSH2_SYS_USE_PKG_CONFIG=1 && + DESTDIR=${PWD}/install python3 ./x.py install && + unset LIBSSH2_SYS_USE_PKG_CONFIG + + chown -R root:root install && + cp -a install/* $PKG_DEST + + mkdir -p $PKG_DEST/etc/profile.d/ + cat > $PKG_DEST/etc/profile.d/rustc.sh << "EOF" +# Begin /etc/profile.d/rustc.sh + +pathprepend /opt/rustc/bin PATH + +# End /etc/profile.d/rustc.sh +EOF + mkdir -p $PKG_DEST/etc/ld.so.conf.d +cat >> $PKG_DEST/etc/ld.so.conf.d/rustc.conf << EOF +# Begin rustc addition + +/opt/rustc/lib + +# End rustc addition +EOF + +} diff --git a/repo/devel/scdoc.xibuild b/repo/devel/scdoc.xibuild deleted file mode 100644 index d6fc4de..0000000 --- a/repo/devel/scdoc.xibuild +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/sh - -MAKEDEPS="python " -DEPS="pkgconf" - -PKG_VER=1.11.2 -SOURCE=https://git.sr.ht/~sircmpwn/scdoc/archive/$PKG_VER.tar.gz -DESC="Simple man page generator written for POSIX systems written in C99" - -build () { - make PREFIX="/usr" -} - -package () { - make DESTDIR=$PKG_DEST PREFIX="/usr" install -} diff --git a/repo/devel/scdoc/scdoc.xibuild b/repo/devel/scdoc/scdoc.xibuild new file mode 100644 index 0000000..d6fc4de --- /dev/null +++ b/repo/devel/scdoc/scdoc.xibuild @@ -0,0 +1,16 @@ +#!/bin/sh + +MAKEDEPS="python " +DEPS="pkgconf" + +PKG_VER=1.11.2 +SOURCE=https://git.sr.ht/~sircmpwn/scdoc/archive/$PKG_VER.tar.gz +DESC="Simple man page generator written for POSIX systems written in C99" + +build () { + make PREFIX="/usr" +} + +package () { + make DESTDIR=$PKG_DEST PREFIX="/usr" install +} diff --git a/repo/devel/sgml-common.xibuild b/repo/devel/sgml-common.xibuild deleted file mode 100644 index 70fe070..0000000 --- a/repo/devel/sgml-common.xibuild +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/sh - -MAKEDEPS="unzip patch" -DEPS="libxml2 sgml-common" - -PKG_VER=0.6.3 -SOURCE=https://sourceware.org/ftp/docbook-tools/new-trials/SOURCES/sgml-common-$PKG_VER.tgz -ADDITIONAL=" - https://www.linuxfromscratch.org/patches/blfs/svn/sgml-common-$PKG_VER-manpage-1.patch - " - -DESC="Tools for maintaining centralized SGML catalogs." - -prepare() { - patch -Np1 -i sgml-common-$PKG_VER-manpage-1.patch && - autoreconf -f -i -} - -build() { - ./configure --prefix=/usr --sysconfdir=/etc && - make -} - -package () { - make DESTDIR=$PKG_DEST docdir=/usr/share/doc install && - - mkdir -p $PKG_DEST/etc/sgml - mkdir -p /etc/sgml - -} diff --git a/repo/devel/sgml-common/sgml-common.xibuild b/repo/devel/sgml-common/sgml-common.xibuild new file mode 100644 index 0000000..70fe070 --- /dev/null +++ b/repo/devel/sgml-common/sgml-common.xibuild @@ -0,0 +1,30 @@ +#!/bin/sh + +MAKEDEPS="unzip patch" +DEPS="libxml2 sgml-common" + +PKG_VER=0.6.3 +SOURCE=https://sourceware.org/ftp/docbook-tools/new-trials/SOURCES/sgml-common-$PKG_VER.tgz +ADDITIONAL=" + https://www.linuxfromscratch.org/patches/blfs/svn/sgml-common-$PKG_VER-manpage-1.patch + " + +DESC="Tools for maintaining centralized SGML catalogs." + +prepare() { + patch -Np1 -i sgml-common-$PKG_VER-manpage-1.patch && + autoreconf -f -i +} + +build() { + ./configure --prefix=/usr --sysconfdir=/etc && + make +} + +package () { + make DESTDIR=$PKG_DEST docdir=/usr/share/doc install && + + mkdir -p $PKG_DEST/etc/sgml + mkdir -p /etc/sgml + +} diff --git a/repo/devel/strace.xibuild b/repo/devel/strace.xibuild deleted file mode 100644 index e523146..0000000 --- a/repo/devel/strace.xibuild +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh - -MAKEDEPS="autoconf automake binutils-dev elfutils-dev gawk linux-headers" -DEPS="libelf musl" - -PKG_VER=5.17 -SOURCE=https://github.com/strace/strace/releases/download/v$PKG_VER/strace-$PKG_VER.tar.xz -ADDITIONAL=" -disable-fortify.patch -nlattr-fix.patch -" - -DESC="Diagnostic, debugging and instructional userspace tracer" - -prepare () { - apply_patches -} - -build () { - export CFLAGS="$CFLAGS -Dsigcontext_struct=sigcontext" - ./configure \ - --prefix=/usr \ - --sysconfdir=/etc \ - --mandir=/usr/share/man \ - --localstatedir=/var \ - --enable-mpers=no - make - -} - -package () { - make -j1 DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/strace/disable-fortify.patch b/repo/devel/strace/disable-fortify.patch new file mode 100644 index 0000000..26b2978 --- /dev/null +++ b/repo/devel/strace/disable-fortify.patch @@ -0,0 +1,39 @@ +Subject: [PATCH] don't use fortify-headers on netlink test sources +From: A. Wilcox + +We can't use fortify-headers on netlink tests because it tests what happens +when a buffer overrun occurs. + +--- strace-4.18/tests/netlink_protocol.c.old 2017-07-05 07:08:09.000000000 +0000 ++++ strace-4.18/tests/netlink_protocol.c 2017-08-17 01:09:45.822502012 +0000 +@@ -28,6 +28,8 @@ + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + ++#define _FORTIFY_SOURCE 0 ++ + #include "tests.h" + + #ifdef HAVE_SYS_XATTR_H +--- strace-4.18/tests/netlink_sock_diag.c.old 2017-07-05 07:08:09.000000000 +0000 ++++ strace-4.18/tests/netlink_sock_diag.c 2017-08-17 01:10:00.935807300 +0000 +@@ -27,6 +27,8 @@ + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + ++#define _FORTIFY_SOURCE 0 ++ + #include "tests.h" + #include + #include +--- strace-4.18/tests/nlattr.c.old 2017-07-05 07:08:09.000000000 +0000 ++++ strace-4.18/tests/nlattr.c 2017-08-17 01:10:11.862453682 +0000 +@@ -28,6 +28,8 @@ + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + ++#define _FORTIFY_SOURCE 0 ++ + #include "tests.h" + + #include diff --git a/repo/devel/strace/nlattr-fix.patch b/repo/devel/strace/nlattr-fix.patch new file mode 100644 index 0000000..6d480fa --- /dev/null +++ b/repo/devel/strace/nlattr-fix.patch @@ -0,0 +1,21 @@ +--- strace-4.18/tests/nlattr.c.old 2017-07-05 07:08:09.000000000 +0000 ++++ strace-4.18/tests/nlattr.c 2017-08-17 00:25:26.734218699 +0000 +@@ -61,7 +61,7 @@ + }; + struct msg *msg; + struct nlattr *nla; +- unsigned int msg_len; ++ uint32_t msg_len; + long rc; + + /* fetch fail: len < sizeof(struct nlattr) */ +@@ -259,7 +259,7 @@ + }; + struct msg *msg; + struct nlattr *nla; +- unsigned int msg_len; ++ uint32_t msg_len; + long rc; + + msg_len = NLMSG_SPACE(sizeof(msg->udm)) + sizeof(*nla); + diff --git a/repo/devel/strace/strace.xibuild b/repo/devel/strace/strace.xibuild new file mode 100644 index 0000000..e523146 --- /dev/null +++ b/repo/devel/strace/strace.xibuild @@ -0,0 +1,33 @@ +#!/bin/sh + +MAKEDEPS="autoconf automake binutils-dev elfutils-dev gawk linux-headers" +DEPS="libelf musl" + +PKG_VER=5.17 +SOURCE=https://github.com/strace/strace/releases/download/v$PKG_VER/strace-$PKG_VER.tar.xz +ADDITIONAL=" +disable-fortify.patch +nlattr-fix.patch +" + +DESC="Diagnostic, debugging and instructional userspace tracer" + +prepare () { + apply_patches +} + +build () { + export CFLAGS="$CFLAGS -Dsigcontext_struct=sigcontext" + ./configure \ + --prefix=/usr \ + --sysconfdir=/etc \ + --mandir=/usr/share/man \ + --localstatedir=/var \ + --enable-mpers=no + make + +} + +package () { + make -j1 DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/swig.xibuild b/repo/devel/swig.xibuild deleted file mode 100644 index 5d2471c..0000000 --- a/repo/devel/swig.xibuild +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make autoconf bison" -DEPS="guile gcc musl pcre zlib" - -PKG_VER=4.0.2 -SOURCE=https://downloads.sourceforge.net/swig/swig-$PKG_VER.tar.gz -DESC="A compiler that makes it easy to integrate C and C++ code with scripting languages" - -build () { - ./configure --prefix=/usr - make -} - -package () { - make DESTDIR=$PKG_DEST install - - # backwards compatibility? - ln -s /usr/bin/aclocal $PKG_DEST/usr/bin/aclocal-1.15 -} diff --git a/repo/devel/swig/swig.xibuild b/repo/devel/swig/swig.xibuild new file mode 100644 index 0000000..5d2471c --- /dev/null +++ b/repo/devel/swig/swig.xibuild @@ -0,0 +1,20 @@ +#!/bin/sh + +MAKEDEPS="make autoconf bison" +DEPS="guile gcc musl pcre zlib" + +PKG_VER=4.0.2 +SOURCE=https://downloads.sourceforge.net/swig/swig-$PKG_VER.tar.gz +DESC="A compiler that makes it easy to integrate C and C++ code with scripting languages" + +build () { + ./configure --prefix=/usr + make +} + +package () { + make DESTDIR=$PKG_DEST install + + # backwards compatibility? + ln -s /usr/bin/aclocal $PKG_DEST/usr/bin/aclocal-1.15 +} diff --git a/repo/devel/texinfo.xibuild b/repo/devel/texinfo.xibuild deleted file mode 100644 index b53afe6..0000000 --- a/repo/devel/texinfo.xibuild +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make " -DEPS="ncurses gzip perl sh" - -PKG_VER=6.8 -SOURCE=https://ftp.gnu.org/gnu/texinfo/texinfo-$PKG_VER.tar.xz -DESC="GNU documentation system for reading, writing and converting info pages" - -prepare () { - # fix an issue when building with musl-2.34 or later - sed -e 's/__attribute_nonnull__/__nonnull/' \ - -i gnulib/lib/malloc/dynarray-skeleton.c -} - -build () { - ./configure --prefix=/usr - make -} - -package () { - make DESTDIR=$PKG_DEST install - make TEXMF=$PKG_DEST/usr/share/texmf install-tex -} diff --git a/repo/devel/texinfo/texinfo.xibuild b/repo/devel/texinfo/texinfo.xibuild new file mode 100644 index 0000000..b53afe6 --- /dev/null +++ b/repo/devel/texinfo/texinfo.xibuild @@ -0,0 +1,24 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="ncurses gzip perl sh" + +PKG_VER=6.8 +SOURCE=https://ftp.gnu.org/gnu/texinfo/texinfo-$PKG_VER.tar.xz +DESC="GNU documentation system for reading, writing and converting info pages" + +prepare () { + # fix an issue when building with musl-2.34 or later + sed -e 's/__attribute_nonnull__/__nonnull/' \ + -i gnulib/lib/malloc/dynarray-skeleton.c +} + +build () { + ./configure --prefix=/usr + make +} + +package () { + make DESTDIR=$PKG_DEST install + make TEXMF=$PKG_DEST/usr/share/texmf install-tex +} diff --git a/repo/devel/uthash.xibuild b/repo/devel/uthash.xibuild deleted file mode 100644 index e9dd494..0000000 --- a/repo/devel/uthash.xibuild +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh - -NAME="uthash" -DESC="C macros for hash tables and more" - -MAKEDEPS="make " -DEPS="rxvt-unicode" - -PKG_VER=2.3.0 -SOURCE="https://github.com/troydhanson/uthash/archive/v$PKG_VER.tar.gz" - -package () { - mkdir -p $PKG_DEST/usr/include - install -m 0644 src/*.h $PKG_DEST/usr/include/ -} diff --git a/repo/devel/uthash/uthash.xibuild b/repo/devel/uthash/uthash.xibuild new file mode 100644 index 0000000..e9dd494 --- /dev/null +++ b/repo/devel/uthash/uthash.xibuild @@ -0,0 +1,15 @@ +#!/bin/sh + +NAME="uthash" +DESC="C macros for hash tables and more" + +MAKEDEPS="make " +DEPS="rxvt-unicode" + +PKG_VER=2.3.0 +SOURCE="https://github.com/troydhanson/uthash/archive/v$PKG_VER.tar.gz" + +package () { + mkdir -p $PKG_DEST/usr/include + install -m 0644 src/*.h $PKG_DEST/usr/include/ +} diff --git a/repo/devel/vala.xibuild b/repo/devel/vala.xibuild deleted file mode 100644 index a457cca..0000000 --- a/repo/devel/vala.xibuild +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh - -MAKEDEPS="libxslt bash flex bison gobject-introspection graphviz" -DEPS="glib graphviz musl pkgconf" - -PKG_VER=0.54.7 -SOURCE=https://download.gnome.org/sources/vala/${PKG_VER%.*}/vala-$PKG_VER.tar.xz -DESC="Compiler for the GObject type system" - -prepare () { - sed -i "/constants\/member-access/d" \ - tests/Makefile.in -} - -build () { - ./configure \ - --prefix=/usr - make - -} -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/vala/vala.xibuild b/repo/devel/vala/vala.xibuild new file mode 100644 index 0000000..a457cca --- /dev/null +++ b/repo/devel/vala/vala.xibuild @@ -0,0 +1,23 @@ +#!/bin/sh + +MAKEDEPS="libxslt bash flex bison gobject-introspection graphviz" +DEPS="glib graphviz musl pkgconf" + +PKG_VER=0.54.7 +SOURCE=https://download.gnome.org/sources/vala/${PKG_VER%.*}/vala-$PKG_VER.tar.xz +DESC="Compiler for the GObject type system" + +prepare () { + sed -i "/constants\/member-access/d" \ + tests/Makefile.in +} + +build () { + ./configure \ + --prefix=/usr + make + +} +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/waf.xibuild b/repo/devel/waf.xibuild deleted file mode 100644 index a479282..0000000 --- a/repo/devel/waf.xibuild +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh - -NAME="waf" -DESC="The meta build system" - -MAKEDEPS="" -DEPS="python " - -PKG_VER=2.0.22 -SOURCE="https://waf.io/waf-$PKG_VER" - -package () { - install -Dm755 waf-$PKG_VER "$PKG_DEST"/usr/bin/waf -} diff --git a/repo/devel/waf/waf.xibuild b/repo/devel/waf/waf.xibuild new file mode 100644 index 0000000..a479282 --- /dev/null +++ b/repo/devel/waf/waf.xibuild @@ -0,0 +1,14 @@ +#!/bin/sh + +NAME="waf" +DESC="The meta build system" + +MAKEDEPS="" +DEPS="python " + +PKG_VER=2.0.22 +SOURCE="https://waf.io/waf-$PKG_VER" + +package () { + install -Dm755 waf-$PKG_VER "$PKG_DEST"/usr/bin/waf +} diff --git a/repo/devel/xmlto.xibuild b/repo/devel/xmlto.xibuild deleted file mode 100644 index 0efc381..0000000 --- a/repo/devel/xmlto.xibuild +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh - -MAKEDEPS="make " -DEPS="libxslt" - -PKG_VER=0.0.28 -SOURCE=https://releases.pagure.org/xmlto/xmlto-$PKG_VER.tar.bz2 -DESC="Convert xml to many other formats" - - -build () { - ./configure --prefix=/usr - make -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/xmlto/xmlto.xibuild b/repo/devel/xmlto/xmlto.xibuild new file mode 100644 index 0000000..0efc381 --- /dev/null +++ b/repo/devel/xmlto/xmlto.xibuild @@ -0,0 +1,18 @@ +#!/bin/sh + +MAKEDEPS="make " +DEPS="libxslt" + +PKG_VER=0.0.28 +SOURCE=https://releases.pagure.org/xmlto/xmlto-$PKG_VER.tar.bz2 +DESC="Convert xml to many other formats" + + +build () { + ./configure --prefix=/usr + make +} + +package () { + make DESTDIR=$PKG_DEST install +} diff --git a/repo/devel/xorg-cf-files.xibuild b/repo/devel/xorg-cf-files.xibuild deleted file mode 100644 index a99bcdc..0000000 --- a/repo/devel/xorg-cf-files.xibuild +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh - -NAME="xorg-cf-files" -DESC="Data files for the imake utility" - -MAKEDEPS="make " -DEPS="" - -PKG_VER=1.0.7 -SOURCE="https://xorg.freedesktop.org/releases/individual/util/xorg-cf-files-$PKG_VER.tar.bz2" - -build () { - ./configure \ - --prefix=/usr \ - --bindir=/usr/bin \ - --sysconfdir=/etc \ - --disable-static - make -} - -package () { - make DESTDIR=$PKG_DEST install -} diff --git a/repo/devel/xorg-cf-files/xorg-cf-files.xibuild b/repo/devel/xorg-cf-files/xorg-cf-files.xibuild new file mode 100644 index 0000000..a99bcdc --- /dev/null +++ b/repo/devel/xorg-cf-files/xorg-cf-files.xibuild @@ -0,0 +1,23 @@ +#!/bin/sh + +NAME="xorg-cf-files" +DESC="Data files for the imake utility" + +MAKEDEPS="make " +DEPS="" + +PKG_VER=1.0.7 +SOURCE="https://xorg.freedesktop.org/releases/individual/util/xorg-cf-files-$PKG_VER.tar.bz2" + +build () { + ./configure \ + --prefix=/usr \ + --bindir=/usr/bin \ + --sysconfdir=/etc \ + --disable-static + make +} + +package () { + make DESTDIR=$PKG_DEST install +} -- cgit v1.2.1