changeset 391:bdad6c7981e7

core: convert packages to clang
author David Demelier <markand@malikania.fr>
date Tue, 02 Apr 2019 13:33:22 +0200
parents 94ef1383aa74
children 8017138b628e
files core/acl/acl.sh core/attr/attr.sh core/bash/bash.sh core/bc/bc.sh core/bzip2/bzip2.sh core/coreutils/coreutils.sh core/cpio/cpio.sh core/diffutils/diffutils.sh core/e2fsprogs/e2fsprogs.sh core/ed/ed.sh core/efibootmgr/efibootmgr.sh core/eudev/eudev.sh core/file/file.sh core/findutils/findutils.sh core/gawk/gawk.sh core/gettext/gettext.sh core/grep/grep.sh core/gzip/gzip.sh core/kbd/kbd.sh core/kmod/kmod.sh core/lbzip2/lbzip2.sh core/less/less.sh core/libarchive/libarchive.sh core/libcap/libcap.sh core/lz4/lz4.sh core/lzip/lzip.sh core/mandoc/mandoc.sh core/procps/procps.sh core/rhash/rhash.sh core/sed/sed.sh core/sysklogd/sysklogd.sh core/sysvinit/sysvinit.sh core/tar/tar.sh core/texinfo/texinfo.sh core/tmux/tmux.sh core/tzdata/tzdata.sh core/util-linux/util-linux.sh core/xz/xz.sh core/zsh/zsh.sh core/zstd/zstd.sh
diffstat 40 files changed, 46 insertions(+), 49 deletions(-) [+]
line wrap: on
line diff
--- a/core/acl/acl.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/acl/acl.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -26,7 +26,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/attr/attr.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/attr/attr.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/bash/bash.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/bash/bash.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/bc/bc.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/bc/bc.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/bzip2/bzip2.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/bzip2/bzip2.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -22,7 +22,7 @@
 PKGSUMMARY="data compression program and library"
 PKGDOWNLOAD="https://downloads.sourceforge.net/$PKGNAME/$PKGNAME-$PKGVERSION.tar.gz"
 
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 
 if [ "$(uname -m)" = "x86_64" ]; then
--- a/core/coreutils/coreutils.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/coreutils/coreutils.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/cpio/cpio.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/cpio/cpio.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/diffutils/diffutils.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/diffutils/diffutils.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/e2fsprogs/e2fsprogs.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/e2fsprogs/e2fsprogs.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -26,7 +26,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/ed/ed.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/ed/ed.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -22,7 +22,7 @@
 PKGSUMMARY="GNU stream editor"
 PKGDOWNLOAD="https://ftp.gnu.org/gnu/$PKGNAME/$PKGNAME-$PKGVERSION.tar.lz"
 
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 
 build()
--- a/core/efibootmgr/efibootmgr.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/efibootmgr/efibootmgr.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -23,12 +23,9 @@
 PKGDOWNLOAD="https://github.com/rhboot/$PKGNAME/archive/$PKGVERSION.tar.gz"
 PKGDEPENDS="core/gettext lib/efivar lib/popt"
 
-: ${CC:=gcc}
-: ${CFLAGS:=-O2}
-
 build()
 {
-	rm -rf PKGNAME-$PKGVERSION
+	rm -rf $PKGNAME-$PKGVERSION
 	tar xvaf $PKGVERSION.tar.gz
 	pushd $PKGNAME-$PKGVERSION
 
@@ -36,8 +33,8 @@
 	# https://git.alpinelinux.org/aports/tree/testing/efibootmgr?h=master
 	patch -p1 < ../efivar.patch
 	patch -p1 < ../musl-gettext.patch
-	make PCDIR=/usr/lib/pkgconfig EFIDIR=/boot/efi CC="$CC" CFLAGS="$CFLAGS"
-	make EFIDIR=/boot/efi DESTDIR=$DESTDIR install
+	PCDIR=/usr/lib/pkgconfig EFIDIR=/boot/efi make
+	EFIDIR=/boot/efi DESTDIR=$DESTDIR make install
 
 	popd
 	rm -rf $PKGNAME-$PKGVERSION
--- a/core/eudev/eudev.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/eudev/eudev.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -26,7 +26,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/file/file.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/file/file.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/findutils/findutils.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/findutils/findutils.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/gawk/gawk.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/gawk/gawk.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/gettext/gettext.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/gettext/gettext.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -22,9 +22,9 @@
 PKGSUMMARY="i18n libraries and tools"
 PKGDOWNLOAD="https://ftp.gnu.org/gnu/$PKGNAME/$PKGNAME-$PKGVERSION.tar.xz"
 
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
-: ${CXX:=g++}
+: ${CXX:=clang++}
 : ${CXXFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/grep/grep.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/grep/grep.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -26,7 +26,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/gzip/gzip.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/gzip/gzip.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -24,7 +24,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/kbd/kbd.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/kbd/kbd.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -26,7 +26,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/kmod/kmod.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/kmod/kmod.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -26,7 +26,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/lbzip2/lbzip2.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/lbzip2/lbzip2.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -24,7 +24,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/less/less.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/less/less.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/libarchive/libarchive.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/libarchive/libarchive.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,9 +25,9 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
-: ${CXX:=g++}
+: ${CXX:=clang++}
 : ${CXXFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/libcap/libcap.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/libcap/libcap.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -23,7 +23,7 @@
 PKGDOWNLOAD="https://kernel.org/pub/linux/libs/security/linux-privs/libcap2/$PKGNAME-$PKGVERSION.tar.xz"
 PKGDEPENDS="core/attr lib/linux-headers perl/perl"
 
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 
--- a/core/lz4/lz4.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/lz4/lz4.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -22,7 +22,7 @@
 PKGSUMMARY="fast compression algorithm"
 PKGDOWNLOAD="https://github.com/$PKGNAME/$PKGNAME/archive/v$PKGVERSION.tar.gz"
 
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 
 build()
--- a/core/lzip/lzip.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/lzip/lzip.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -22,7 +22,7 @@
 PKGSUMMARY="lossless file compressor using LZMA"
 PKGDOWNLOAD="https://download.savannah.gnu.org/releases/$PKGNAME/$PKGNAME-$PKGVERSION.tar.gz"
 
-: ${CXX:=g++}
+: ${CXX:=clang++}
 : ${CXXFLAGS:=-O2}
 
 build()
--- a/core/mandoc/mandoc.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/mandoc/mandoc.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -23,7 +23,7 @@
 PKGDOWNLOAD="http://mandoc.bsd.lv/snapshots/$PKGNAME-$PKGVERSION.tar.gz"
 PKGDEPENDS="lib/zlib"
 
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/procps/procps.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/procps/procps.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -27,9 +27,9 @@
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
 : ${CTARGET:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
-: ${CXX:=g++}
+: ${CXX:=clang++}
 : ${CXXFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/rhash/rhash.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/rhash/rhash.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 PKGPROTECT="etc/rhashrc"
 
 : ${CTARGET:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${NLS:=yes}
--- a/core/sed/sed.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/sed/sed.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/sysklogd/sysklogd.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/sysklogd/sysklogd.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/sysvinit/sysvinit.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/sysvinit/sysvinit.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -27,7 +27,7 @@
             etc/rc.shutdown
             etc/rc.start"
 
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 
 build()
--- a/core/tar/tar.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/tar/tar.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/texinfo/texinfo.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/texinfo/texinfo.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -26,7 +26,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/tmux/tmux.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/tmux/tmux.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/tzdata/tzdata.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/tzdata/tzdata.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -23,7 +23,7 @@
 PKGDOWNLOAD="https://www.iana.org/time-zones/repository/releases/tzcode$PKGVERSION.tar.gz
              https://www.iana.org/time-zones/repository/releases/tzdata$PKGVERSION.tar.gz"
 
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 
--- a/core/util-linux/util-linux.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/util-linux/util-linux.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/xz/xz.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/xz/xz.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -25,7 +25,7 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/zsh/zsh.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/zsh/zsh.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -26,9 +26,9 @@
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O2}
-: ${CXX:=g++}
+: ${CXX:=clang++}
 : ${CXXFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
--- a/core/zstd/zstd.sh	Tue Apr 02 20:03:00 2019 +0200
+++ b/core/zstd/zstd.sh	Tue Apr 02 13:33:22 2019 +0200
@@ -22,7 +22,7 @@
 PKGSUMMARY="fast real-time compression algorithm"
 PKGDOWNLOAD="https://github.com/facebook/zstd/releases/download/v$PKGVERSION/$PKGNAME-$PKGVERSION.tar.gz"
 
-: ${CC:=gcc}
+: ${CC:=clang}
 : ${CFLAGS:=-O3}                # upstream default
 
 build()