Przeglądaj źródła

Merge branch 'tomop'

git-svn-id: http://trac.vinelinux.org/repos/projects/specs@12228 ec354946-7b23-47d6-9f5a-488ba84defc7
tomop 4 lat temu
rodzic
commit
6883326452
6 zmienionych plików z 341 dodań i 221 usunięć
  1. 89 81
      f/firefox/firefox-vl.spec
  2. 92 62
      l/llvm/llvm-vl.spec
  3. 31 16
      n/nodejs/nodejs-vl.spec
  4. 5 2
      n/nspr/nspr-vl.spec
  5. 10 8
      n/nss/nss-vl.spec
  6. 114 52
      r/rust/rust-vl.spec

+ 89 - 81
f/firefox/firefox-vl.spec

@@ -1,15 +1,17 @@
-%bcond_without clang
+%bcond_with clang
 
 
 # do not include minor version number in MOZILLA_FIVE_HOME
 # do not include minor version number in MOZILLA_FIVE_HOME
-%global ffmajor 60.7
-%global geckomajor 60.7
-%global ffminor 2
+%global ffmajor 68.1
+%global geckomajor 68.1
+%global ffminor 0
 %global ffversion %{ffmajor}%{?ffminor:.%{ffminor}}
 %global ffversion %{ffmajor}%{?ffminor:.%{ffminor}}
 %define ffdir %{_libdir}/firefox
 %define ffdir %{_libdir}/firefox
 %define tarballdir firefox-%{ffversion}
 %define tarballdir firefox-%{ffversion}
 %global mozappdir     %{_libdir}/%{name}
 %global mozappdir     %{_libdir}/%{name}
 %global langpackdir   %{mozappdir}/distribution/extensions
 %global langpackdir   %{mozappdir}/distribution/extensions
 
 
+%global nodewrapperdir %{_builddir}/%{tarballdir}/bin
+
 %define firefox_app_id \{ec8030f7-c20a-464f-9b0e-13a3a9e97384\}
 %define firefox_app_id \{ec8030f7-c20a-464f-9b0e-13a3a9e97384\}
 %define homepage https://vinelinux.org/
 %define homepage https://vinelinux.org/
 
 
@@ -42,10 +44,11 @@ Release:        %{ffrelease}
 URL:            https://www.mozilla.org/ja/
 URL:            https://www.mozilla.org/ja/
 License:        MPL/LGPL
 License:        MPL/LGPL
 Group:          Applications/Internet
 Group:          Applications/Internet
-Source0:        firefox-%{version}esr.source.tar.xz
+Source0:        https://archive.mozilla.org/pub/firefox/releases/%{version}esr/source/firefox-%{version}esr.source.tar.xz
+Source2:        cbindgen-vendor.tar.xz
 
 
-Source230:       mozconfig-firefox-vine6
-Source240:       mozconfig-firefox-vine7
+Source230:      mozconfig-firefox-vine6
+Source240:      mozconfig-firefox-vine7
 
 
 Source11:       firefox-vine-default-bookmarks.html
 Source11:       firefox-vine-default-bookmarks.html
 Source12:       firefox-vine-default-prefs.js
 Source12:       firefox-vine-default-prefs.js
@@ -57,9 +60,13 @@ Source25:       firefox.desktop
 Source26:       firefox-safe-mode.desktop
 Source26:       firefox-safe-mode.desktop
 Source27:       firefox-safe-mode.vine.sh
 Source27:       firefox-safe-mode.vine.sh
 Source30:       firefox.1
 Source30:       firefox.1
+Source32:       node-stdout-nonblocking-wrapper
 Source50:       firefox-xremote-client.sh.in
 Source50:       firefox-xremote-client.sh.in
 Source100:      find-external-requires
 Source100:      find-external-requires
 
 
+# for newer rust
+Source900:      https://raw.githubusercontent.com/servo/rust-cssparser/master/src/parser.rs
+
 # locale sources
 # locale sources
 %define MOZ_BUILD_LOCALES "ja"
 %define MOZ_BUILD_LOCALES "ja"
 Source1000:     firefox-%{ffversion}esr-langpacks.tar.xz
 Source1000:     firefox-%{ffversion}esr-langpacks.tar.xz
@@ -67,30 +74,29 @@ Source1010:     firefox-unofficial-branding-fx.tar.xz
 #
 #
 Source2000:     firefox-searchplugins-6.0-ja.tar.bz2
 Source2000:     firefox-searchplugins-6.0-ja.tar.bz2
 
 
+Source3000:     firefox.metainfo.xml
+
 # build patches
 # build patches
 Patch4:         build-mozconfig-fix.patch
 Patch4:         build-mozconfig-fix.patch
-# Always feel lucky for unsupported platforms:
-# https://bugzilla.mozilla.org/show_bug.cgi?id=1347128
-Patch37:        build-jit-atomic-always-lucky.patch
 
 
 # patches from fedora
 # patches from fedora
 Patch215:        firefox-enable-addons.patch
 Patch215:        firefox-enable-addons.patch
 Patch219:        rhbz-1173156.patch
 Patch219:        rhbz-1173156.patch
 Patch224:        mozilla-1170092.patch
 Patch224:        mozilla-1170092.patch
-Patch225:        mozilla-1005640-accept-lang.patch
 Patch230:        rhbz-1503632-nss.patch
 Patch230:        rhbz-1503632-nss.patch
 
 
 # upstream patch
 # upstream patch
 Patch402:        mozilla-1196777.patch
 Patch402:        mozilla-1196777.patch
-Patch406:        mozilla-256180.patch
-Patch413:        mozilla-1353817.patch
-Patch415:        mozilla-1436242.patch
-
+Patch412:        mozilla-1337988.patch
+#Patch413:        mozilla-1353817.patch
+Patch419:        mozilla-1568569.patch
+Patch420:        mozilla-1566876-webrtc-ind.patch
+Patch421:        mozilla-1579023.patch
 
 
 # customization patches
 # customization patches
 
 
 ## Vine patch
 ## Vine patch
-#Patch1000:      firefox-19.0-disable-pdfjs.patch
+Patch1000:      ignore-python-unicode-exception.patch
 
 
 # vine customization patch
 # vine customization patch
 Patch2000:      firefox-47.0.1-vine.patch
 Patch2000:      firefox-47.0.1-vine.patch
@@ -100,9 +106,8 @@ BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root
 BuildRequires:	alsa-lib-devel
 BuildRequires:	alsa-lib-devel
 BuildRequires:  autoconf213
 BuildRequires:  autoconf213
 BuildRequires:  bzip2-devel
 BuildRequires:  bzip2-devel
-%if %{with clang}
+# cbindgen needs clang
 BuildRequires:  clang-devel, lld, llvm-devel
 BuildRequires:  clang-devel, lld, llvm-devel
-%endif
 BuildRequires:  curl-devel
 BuildRequires:  curl-devel
 BuildRequires:  desktop-file-utils
 BuildRequires:  desktop-file-utils
 BuildRequires:  freetype2-devel
 BuildRequires:  freetype2-devel
@@ -121,6 +126,8 @@ BuildRequires:  libpng-devel
 BuildRequires:	libXt-devel
 BuildRequires:	libXt-devel
 BuildRequires:	libXrender-devel
 BuildRequires:	libXrender-devel
 BuildRequires:  libXScrnSaver-devel
 BuildRequires:  libXScrnSaver-devel
+BuildRequires:  nasm
+BuildRequires:  nodejs > 10.0.0
 BuildRequires:  pango-devel
 BuildRequires:  pango-devel
 BuildRequires:  pulseaudio-libs-devel
 BuildRequires:  pulseaudio-libs-devel
 %if %{build_vine7}
 %if %{build_vine7}
@@ -130,7 +137,8 @@ BuildRequires:  python
 BuildRequires:  python27-devel >= 2.7.3
 BuildRequires:  python27-devel >= 2.7.3
 BuildRequires:  python27 >= 2.7.3
 BuildRequires:  python27 >= 2.7.3
 %endif
 %endif
-BuildRequires:  rust, cargo
+BuildRequires:  rust >= 1.34.0
+BuildRequires:  cargo
 BuildRequires:  startup-notification-devel
 BuildRequires:  startup-notification-devel
 BuildRequires:  unzip
 BuildRequires:  unzip
 BuildRequires:  wget
 BuildRequires:  wget
@@ -172,15 +180,12 @@ FX ウェブブラウザは Mozilla テクノロジーをベースとしたオ
 %setup -q -n %{name}-%{version} -c
 %setup -q -n %{name}-%{version} -c
 cd %{tarballdir}
 cd %{tarballdir}
 
 
-%patch37 -p1 -b .jit-atomic-lucky
-
 %patch4  -p1 -b .build-mozconfig-fix
 %patch4  -p1 -b .build-mozconfig-fix
 
 
 # Fedora patches
 # Fedora patches
 %patch215 -p1 -b .addons
 %patch215 -p1 -b .addons
 %patch219 -p1 -b .rhbz-1173156
 %patch219 -p1 -b .rhbz-1173156
 %patch224 -p1 -b .1170092
 %patch224 -p1 -b .1170092
-%patch225 -p1 -b .1005640-accept-lang
 
 
 # This ensures no migration of certdb to sqlite on the RHEL6 and RHEL7.
 # This ensures no migration of certdb to sqlite on the RHEL6 and RHEL7.
 # This needs to stay for the future releases
 # This needs to stay for the future releases
@@ -189,12 +194,13 @@ cd %{tarballdir}
 %endif
 %endif
 
 
 %patch402 -p1 -b .1196777
 %patch402 -p1 -b .1196777
-%patch406 -p1 -b .256180
-%patch413 -p1 -b .1353817
-%patch415 -p1 -b .1436242
+%patch419 -p1 -b .1568569
+%patch420 -p1 -b .1566876-webrtc-ind
+%patch421 -p1 -b .1579023
 
 
 
 
-#patch2000 -p1 -b .vine
+%patch1000 -p0 -b .ignore-exception
+
 perl -pi \
 perl -pi \
 -e 's|pref\("extensions.langpacks.signatures.required".*$|pref("extensions.langpacks.signatures.required", false);|' \
 -e 's|pref\("extensions.langpacks.signatures.required".*$|pref("extensions.langpacks.signatures.required", false);|' \
 browser/app/profile/firefox.js
 browser/app/profile/firefox.js
@@ -213,6 +219,9 @@ perl -pi \
 -e 's|pref\("startup.homepage_welcome_url".*$|pref("startup.homepage_welcome_url", "https://vinelinux.org/");|' \
 -e 's|pref\("startup.homepage_welcome_url".*$|pref("startup.homepage_welcome_url", "https://vinelinux.org/");|' \
 browser/branding/unofficial/locales/browserconfig.properties
 browser/branding/unofficial/locales/browserconfig.properties
 
 
+# replace source for newer rust
+cp -f %{SOURCE900} ./third_party/rust/cssparser/src/
+sed -i -e 's/"files":{[^}]*}/"files":{ }/' ./third_party/rust/cssparser/.cargo-checksum.json
 
 
 %{__rm} -f .mozconfig
 %{__rm} -f .mozconfig
 
 
@@ -232,9 +241,7 @@ echo "ac_add_options --disable-debug" >> .mozconfig
 echo "ac_add_options --enable-linker=lld" >> .mozconfig
 echo "ac_add_options --enable-linker=lld" >> .mozconfig
 %endif
 %endif
 
 
-#ifarch %{ix86}
-#echo "ac_add_options --disable-stylo" >> .mozconfig
-#endif
+echo 'export NODEJS="%{nodewrapperdir}/node-stdout-nonblocking-wrapper"' >> .mozconfig
 
 
 # Remove executable bit to make brp-mangle-shebangs happy.
 # Remove executable bit to make brp-mangle-shebangs happy.
 chmod -x third_party/rust/itertools/src/lib.rs
 chmod -x third_party/rust/itertools/src/lib.rs
@@ -252,13 +259,35 @@ chmod -x third_party/rust/itertools/src/lib.rs
 
 
 %build
 %build
 cd %{tarballdir}
 cd %{tarballdir}
-autoconf-2.13
+
+# install bundled cbindgen
+mkdir -p my_rust_vendor
+cd my_rust_vendor
+%{__tar} xf %{SOURCE2}
+cd -
+mkdir -p .cargo
+cat > .cargo/config <<EOL
+[source.crates-io]
+replace-with = "vendored-sources"
+
+[source.vendored-sources]
+directory = "`pwd`/my_rust_vendor"
+EOL
+
+env CARGO_HOME=.cargo cargo install cbindgen
+export PATH=`pwd`/.cargo/bin:$PATH
+
+mkdir %{nodewrapperdir} || :
+cp %{SOURCE32} %{nodewrapperdir}/ || :
+
+#autoconf-2.13
 
 
 MOZ_OPT_FLAGS=$(echo "$RPM_OPT_FLAGS" | \
 MOZ_OPT_FLAGS=$(echo "$RPM_OPT_FLAGS" | \
                 %{__sed} -e 's/-Wall//')
                 %{__sed} -e 's/-Wall//')
-export RPM_OPT_FLAGS=$MOZ_OPT_FLAGS
-export CFLAGS=$MOZ_OPT_FLAGS
-export CXXFLAGS=$MOZ_OPT_FLAGS
+MOZ_OPT_FLAGS=$(echo "$MOZ_OPT_FLAGS" | %{__sed} -e 's/-Werror=format-security//')
+MOZ_OPT_FLAGS="$MOZ_OPT_FLAGS -fpermissive"
+MOZ_OPT_FLAGS="$MOZ_OPT_FLAGS -fPIC -Wl,-z,relro -Wl,-z,now"
+MOZ_OPT_FLAGS=$(echo "$MOZ_OPT_FLAGS" | %{__sed} -e 's/-g/-g0/')
 
 
 export MOZILLA_OFFICIAL=1
 export MOZILLA_OFFICIAL=1
 export BUILD_OFFICIAL=1
 export BUILD_OFFICIAL=1
@@ -274,8 +303,22 @@ export LLVM_PROFDATA="llvm-profdata"
 export AR="llvm-ar"
 export AR="llvm-ar"
 export NM="llvm-nm"
 export NM="llvm-nm"
 export RANLIB="llvm-ranlib"
 export RANLIB="llvm-ranlib"
+MOZ_OPT_FLAGS="$MOZ_OPT_FLAGS -Wno-ignored-optimization-argument"
+%else
+export CC=gcc
+export CXX=g++
+export AR="gcc-ar"
+export NM="gcc-nm"
+export RANLIB="gcc-ranlib"
+MOZ_LINK_FLAGS="-Wl,--no-keep-memory -Wl,--reduce-memory-overheads"
 %endif
 %endif
 
 
+export RPM_OPT_FLAGS=$MOZ_OPT_FLAGS
+export CFLAGS=$MOZ_OPT_FLAGS
+export CXXFLAGS=$MOZ_OPT_FLAGS
+export LDFLAGS=$MOZ_LINK_FLAGS
+export RUSTFLAGS="-Cdebuginfo=0"
+
 MOZ_SMP_FLAGS=-j1
 MOZ_SMP_FLAGS=-j1
 # On x86 architectures, Mozilla can build up to 4 jobs at once in parallel,
 # On x86 architectures, Mozilla can build up to 4 jobs at once in parallel,
 # however builds tend to fail on other arches when building in parallel.
 # however builds tend to fail on other arches when building in parallel.
@@ -290,22 +333,10 @@ MOZ_SMP_FLAGS=-j1
 sed -i 's/\(MOZ_PKG_FATAL_WARNINGS =\).*/\1 0/' \
 sed -i 's/\(MOZ_PKG_FATAL_WARNINGS =\).*/\1 0/' \
   browser/installer/Makefile.in &&
   browser/installer/Makefile.in &&
 
 
-%if 0
-# https://bugzilla.mozilla.org/show_bug.cgi?id=824381
-mkdir -p js/src/.deps
-
-find security/nss/lib -name "*.def" | while read i
-do
-  mv $i $i.orig
-  grep -v ';-' $i.orig | \
-    sed -e 's,;+,,' -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,;,' > $i
-done
-%endif
-
 export MOZ_MAKE_FLAGS="$MOZ_SMP_FLAGS"
 export MOZ_MAKE_FLAGS="$MOZ_SMP_FLAGS"
 #export MOZ_SERVICES_SYNC="1"
 #export MOZ_SERVICES_SYNC="1"
 #export STRIP=/bin/true
 #export STRIP=/bin/true
-./mach build -v
+MOZ_NOSPAM=1 ./mach build
 
 
 #export LDFLAGS="-Wl,-rpath,%{ffdir}"
 #export LDFLAGS="-Wl,-rpath,%{ffdir}"
 #%__make -f client.mk build MOZ_MAKE_FLAGS="$MOZ_SMP_FLAGS"
 #%__make -f client.mk build MOZ_MAKE_FLAGS="$MOZ_SMP_FLAGS"
@@ -355,38 +386,8 @@ done
 #
 #
 # See http://www.freedesktop.org/software/appstream/docs/ for more details.
 # See http://www.freedesktop.org/software/appstream/docs/ for more details.
 #
 #
-%{__mkdir_p} %{buildroot}%{_datadir}/appdata
-cat > %{buildroot}%{_datadir}/appdata/%{name}.appdata.xml <<EOF
-<?xml version="1.0" encoding="UTF-8"?>
-<!-- Copyright 2014 Richard Hughes <richard@hughsie.com> -->
-<!--
-BugReportURL: https://bugzilla.mozilla.org/show_bug.cgi?id=1071061
-SentUpstream: 2014-09-22
--->
-<application>
-  <id type="desktop">firefox.desktop</id>
-  <metadata_license>CC0-1.0</metadata_license>
-  <description>
-    <p>
-      Bringing together all kinds of awesomeness to make browsing better for you.
-      Get to your favorite sites quickly – even if you don’t remember the URLs.
-      Type your term into the location bar (aka the Awesome Bar) and the autocomplete
-      function will include possible matches from your browsing history, bookmarked
-      sites and open tabs.
-    </p>
-    <!-- FIXME: Needs another couple of paragraphs -->
-  </description>
-  <url type="homepage">http://www.mozilla.org/</url>
-  <screenshots>
-    <screenshot type="default">https://raw.githubusercontent.com/hughsie/fedora-appstream/master/screenshots-extra/firefox/a.png</screenshot>
-    <screenshot>https://raw.githubusercontent.com/hughsie/fedora-appstream/master/screenshots-extra/firefox/b.png</screenshot>
-    <screenshot>https://raw.githubusercontent.com/hughsie/fedora-appstream/master/screenshots-extra/firefox/c.png</screenshot>
-  </screenshots>
-  <!-- FIXME: change this to an upstream email address for spec updates
-  <updatecontact>someone_who_cares@upstream_project.org</updatecontact>
-   -->
-</application>
-EOF
+%{__mkdir_p} %{buildroot}%{_datadir}/metainfo
+install -m644 %{SOURCE3000} %{buildroot}%{_datadir}/metainfo/%{name}.metainfo.xml
 
 
 %{__install} -p -m 755 %{SOURCE21} $RPM_BUILD_ROOT%{_bindir}/firefox
 %{__install} -p -m 755 %{SOURCE21} $RPM_BUILD_ROOT%{_bindir}/firefox
 %{__install} -p -m 755 %{SOURCE27} $RPM_BUILD_ROOT%{_bindir}/firefox-safe-mode
 %{__install} -p -m 755 %{SOURCE27} $RPM_BUILD_ROOT%{_bindir}/firefox-safe-mode
@@ -407,8 +408,8 @@ for langpack in `ls firefox-langpacks/*.xpi`; do
   unzip -qq $langpack -d $extensionID
   unzip -qq $langpack -d $extensionID
   find $extensionID -type f | xargs chmod 644
   find $extensionID -type f | xargs chmod 644
 
 
-  sed -i -e "s|browser.startup.homepage.*$|browser.startup.homepage=%{homepage}|g;" \
-     $extensionID/browser/chrome/$language/locale/branding/browserconfig.properties
+#  sed -i -e "s|browser.startup.homepage.*$|browser.startup.homepage=%{homepage}|g;" \
+#     $extensionID/browser/chrome/$language/locale/branding/browserconfig.properties
 
 
   if [ $language = "ja" ]; then
   if [ $language = "ja" ]; then
     sed -i \
     sed -i \
@@ -516,13 +517,20 @@ fi
 %{_datadir}/applications/vine-%{name}.desktop
 %{_datadir}/applications/vine-%{name}.desktop
 %{_datadir}/applications/vine-%{name}-safe-mode.desktop
 %{_datadir}/applications/vine-%{name}-safe-mode.desktop
 %{_datadir}/pixmaps/firefox.png
 %{_datadir}/pixmaps/firefox.png
-%{_datadir}/appdata/firefox.appdata.xml
+%{_datadir}/metainfo/firefox.metainfo.xml
 %{ffdir}
 %{ffdir}
 %{_libdir}/mozilla
 %{_libdir}/mozilla
 
 
 #---------------------------------------------------------------------
 #---------------------------------------------------------------------
 
 
 %changelog
 %changelog
+* Sun Sep 29 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 68.1.0-1
+- updated to 68.1.0.
+- dropped Patch37, 225 and 406-415.
+- imported Patch419-421 from upstream (via rawhide).
+- updated Patch224.
+- added Patch1000.
+
 * Sat Jun 22 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 60.7.2-1
 * Sat Jun 22 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 60.7.2-1
 - updated to 60.7.2.
 - updated to 60.7.2.
 
 

+ 92 - 62
l/llvm/llvm-vl.spec

@@ -1,3 +1,5 @@
+%bcond_with test
+
 %define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
 %define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
 
 
 %define ver_suffix %(echo "%{version}" | cut -d . -f 1)
 %define ver_suffix %(echo "%{version}" | cut -d . -f 1)
@@ -19,7 +21,7 @@
 
 
 Name:           llvm
 Name:           llvm
 Version:        9.0.0
 Version:        9.0.0
-Release:        1%{?_dist_release}
+Release:        2%{?_dist_release}
 Summary:        The Low Level Virtual Machine
 Summary:        The Low Level Virtual Machine
 Summary(ja):    LLVM - 低レベルバーチャルマシン
 Summary(ja):    LLVM - 低レベルバーチャルマシン
 
 
@@ -46,20 +48,25 @@ Source11:        clang-config.h
 
 
 # patches
 # patches
 
 
-# recognize s390 as SystemZ when configuring build
 # llvm
 # llvm
-Patch3:         0001-CMake-Split-static-library-exports-into-their-own-ex.patch
-Patch7:         0001-Filter-out-cxxflags-not-supported-by-clang.patch
-Patch12:        0001-unittests-Don-t-install-TestPlugin.so.patch
-Patch15:        0001-Don-t-set-rpath-when-installing.patch
+Patch0:         0001-Filter-out-cxxflags-not-supported-by-clang.patch
+# TODO: I'm not sure why this is needed.  Could be a change in newer version
+# of gold.
+Patch1:         0001-Pass-target-to-gold-linker-to-avoid-faliures-on-i686.patch
+Patch2:         0001-CMake-Split-static-library-exports-into-their-own-ex.patch
+Patch3:         0001-CMake-Split-test-binary-exports-into-their-own-expor.patch
 
 
 # clang
 # clang
-Patch100:         0001-lit.cfg-Add-hack-so-lit-can-find-not-and-FileCheck.patch
-Patch101:         0001-GCC-compatibility-Ignore-fstack-clash-protection.patch
-Patch102:         0001-Driver-Prefer-vendor-supplied-gcc-toolchain.patch
+Patch100:       0002-gtest-reorg.patch
+Patch101:       0001-Fix-uninitialized-value-in-ABIArgInfo.patch
+Patch102:       0001-ToolChain-Add-lgcc_s-to-the-linker-flags-when-using-.patch
+Patch103:       0001-Fix-Driver-modules.cpp-test-to-work-when-build-direc.patch
+
+# compiler-rt
+Patch200:       0001-PATCH-std-thread-copy.patch
 
 
 # lld
 # lld
-Patch400:         0001-CMake-Check-for-gtest-headers-even-if-lit.py-is-not-.patch
+Patch400:       0001-CMake-Check-for-gtest-headers-even-if-lit.py-is-not-.patch
 
 
 # Vine Patch
 # Vine Patch
 Patch1000: clang-3.8.1-driver-ld.gold.patch
 Patch1000: clang-3.8.1-driver-ld.gold.patch
@@ -69,9 +76,13 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
 
 
 BuildRequires:  binutils-devel
 BuildRequires:  binutils-devel
 BuildRequires:  cmake
 BuildRequires:  cmake
+BuildRequires:  ninja
 BuildRequires:  bison
 BuildRequires:  bison
+BuildRequires:  python3
+BuildRequires:  python3-rpm-macros
 BuildRequires:  chrpath
 BuildRequires:  chrpath
 BuildRequires:  flex
 BuildRequires:  flex
+BuildRequires:  git
 BuildRequires:  gcc-c++ >= 3.4
 BuildRequires:  gcc-c++ >= 3.4
 BuildRequires:  groff
 BuildRequires:  groff
 BuildRequires:  libffi-devel
 BuildRequires:  libffi-devel
@@ -85,7 +96,7 @@ BuildRequires:  ocaml-ctypes
 BuildRequires:  ocaml-ounit
 BuildRequires:  ocaml-ounit
 %endif
 %endif
 # for DejaGNU test suite
 # for DejaGNU test suite
-BuildRequires:  dejagnu tcl-devel python
+BuildRequires:  dejagnu tcl-devel
 %if %{with doxygen}
 %if %{with doxygen}
 BuildRequires:  doxygen graphviz
 BuildRequires:  doxygen graphviz
 %endif
 %endif
@@ -94,7 +105,7 @@ BuildRequires:  perl
 # lldb
 # lldb
 BuildRequires:  swig
 BuildRequires:  swig
 BuildRequires:  libedit-devel
 BuildRequires:  libedit-devel
-BuildRequires:  python-devel >= 2.7
+BuildRequires:  python3-devel
 # lld
 # lld
 BuildRequires: ncurses-devel
 BuildRequires: ncurses-devel
 BuildRequires: zlib-devel
 BuildRequires: zlib-devel
@@ -217,7 +228,7 @@ Group:          Development/Languages
 Requires:       clang = %{version}-%{release}
 Requires:       clang = %{version}-%{release}
 # not picked up automatically since files are currently not instaled
 # not picked up automatically since files are currently not instaled
 # in standard Python hierarchies yet
 # in standard Python hierarchies yet
-Requires:       python
+Requires:       python3
 
 
 %description -n clang-analyzer
 %description -n clang-analyzer
 The Clang Static Analyzer consists of both a source code analysis
 The Clang Static Analyzer consists of both a source code analysis
@@ -225,12 +236,12 @@ framework and a standalone tool that finds bugs in C and Objective-C
 programs. The standalone tool is invoked from the command-line, and is
 programs. The standalone tool is invoked from the command-line, and is
 intended to run in tandem with a build of a project or code base.
 intended to run in tandem with a build of a project or code base.
 
 
-%package -n python-clang
-Summary: Python bindings for clang
+%package -n python3-clang
+Summary: Python3 bindings for clang
 Requires: %{name}%{ver_suffix}-libs%{?_isa} = %{version}-%{release}
 Requires: %{name}%{ver_suffix}-libs%{?_isa} = %{version}-%{release}
-Requires: python
-%description -n python-clang
-Python bindings for clang
+Requires: python3
+%description -n python3-clang
+Python3 bindings for clang
 
 
 
 
 #%package -n clang-doc
 #%package -n clang-doc
@@ -319,14 +330,14 @@ API documentation for the Clang compiler.
 %endif
 %endif
 
 
 
 
-%package -n python-lldb
-Summary:        Python module for LLDB
-Summary(ja):    LLDB用Pythonモジュール
+%package -n python3-lldb
+Summary:        Python3 module for LLDB
+Summary(ja):    LLDB用Python3モジュール
 BuildRequires:  python-devel
 BuildRequires:  python-devel
 Requires:       python-six
 Requires:       python-six
 
 
-%description -n python-lldb
-The package contains the LLDB Python module.
+%description -n python3-lldb
+The package contains the LLDB Python3 module.
 
 
 
 
 %package -n libomp
 %package -n libomp
@@ -398,10 +409,10 @@ Shared libraries for the LLVM compiler infrastructure.
 %prep
 %prep
 %setup -q -a1 -a2 -a3 -a4 -a6 -n llvm-%{version}.src 
 %setup -q -a1 -a2 -a3 -a4 -a6 -n llvm-%{version}.src 
 
 
-%patch3 -p1
-#%patch7 -p1
-#%patch12 -p1
-%patch15 -p1
+#%patch0 -p2
+#%patch1 -p2
+#%patch2 -p2
+##patch3 -p2
 
 
 rm -rf tools/clang tools/lld tools/lldb projects/compiler-rt
 rm -rf tools/clang tools/lld tools/lldb projects/compiler-rt
 mv cfe-%{version}.src tools/clang
 mv cfe-%{version}.src tools/clang
@@ -416,13 +427,18 @@ mv clang-tools-extra-%{version}.src tools/clang/tools/extra
 %endif
 %endif
 
 
 pushd tools/clang
 pushd tools/clang
-%patch100 -p1 -b .lit-search-path
-%patch101 -p1 -b .fstack-clash-protection
-#patch102 -p1 -b .vendor-gcc
+##patch100 -p1
+#%patch101 -p2
+#%patch102 -p1
+#%patch103 -p2
+popd
+
+pushd projects/compiler-rt
+#%patch200 -p1
 popd
 popd
 
 
 pushd tools/lld
 pushd tools/lld
-%patch400 -p1
+#%patch400 -p1
 popd
 popd
 
 
 # Vine Linux
 # Vine Linux
@@ -433,8 +449,8 @@ popd
 %endif
 %endif
 #%patch1002 -p1 -b .driver-vine
 #%patch1002 -p1 -b .driver-vine
 
 
-sed -i -e 's/"i686-linux-gnu",/"i686-linux-gnu","i686-vine-linux",/' tools/clang/lib/Driver/ToolChains/Gnu.cpp
-sed -i -e 's/"x86_64-linux-gnu",/"x86_64-linux-gnu","x86_64-vine-linux",/' tools/clang/lib/Driver/ToolChains/Gnu.cpp
+sed -i -e 's/"i686-linux-gnu",/"i686-linux-gnu","i686-vine-linux","i686-vine-linux-gnu",/' tools/clang/lib/Driver/ToolChains/Gnu.cpp
+sed -i -e 's/"x86_64-linux-gnu",/"x86_64-linux-gnu","x86_64-vine-linux","x86_64-vine-linux-gnu",/' tools/clang/lib/Driver/ToolChains/Gnu.cpp
 
 
 sed -i -e 's/"ld"/"ld.gold"/' tools/clang/include/clang/Driver/ToolChain.h
 sed -i -e 's/"ld"/"ld.gold"/' tools/clang/include/clang/Driver/ToolChain.h
 
 
@@ -442,25 +458,33 @@ sed -i -e 's/"ld"/"ld.gold"/' tools/clang/include/clang/Driver/ToolChain.h
 mkdir build
 mkdir build
 cd build
 cd build
 
 
-CFLAGS="%{optflags} -fno-strict-aliasing -Wno-error=format-security -fPIC"
-CXXFLAGS="%{optflags} -fno-strict-aliasing -Wno-error=format-security -fPIC -std=c++11"
-TMP_PWD=$(pwd)
-LDFLAGS="%{?__global_ldflags} -L$TMP_PWD/%{_lib} -lpthread -ldl"
+%ifarch s390 s390x %{arm} %ix86
+# Decrease debuginfo verbosity to reduce memory consumption during final library linking
+%global optflags %(echo %{optflags} | sed 's/-g /-g1 /')
+%endif
+
+#CFLAGS="%{optflags} -fno-strict-aliasing -Wno-error=format-security -fPIC"
+#CXXFLAGS="%{optflags} -fno-strict-aliasing -Wno-error=format-security -fPIC -std=c++11"
+#TMP_PWD=$(pwd)
+#LDFLAGS="%{?__global_ldflags} -L$TMP_PWD/%{_lib} -lpthread -ldl"
 
 
 %cmake .. \
 %cmake .. \
+        -GNinja \
         -DBUILD_SHARED_LIBS:BOOL=OFF \
         -DBUILD_SHARED_LIBS:BOOL=OFF \
+        -DLLVM_PARALLEL_LINK_JOBS=1 \
         -DCMAKE_BUILD_TYPE=Release \
         -DCMAKE_BUILD_TYPE=Release \
-        -DCMAKE_SHARED_LINKER_FLAGS="-Wl,-Bsymbolic -static-libstdc++" \
+        -DCMAKE_INSTALL_RPATH=";" \
 %if 0%{?__isa_bits} == 64
 %if 0%{?__isa_bits} == 64
         -DLLVM_LIBDIR_SUFFIX=64 \
         -DLLVM_LIBDIR_SUFFIX=64 \
 %else
 %else
         -DLLVM_LIBDIR_SUFFIX= \
         -DLLVM_LIBDIR_SUFFIX= \
 %endif
 %endif
-        -DLLVM_TARGETS_TO_BUILD="X86;AMDGPU;NVPTX;BPF;ARM;AArch64" \
+        -DLLVM_TARGETS_TO_BUILD=all \
         -DLLVM_ENABLE_LIBCXX:BOOL=OFF \
         -DLLVM_ENABLE_LIBCXX:BOOL=OFF \
         -DLLVM_ENABLE_ZLIB:BOOL=ON \
         -DLLVM_ENABLE_ZLIB:BOOL=ON \
         -DLLVM_ENABLE_FFI:BOOL=ON \
         -DLLVM_ENABLE_FFI:BOOL=ON \
         -DLLVM_ENABLE_RTTI:BOOL=ON \
         -DLLVM_ENABLE_RTTI:BOOL=ON \
+        -DLLVM_ENABLE_EH=ON \
         -DLLVM_BINUTILS_INCDIR=%{_includedir} \
         -DLLVM_BINUTILS_INCDIR=%{_includedir} \
         -DLLVM_BUILD_RUNTIME:BOOL=ON \
         -DLLVM_BUILD_RUNTIME:BOOL=ON \
         -DLLVM_INCLUDE_TOOLS:BOOL=ON \
         -DLLVM_INCLUDE_TOOLS:BOOL=ON \
@@ -481,7 +505,6 @@ LDFLAGS="%{?__global_ldflags} -L$TMP_PWD/%{_lib} -lpthread -ldl"
         -DLLVM_BUILD_LLVM_DYLIB:BOOL=ON \
         -DLLVM_BUILD_LLVM_DYLIB:BOOL=ON \
         -DLLVM_DYLIB_EXPORT_ALL:BOOL=ON \
         -DLLVM_DYLIB_EXPORT_ALL:BOOL=ON \
         -DLLVM_LINK_LLVM_DYLIB:BOOL=ON \
         -DLLVM_LINK_LLVM_DYLIB:BOOL=ON \
-        -DLLVM_BUILD_EXTERNAL_COMPILER_RT:BOOL=ON \
         -DLLVM_INSTALL_TOOLCHAIN_ONLY:BOOL=OFF \
         -DLLVM_INSTALL_TOOLCHAIN_ONLY:BOOL=OFF \
         -DLLVM_OPTIMIZED_TABLEGEN:BOOL=ON \
         -DLLVM_OPTIMIZED_TABLEGEN:BOOL=ON \
         \
         \
@@ -491,6 +514,8 @@ LDFLAGS="%{?__global_ldflags} -L$TMP_PWD/%{_lib} -lpthread -ldl"
         -DCLANG_INCLUDE_TESTS:BOOL=ON \
         -DCLANG_INCLUDE_TESTS:BOOL=ON \
         -DCLANG_PLUGIN_SUPPORT:BOOL=ON \
         -DCLANG_PLUGIN_SUPPORT:BOOL=ON \
         -DCLANG_BUILD_EXAMPLES:BOOL=OFF \
         -DCLANG_BUILD_EXAMPLES:BOOL=OFF \
+        -DCLANG_LINK_CLANG_DYLIB=ON \
+        -DCLANG_REPOSITORY_STRING="Vine Linux %{version}-%{release}" \
         -DLIB_SUFFIX= \
         -DLIB_SUFFIX= \
         \
         \
         -DLLDB_DISABLE_CURSES:BOOL=OFF \
         -DLLDB_DISABLE_CURSES:BOOL=OFF \
@@ -502,21 +527,20 @@ LDFLAGS="%{?__global_ldflags} -L$TMP_PWD/%{_lib} -lpthread -ldl"
         -DLIBOMP_INSTALL_ALIASES=OFF \
         -DLIBOMP_INSTALL_ALIASES=OFF \
         -DLIBOMP_HEADERS_INSTALL_PATH:PATH=%{_libdir}/clang/%{version}/include \
         -DLIBOMP_HEADERS_INSTALL_PATH:PATH=%{_libdir}/clang/%{version}/include \
         \
         \
-        -DPYTHON_EXECUTABLE:STRING=%{__python} \
-        -DPYTHON_VERSION_MAJOR:STRING=$(%{__python} -c "import sys; print sys.version_info.major") \
-        -DPYTHON_VERSION_MINOR:STRING=$(%{__python} -c "import sys; print sys.version_info.minor") \
+        -DPYTHON_EXECUTABLE:STRING=%{__python3} \
         -DCOMPILER_RT_INCLUDE_TESTS:BOOL=OFF # could be on?
         -DCOMPILER_RT_INCLUDE_TESTS:BOOL=OFF # could be on?
 
 
 # workaround for all-in-one build
 # workaround for all-in-one build
 #TMP_PWD=$(pwd)
 #TMP_PWD=$(pwd)
 #LD_LIBRARY_PATH="$TMP_PWD/%{_lib}" make %{?_smp_mflags}
 #LD_LIBRARY_PATH="$TMP_PWD/%{_lib}" make %{?_smp_mflags}
-make %{?_smp_mflags}
+
+%ninja_build
 
 
 %install
 %install
 rm -rf %{buildroot}
 rm -rf %{buildroot}
 
 
 cd build
 cd build
-make install DESTDIR=%{buildroot}
+%ninja_install
 
 
 # llvm
 # llvm
 
 
@@ -534,8 +558,8 @@ install -m 0644 %{SOURCE10} %{buildroot}%{_includedir}/llvm/Config/llvm-config.h
 rm -fv %{buildroot}%{_libdir}/libclang*.a
 rm -fv %{buildroot}%{_libdir}/libclang*.a
 
 
 # install clang python bindings
 # install clang python bindings
-mkdir -p %{buildroot}%{python_sitelib}/clang/
-install -p -m644 ../tools/clang/bindings/python/clang/* %{buildroot}%{python_sitelib}/clang/
+mkdir -p %{buildroot}%{python3_sitelib}/clang/
+install -p -m644 ../tools/clang/bindings/python/clang/* %{buildroot}%{python3_sitelib}/clang/
 
 
 mv -v %{buildroot}%{_includedir}/clang/Config/config{,-%{__isa_bits}}.h
 mv -v %{buildroot}%{_includedir}/clang/Config/config{,-%{__isa_bits}}.h
 install -m 0644 %{SOURCE11} %{buildroot}%{_includedir}/clang/Config/config.h
 install -m 0644 %{SOURCE11} %{buildroot}%{_includedir}/clang/Config/config.h
@@ -558,10 +582,10 @@ rm -fv %{buildroot}%{_libdir}/liblldb*.a
 
 
 # python: fix binary libraries location
 # python: fix binary libraries location
 liblldb=$(basename $(readlink -e %{buildroot}%{_libdir}/liblldb.so))
 liblldb=$(basename $(readlink -e %{buildroot}%{_libdir}/liblldb.so))
-ln -vsf "../../../${liblldb}" %{buildroot}%{python_sitearch}/lldb/_lldb.so
+ln -vsf "../../../${liblldb}" %{buildroot}%{python3_sitearch}/lldb/_lldb.so
 
 
 # remove bundled six.py
 # remove bundled six.py
-rm -f %{buildroot}%{python_sitearch}/six.*
+rm -f %{buildroot}%{python3_sitearch}/six.*
 
 
 
 
 # lld
 # lld
@@ -604,12 +628,13 @@ rm -f %{buildroot}%{_datadir}/clang/bash-autocomplete.sh
 rm -f %{buildroot}%{_datadir}/clang/clang-rename.el
 rm -f %{buildroot}%{_datadir}/clang/clang-rename.el
 rm -f %{buildroot}%{_datadir}/clang/clang-rename.py
 rm -f %{buildroot}%{_datadir}/clang/clang-rename.py
 
 
+%if %{with test}
 %check
 %check
-# the || : is wrong, i know, but the git snaps fail to make check due to
-# broken makefiles in the doc dirs.
-cd build
-make check-all LIT_ARGS="-v -j4" | tee llvm-testlog.txt ||:
-make -C tools/clang/test TESTARGS="-v -j4" | tee clang-testlog.txt ||:
+ninja -C build check
+ninja -C build check-clang
+ninja -C build check-lldb
+ninja -C build check-lld
+%endif
 
 
 %clean
 %clean
 rm -rf %{buildroot}
 rm -rf %{buildroot}
@@ -691,7 +716,7 @@ exit 0
 %{_libdir}/libLTO.so*
 %{_libdir}/libLTO.so*
 %{_libdir}/libRemarks.so
 %{_libdir}/libRemarks.so
 %{_libdir}/cmake/llvm
 %{_libdir}/cmake/llvm
-%exclude %{_libdir}/cmake/llvm/LLVMStaticExports.cmake
+#exclude %{_libdir}/cmake/llvm/LLVMStaticExports.cmake
 
 
 %files -n llvm%{ver_suffix}-libs
 %files -n llvm%{ver_suffix}-libs
 %defattr(-,root,root,-)
 %defattr(-,root,root,-)
@@ -704,7 +729,7 @@ exit 0
 
 
 %files static
 %files static
 %{_libdir}/*.a
 %{_libdir}/*.a
-%{_libdir}/cmake/llvm/LLVMStaticExports.cmake
+#{_libdir}/cmake/llvm/LLVMStaticExports.cmake
 
 
 %files -n clang
 %files -n clang
 %defattr(-,root,root,-)
 %defattr(-,root,root,-)
@@ -743,8 +768,8 @@ exit 0
 %{_datadir}/scan-build
 %{_datadir}/scan-build
 %{_mandir}/man1/scan-build.1.*
 %{_mandir}/man1/scan-build.1.*
 
 
-%files -n python-clang
-%{python_sitelib}/clang/
+%files -n python3-clang
+%{python3_sitelib}/clang/
 
 
 %files -n lldb
 %files -n lldb
 %defattr(-,root,root,-)
 %defattr(-,root,root,-)
@@ -757,8 +782,8 @@ exit 0
 %{_includedir}/lldb
 %{_includedir}/lldb
 %{_libdir}/liblldb*.so
 %{_libdir}/liblldb*.so
 
 
-%files -n python-lldb
-%{python_sitearch}/lldb
+%files -n python3-lldb
+%{python3_sitearch}/lldb
 
 
 %files -n lld
 %files -n lld
 %defattr(-,root,root,-)
 %defattr(-,root,root,-)
@@ -828,8 +853,8 @@ exit 0
 %doc LICENSE.TXT
 %doc LICENSE.TXT
 #config(noreplace) %{_sysconfdir}/ld.so.conf.d/llvm-%{_arch}.conf
 #config(noreplace) %{_sysconfdir}/ld.so.conf.d/llvm-%{_arch}.conf
 %exclude %{_libdir}/libLTO.so
 %exclude %{_libdir}/libLTO.so
-%exclude %{_libdir}/BugpointPasses.so
-%exclude %{_libdir}/libclang.so
+#exclude %{_libdir}/BugpointPasses.so
+%exclude %{_libdir}/libclang*.so
 %exclude %{_libdir}/liblld*.so
 %exclude %{_libdir}/liblld*.so
 %exclude %{_libdir}/LLVMGold.so
 %exclude %{_libdir}/LLVMGold.so
 %exclude %{_libdir}/LLVMHello.so
 %exclude %{_libdir}/LLVMHello.so
@@ -838,6 +863,11 @@ exit 0
 %endif
 %endif
 
 
 %changelog
 %changelog
+* Sun Sep 22 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 9.0.0-2
+- dropped all patches.
+- switched build-system to ninja.
+- switched python to python3.
+
 * Fri Sep 20 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 9.0.0-1
 * Fri Sep 20 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 9.0.0-1
 - new upstream release.
 - new upstream release.
 - added OpenMP.
 - added OpenMP.

+ 31 - 16
n/nodejs/nodejs-vl.spec

@@ -1,8 +1,10 @@
+%bcond_without clang
+
 %global system_zlib 1
 %global system_zlib 1
 %global system_v8 0
 %global system_v8 0
 %global system_openssl 1
 %global system_openssl 1
 %global system_http_parser 0
 %global system_http_parser 0
-%global system_cares 0
+%global system_cares 1
 %global system_libuv 0
 %global system_libuv 0
 
 
 %if "%{_dist_release}" < "vl7"
 %if "%{_dist_release}" < "vl7"
@@ -12,7 +14,7 @@
 %define _unpackaged_files_terminate_build 1
 %define _unpackaged_files_terminate_build 1
 
 
 Name: nodejs
 Name: nodejs
-Version: 8.9.3
+Version: 10.16.3
 Release: 1%{?_dist_release}
 Release: 1%{?_dist_release}
 Summary: JavaScript runtime
 Summary: JavaScript runtime
 Summary(ja): JavaScript runtime
 Summary(ja): JavaScript runtime
@@ -23,7 +25,7 @@ URL: http://nodejs.org/
 # Exclusive archs must match v8
 # Exclusive archs must match v8
 ExclusiveArch: %{ix86} x86_64 %{arm}
 ExclusiveArch: %{ix86} x86_64 %{arm}
 
 
-Source0: http://nodejs.org/dist/v%{version}/node-v%{version}.tar.gz
+Source0: https://nodejs.org/dist/v%{version}/node-v%{version}.tar.gz
 Source1: macros.nodejs
 Source1: macros.nodejs
 Source2: nodejs.attr
 Source2: nodejs.attr
 Source3: nodejs.prov
 Source3: nodejs.prov
@@ -31,18 +33,16 @@ Source4: nodejs.req
 Source5: nodejs-symlink-deps
 Source5: nodejs-symlink-deps
 Source6: nodejs-fixdep
 Source6: nodejs-fixdep
 
 
-# https://github.com/nodejs/node/pull/17174
-# this bug will be fixed in 8.9.4.
-Patch0: 17174.patch
-# https://github.com/nodejs/node/pull/17258
-# this bug will be fixed in 8.9.4.
-Patch1: 17258.patch
-
 # V8 presently breaks ABI at least every x.y release while never bumping SONAME,
 # V8 presently breaks ABI at least every x.y release while never bumping SONAME,
 # so we need to be more explicit until spot fixes that
 # so we need to be more explicit until spot fixes that
 %global v8_ge 6.1.534.48
 %global v8_ge 6.1.534.48
 %global v8_lt 6.2
 %global v8_lt 6.2
 
 
+%if %{with clang}
+BuildRequires: clang
+BuildRequires: lld
+%endif
+
 %if %{system_v8}
 %if %{system_v8}
 BuildRequires: v8-devel >= %{v8_ge}
 BuildRequires: v8-devel >= %{v8_ge}
 %endif
 %endif
@@ -122,8 +122,6 @@ The API documentation for the Node.js JavaScript runtime.
 
 
 %prep
 %prep
 %setup -q -n node-v%{version}
 %setup -q -n node-v%{version}
-%patch0 -p1
-%patch1 -p1
 
 
 # Make sure nothing gets included from bundled deps:
 # Make sure nothing gets included from bundled deps:
 # We only delete the source and header files, because
 # We only delete the source and header files, because
@@ -160,9 +158,20 @@ find deps/uv -name "*.h" -exec rm -f {} \;
 %endif
 %endif
 
 
 %build
 %build
+
 # build with debugging symbols and add defines from libuv (#892601)
 # build with debugging symbols and add defines from libuv (#892601)
 export CFLAGS='%{optflags} -g -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64'
 export CFLAGS='%{optflags} -g -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64'
 export CXXFLAGS='%{optflags} -g -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64'
 export CXXFLAGS='%{optflags} -g -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64'
+export LDFLAGS="-Wl,-z,relro,-z,now"
+
+%if %{with clang}
+export CC=clang
+export CXX=clang++
+export LD=clang
+export CFLAGS="$CFLAGS -Wno-ignored-optimization-argument"
+export CXXFLAGS="$CXXFLAGS -Wno-ignored-optimization-argument"
+export LDFLAGS="$LDFLAGS -fuse-ld=lld"
+%endif
 
 
 ./configure --prefix=%{_prefix} \
 ./configure --prefix=%{_prefix} \
           %if %{system_v8}
           %if %{system_v8}
@@ -238,7 +247,8 @@ mkdir -p %{buildroot}%{_datadir}/node
 cp -p common.gypi %{buildroot}%{_datadir}/node
 cp -p common.gypi %{buildroot}%{_datadir}/node
 
 
 %files
 %files
-%doc CHANGELOG.md LICENSE README.md AUTHORS
+%license LICENSE
+%doc CHANGELOG.md README.md AUTHORS
 %{_bindir}/node
 %{_bindir}/node
 %{_bindir}/npm
 %{_bindir}/npm
 %{_bindir}/npx
 %{_bindir}/npx
@@ -256,15 +266,20 @@ cp -p common.gypi %{buildroot}%{_datadir}/node
 %{_rpmconfigdir}/nodejs*
 %{_rpmconfigdir}/nodejs*
 
 
 %files docs
 %files docs
-#%{_defaultdocdir}/%{name}-docs-%{version}
-%doc LICENSE
+%doc %{_docdir}/%{name}-docs-%{version}
+%license LICENSE
 
 
 %changelog
 %changelog
+* Sat Sep 28 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 10.16.3-1
+- updated to 10.16.3.
+- dropped Patch0 and 1: fixed in upstream.
+- built with clang / lld.
+
 * Tue Dec 26 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 8.9.3-1
 * Tue Dec 26 2017 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 8.9.3-1
 - updated to 8.9.3.
 - updated to 8.9.3.
 - built with bundled v8.
 - built with bundled v8.
 - built with system c-ares.
 - built with system c-ares.
-- added Patch0.
+- added Patch0 and 1.
 
 
 * Fri Sep 02 2016 Toshiaki Ara <ara_t@384.jp> 0.10.26-2
 * Fri Sep 02 2016 Toshiaki Ara <ara_t@384.jp> 0.10.26-2
 - rebuild with gcc-5.4.0
 - rebuild with gcc-5.4.0

+ 5 - 2
n/nspr/nspr-vl.spec

@@ -3,12 +3,12 @@
 Summary:	Netscape Portable Runtime
 Summary:	Netscape Portable Runtime
 Summary(ja):    Netscape ポータブルランタイム
 Summary(ja):    Netscape ポータブルランタイム
 Name:		nspr
 Name:		nspr
-Version:	4.20
+Version:	4.22
 Release:	1%{?_dist_release}
 Release:	1%{?_dist_release}
 License:	MPLv2.0
 License:	MPLv2.0
 URL:		http://www.mozilla.org/projects/nspr/
 URL:		http://www.mozilla.org/projects/nspr/
 Group:		System Environment/Libraries
 Group:		System Environment/Libraries
-Source0:	%{name}-%{version}.tar.gz
+Source0:	https://archive.mozilla.org/pub/nspr/releases/v%{version}/src/%{name}-%{version}.tar.gz
 
 
 Patch1:		nspr-config-pc.patch
 Patch1:		nspr-config-pc.patch
 
 
@@ -136,6 +136,9 @@ NSPR_VERSION=`./config/nspr-config --version`
 
 
 
 
 %changelog
 %changelog
+* Fri Sep 27 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.22-1
+- update to 4.22.
+
 * Thu Nov 08 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.20-1
 * Thu Nov 08 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 4.20-1
 - update to 4.20.
 - update to 4.20.
 - dropped Patch2.
 - dropped Patch2.

+ 10 - 8
n/nss/nss-vl.spec

@@ -1,9 +1,7 @@
 %define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
 %define build_compat32 %{?_with_compat32:1}%{!?_with_compat32:0}
 
 
-%define _unpackaged_files_terminate_build 1
-
-%define nspr_version 4.20
-%define pem_version 1.0.4
+%define nspr_version 4.22
+%define pem_version 1.0.5
 %define unsupported_tools_directory %{_libdir}/nss/unsupported-tools
 %define unsupported_tools_directory %{_libdir}/nss/unsupported-tools
 %global allTools "certutil cmsutil crlutil derdump modutil pk12util pp signtool signver ssltap vfychain vfyserv"
 %global allTools "certutil cmsutil crlutil derdump modutil pk12util pp signtool signver ssltap vfychain vfyserv"
 
 
@@ -29,7 +27,7 @@
 
 
 Summary:          Network Security Services
 Summary:          Network Security Services
 Name:             nss
 Name:             nss
-Version:          3.40
+Version:          3.46
 Release:          1%{?_dist_release}
 Release:          1%{?_dist_release}
 License:          MPLv1.1 or GPLv2+ or LGPLv2+
 License:          MPLv1.1 or GPLv2+ or LGPLv2+
 URL:              http://www.mozilla.org/projects/security/pki/nss/
 URL:              http://www.mozilla.org/projects/security/pki/nss/
@@ -37,7 +35,8 @@ Group:            System Environment/Libraries
 Vendor:           Project Vine
 Vendor:           Project Vine
 Distribution:     Vine Linux
 Distribution:     Vine Linux
 
 
-Source0:          %{name}-%{version}.tar.gz
+%define           altver %(echo %{version} | sed -e 's/\\./_/')
+Source0:          https://archive.mozilla.org/pub/security/nss/releases/NSS_%{altver}_RTM/src/%{name}-%{version}.tar.gz
 Source1:          nss.pc.in
 Source1:          nss.pc.in
 Source2:          nss-config.in
 Source2:          nss-config.in
 Source3:          blank-cert8.db
 Source3:          blank-cert8.db
@@ -88,7 +87,6 @@ Patch58: rhbz1185708-enable-ecc-3des-ciphers-by-default.patch
 Patch62: nss-skip-util-gtest.patch
 Patch62: nss-skip-util-gtest.patch
 
 
 Patch1000: nss-enable-pem.patch
 Patch1000: nss-enable-pem.patch
-Patch1001: nss-pem-fix-shadowed-vars.patch
 
 
 BuildRoot:        %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRoot:        %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires:    nspr-devel >= %{nspr_version}
 BuildRequires:    nspr-devel >= %{nspr_version}
@@ -168,7 +166,6 @@ v3 certificates, and other security standards.
 pushd nss/lib/ckfw/pem/
 pushd nss/lib/ckfw/pem/
 tar xvf %{SOURCE1001}
 tar xvf %{SOURCE1001}
 perl -pi -e 's/^#define USE_UTIL_DIRECTLY.*$//' ckpem.h
 perl -pi -e 's/^#define USE_UTIL_DIRECTLY.*$//' ckpem.h
-%patch1001 -p2 -b .shadowed_vars
 popd
 popd
 
 
 %patch2 -p0 -b .relro
 %patch2 -p0 -b .relro
@@ -623,6 +620,11 @@ chmod 755 $RPM_BUILD_ROOT/%{_bindir}/nss-softokn-config
 
 
 
 
 %changelog
 %changelog
+* Fri Sep 27 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.46-1
+- update to 3.46.
+- updated nss-pem to 1.0.5.
+- dropped Patch1001: fixed in upstream?
+
 * Thu Nov 08 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.40-1
 * Thu Nov 08 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 3.40-1
 - update to 3.40.
 - update to 3.40.
 - dropped Patch40,59.
 - dropped Patch40,59.

+ 114 - 52
r/rust/rust-vl.spec

@@ -1,29 +1,32 @@
 %bcond_with bootstrap
 %bcond_with bootstrap
 %bcond_with test
 %bcond_with test
+%bcond_without clang
+%bcond_without bundled_libgit2
+%bcond_without bundled_libssh2
 
 
 # Some sub-packages are versioned independently of the rust compiler and runtime itself.
 # Some sub-packages are versioned independently of the rust compiler and runtime itself.
 # Also beware that if any of these are not changed in a version bump, then the release
 # Also beware that if any of these are not changed in a version bump, then the release
 # number should still increase, not be reset to 1!
 # number should still increase, not be reset to 1!
-%global rustc_version 1.30.1
-%global cargo_version 1.30.0
-%global rustfmt_version 0.99.4
-%global rls_version 0.130.5
-%global clippy_version 0.0.212
+%global rustc_version 1.38.0
+%global cargo_version %{rustc_version}
+%global rustfmt_version %{rustc_version}
+%global rls_version %{rustc_version}
+%global clippy_version %{rustc_version}
 
 
-%define _unpackaged_files_terminate_build 1
+%global llvm_major 9
+
+# The channel can be stable, beta, or nightly
+%{!?channel: %global channel stable}
 
 
 # Only x86_64 and i686 are Tier 1 platforms at this time.
 # Only x86_64 and i686 are Tier 1 platforms at this time.
 # https://forge.rust-lang.org/platform-support.html
 # https://forge.rust-lang.org/platform-support.html
 %global rust_arches x86_64 i686
 %global rust_arches x86_64 i686
 
 
-# The channel can be stable, beta, or nightly
-%{!?channel: %global channel stable}
-
 # To bootstrap from scratch, set the channel and date from src/stage0.txt
 # To bootstrap from scratch, set the channel and date from src/stage0.txt
 # e.g. 1.10.0 wants rustc: 1.9.0-2016-05-24
 # e.g. 1.10.0 wants rustc: 1.9.0-2016-05-24
 # or nightly wants some beta-YYYY-MM-DD
 # or nightly wants some beta-YYYY-MM-DD
-%global bootstrap_rust 1.30.1
-%global bootstrap_cargo 1.30.0
+%global bootstrap_rust 1.37.0
+%global bootstrap_cargo 1.37.0
 %global bootstrap_channel %{bootstrap_rust}
 %global bootstrap_channel %{bootstrap_rust}
 
 
 # Only the specified arches will use bootstrap binaries.
 # Only the specified arches will use bootstrap binaries.
@@ -52,7 +55,7 @@
 %endif
 %endif
 
 
 Name:           rust
 Name:           rust
-Version:        1.30.1
+Version:        %{rustc_version}
 Release:        1%{?_dist_release}
 Release:        1%{?_dist_release}
 Summary:        The Rust Programming Language
 Summary:        The Rust Programming Language
 License:        (ASL 2.0 or MIT) and (BSD and ISC and MIT)
 License:        (ASL 2.0 or MIT) and (BSD and ISC and MIT)
@@ -120,19 +123,32 @@ BuildConflicts: %{name} > %{version}
 
 
 BuildRequires:  cmake
 BuildRequires:  cmake
 BuildRequires:  make
 BuildRequires:  make
+%if %{with clang}
+BuildRequires:  clang
+BuildRequires:  lld
+%else
 BuildRequires:  gcc
 BuildRequires:  gcc
 BuildRequires:  gcc-c++
 BuildRequires:  gcc-c++
+%endif
+%if %{without bundled_libgit2}
 BuildRequires:  libgit2-devel
 BuildRequires:  libgit2-devel
+%endif
+%if %{without bundled_libssh2}
 BuildRequires:  libssh2-devel
 BuildRequires:  libssh2-devel
+%endif
 BuildRequires:  ncurses-devel
 BuildRequires:  ncurses-devel
 BuildRequires:  openssl-devel
 BuildRequires:  openssl-devel
 BuildRequires:  zlib-devel
 BuildRequires:  zlib-devel
-BuildRequires:  python
+BuildRequires:  python3
+BuildRequires:  python3-rpm-macros
 BuildRequires:  curl
 BuildRequires:  curl
+BuildRequires:  curl-devel
+BuildRequires:  xz-devel
 
 
 %if %{with bundled_llvm}
 %if %{with bundled_llvm}
 BuildRequires:  cmake
 BuildRequires:  cmake
-Provides:       bundled(llvm) = 4.0
+BuildRequires:  git
+Provides:       bundled(llvm) = 6.0
 %else
 %else
 %if %defined llvm
 %if %defined llvm
 %global llvm_root %{_libdir}/%{llvm}
 %global llvm_root %{_libdir}/%{llvm}
@@ -146,6 +162,7 @@ BuildRequires:  %{llvm}-static
 BuildRequires:  libffi-devel
 BuildRequires:  libffi-devel
 %else
 %else
 # Make sure llvm-config doesn't see it.
 # Make sure llvm-config doesn't see it.
+Requires:       %{llvm}%{llvm_major}-libs
 BuildConflicts: %{llvm}-static
 BuildConflicts: %{llvm}-static
 %endif
 %endif
 %endif
 %endif
@@ -158,7 +175,6 @@ BuildRequires:  gdb
 
 
 # TODO: work on unbundling these!
 # TODO: work on unbundling these!
 Provides:       bundled(jquery) = 2.1.4
 Provides:       bundled(jquery) = 2.1.4
-Provides:       bundled(libbacktrace) = 6.1.0
 Provides:       bundled(miniz) = 1.14
 Provides:       bundled(miniz) = 1.14
 
 
 # Virtual provides for folks who attempt "dnf install rustc"
 # Virtual provides for folks who attempt "dnf install rustc"
@@ -290,45 +306,41 @@ Requires:       rust-doc = %{rustc_version}-%{release}
 This package includes HTML documentation for Cargo.
 This package includes HTML documentation for Cargo.
 
 
 
 
-%package -n rustfmt-preview
+%package -n rustfmt
 Summary:        Tool to find and fix Rust formatting issues
 Summary:        Tool to find and fix Rust formatting issues
 Version:        %{rustfmt_version}
 Version:        %{rustfmt_version}
 Requires:       cargo
 Requires:       cargo
+Obsoletes:      rustfmt-preview < 1.0.0
 
 
-# Despite the lower version, our rustfmt-preview is newer than rustfmt-0.9.
-# It's expected to stay "preview" until it's released as 1.0.
-Obsoletes:      rustfmt <= 0.9.0
-Provides:       rustfmt = %{rustfmt_version}
-
-%description -n rustfmt-preview
+%description -n rustfmt
 A tool for formatting Rust code according to style guidelines.
 A tool for formatting Rust code according to style guidelines.
 
 
 
 
-%package -n rls-preview
+%package -n rls
 Summary:        Rust Language Server for IDE integration
 Summary:        Rust Language Server for IDE integration
 Version:        %{rls_version}
 Version:        %{rls_version}
-Provides:       rls = %{rls_version}
 Requires:       rust-analysis
 Requires:       rust-analysis
 # /usr/bin/rls is dynamically linked against internal rustc libs
 # /usr/bin/rls is dynamically linked against internal rustc libs
 Requires:       %{name} = %{rustc_version}-%{release}
 Requires:       %{name} = %{rustc_version}-%{release}
+Obsoletes:      rls-preview < 1.0.0
 
 
-%description -n rls-preview
+%description -n rls
 The Rust Language Server provides a server that runs in the background,
 The Rust Language Server provides a server that runs in the background,
 providing IDEs, editors, and other tools with information about Rust programs.
 providing IDEs, editors, and other tools with information about Rust programs.
 It supports functionality such as 'goto definition', symbol search,
 It supports functionality such as 'goto definition', symbol search,
 reformatting, and code completion, and enables renaming and refactorings.
 reformatting, and code completion, and enables renaming and refactorings.
 
 
 
 
-%package -n clippy-preview
+%package -n clippy
 Summary:        Lints to catch common mistakes and improve your Rust code
 Summary:        Lints to catch common mistakes and improve your Rust code
 Version:        %{clippy_version}
 Version:        %{clippy_version}
 License:        MPLv2.0
 License:        MPLv2.0
-Provides:       clippy = %{clippy_version}
 Requires:       cargo
 Requires:       cargo
 # /usr/bin/clippy-driver is dynamically linked against internal rustc libs
 # /usr/bin/clippy-driver is dynamically linked against internal rustc libs
 Requires:       %{name} = %{rustc_version}-%{release}
 Requires:       %{name} = %{rustc_version}-%{release}
+Obsoletes:      clippy-preview < 1.0.0
 
 
-%description -n clippy-preview
+%description -n clippy
 A collection of lints to catch common mistakes and improve your Rust code.
 A collection of lints to catch common mistakes and improve your Rust code.
 
 
 
 
@@ -363,24 +375,37 @@ test -f '%{local_rust_root}/bin/rustc'
 
 
 %setup -q -n %{rustc_package}
 %setup -q -n %{rustc_package}
 
 
-# We're disabling jemalloc, but rust-src still wants it.
-# rm -rf src/jemalloc/
+%if "%{python}" == "python3"
+sed -i.try-py3 -e '/try python2.7/i try python3 "$@"' ./configure
+%endif
 
 
 %if %without bundled_llvm
 %if %without bundled_llvm
-rm -rf src/llvm/
+rm -rf src/llvm-project/
 %endif
 %endif
 
 
 # We never enable emscripten.
 # We never enable emscripten.
 rm -rf src/llvm-emscripten/
 rm -rf src/llvm-emscripten/
 
 
-# We never enable other LLVM tools.
-rm -rf src/tools/clang
-rm -rf src/tools/lld
-rm -rf src/tools/lldb
+# Remove other unused vendored libraries
+#rm -rf vendor/curl-sys/curl/
+rm -rf vendor/jemalloc-sys/jemalloc/
+rm -rf vendor/libz-sys/src/zlib/
+rm -rf vendor/lzma-sys/xz-*/
+rm -rf vendor/openssl-src/openssl/
+%if %{without bundled_libgit2}
+rm -rf vendor/libgit2-sys/libgit2/
+%endif
+%if %{without bundled_libssh2}
+rm -rf vendor/libssh2-sys/libssh2/
+%endif
+
+# This only affects the transient rust-installer, but let it use our dynamic xz-libs
+sed -i.lzma -e '/LZMA_API_STATIC/d' src/bootstrap/tool.rs
 
 
-# extract bundled licenses for packaging
-sed -e '/*\//q' src/libbacktrace/backtrace.h \
-  >src/libbacktrace/LICENSE-libbacktrace
+# rename bundled license for packaging
+if [ -e vendor/backtrace-sys/src/libbacktrace/LICENSE ]; then
+  cp -a vendor/backtrace-sys/src/libbacktrace/LICENSE{,-libbacktrace}
+fi
 
 
 %if %{with bundled_llvm} && 0%{?epel}
 %if %{with bundled_llvm} && 0%{?epel}
 mkdir -p cmake-bin
 mkdir -p cmake-bin
@@ -398,13 +423,18 @@ sed -i.ffi -e '$a #[link(name = "ffi")] extern {}' \
 # The configure macro will modify some autoconf-related files, which upsets
 # The configure macro will modify some autoconf-related files, which upsets
 # cargo when it tries to verify checksums in those files.  If we just truncate
 # cargo when it tries to verify checksums in those files.  If we just truncate
 # that file list, cargo won't have anything to complain about.
 # that file list, cargo won't have anything to complain about.
-find src/vendor -name .cargo-checksum.json \
+find vendor -name .cargo-checksum.json \
   -exec sed -i.uncheck -e 's/"files":{[^}]*}/"files":{ }/' '{}' '+'
   -exec sed -i.uncheck -e 's/"files":{[^}]*}/"files":{ }/' '{}' '+'
 
 
+
 %build
 %build
 
 
+%if %{without bundled_libgit2}
 export LIBGIT2_SYS_USE_PKG_CONFIG=1
 export LIBGIT2_SYS_USE_PKG_CONFIG=1
+%endif
+%if %{without bundled_libssh2}
 export LIBSSH2_SYS_USE_PKG_CONFIG=1
 export LIBSSH2_SYS_USE_PKG_CONFIG=1
+%endif
 
 
 %{?cmake_path:export PATH=%{cmake_path}:$PATH}
 %{?cmake_path:export PATH=%{cmake_path}:$PATH}
 %{?library_path:export LIBRARY_PATH="%{library_path}"}
 %{?library_path:export LIBRARY_PATH="%{library_path}"}
@@ -415,11 +445,18 @@ export LIBSSH2_SYS_USE_PKG_CONFIG=1
 %global common_libdir %{_prefix}/lib
 %global common_libdir %{_prefix}/lib
 %global rustlibdir %{common_libdir}/rustlib
 %global rustlibdir %{common_libdir}/rustlib
 
 
-#%ifarch x86_64
-%define enable_debuginfo --enable-debuginfo --enable-debuginfo-only-std --disable-debuginfo-tools --disable-debuginfo-lines
-#%else
-#%define enable_debuginfo --disable-debuginfo --disable-debuginfo-only-std --disable-debuginfo-tools --disable-debuginfo-lines
-#%endif
+%ifarch x86_64
+%define enable_debuginfo --debuginfo-level=0 --debuginfo-level-std=2
+%else
+%define enable_debuginfo --debuginfo-level=0
+%endif
+
+%if %{with clang}
+export CC=clang
+export CXX=clang++
+export LDFLAGS="$LDFLAGS -fuse-ld=lld"
+export RUSTFLAGS="$RUSTFLAGS -C linker=clang -C link-arg=-fuse-ld=lld"
+%endif
 
 
 %configure \
 %configure \
   --disable-option-checking \
   --disable-option-checking \
@@ -428,16 +465,16 @@ export LIBSSH2_SYS_USE_PKG_CONFIG=1
   --enable-local-rust --local-rust-root=%{local_rust_root} \
   --enable-local-rust --local-rust-root=%{local_rust_root} \
   %{!?with_bundled_llvm: --llvm-root=%{llvm_root} --disable-codegen-tests \
   %{!?with_bundled_llvm: --llvm-root=%{llvm_root} --disable-codegen-tests \
     %{!?with_llvm_static: --enable-llvm-link-shared } } \
     %{!?with_llvm_static: --enable-llvm-link-shared } } \
-  --disable-jemalloc \
   --disable-rpath \
   --disable-rpath \
   %{enable_debuginfo} \
   %{enable_debuginfo} \
   --enable-extended \
   --enable-extended \
   --enable-vendor \
   --enable-vendor \
   --enable-verbose-tests \
   --enable-verbose-tests \
+  --set rust.codegen-units-std=1 \
   --release-channel=%{channel}
   --release-channel=%{channel}
 
 
-RUST_BACKTRACE=1 ./x.py build
-./x.py doc
+RUST_BACKTRACE=1 %{__python3} ./x.py build
+%{__python3} ./x.py doc
 
 
 
 
 %install
 %install
@@ -446,6 +483,11 @@ rm -rf %{buildroot}
 %{?cmake_path:export PATH=%{cmake_path}:$PATH}
 %{?cmake_path:export PATH=%{cmake_path}:$PATH}
 %{?library_path:export LIBRARY_PATH="%{library_path}"}
 %{?library_path:export LIBRARY_PATH="%{library_path}"}
 %{?rustflags:export RUSTFLAGS="%{rustflags}"}
 %{?rustflags:export RUSTFLAGS="%{rustflags}"}
+%if %{with clang}
+export CC=clang
+export CXX=clang++
+export RUSTFLAGS="$RUSTFLAGS -C linker=clang -C link-arg=-fuse-ld=lld"
+%endif
 
 
 DESTDIR=%{buildroot} ./x.py install
 DESTDIR=%{buildroot} ./x.py install
 #DESTDIR=%{buildroot} ./x.py install src
 #DESTDIR=%{buildroot} ./x.py install src
@@ -514,12 +556,22 @@ rm -f %{buildroot}%{_bindir}/rust-lldb
 rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py*
 rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py*
 %endif
 %endif
 
 
+%if %{with bundled_llvm}
+rm -rf %{buildroot}/home
+%endif
+
 
 
 %check
 %check
 %if %{with test}
 %if %{with test}
 %{?cmake_path:export PATH=%{cmake_path}:$PATH}
 %{?cmake_path:export PATH=%{cmake_path}:$PATH}
 %{?library_path:export LIBRARY_PATH="%{library_path}"}
 %{?library_path:export LIBRARY_PATH="%{library_path}"}
 %{?rustflags:export RUSTFLAGS="%{rustflags}"}
 %{?rustflags:export RUSTFLAGS="%{rustflags}"}
+%if %{with clang}
+export CC=clang
+export CXX=clang++
+export LD=ld.lld
+export RUSTFLAGS="$RUSTFLAGS -C linker=ld.lld -C link-arg=-fuse-ld=lld"
+%endif
 
 
 # The results are not stable on koji, so mask errors and just log it.
 # The results are not stable on koji, so mask errors and just log it.
 %{__python} ./x.py test --no-fail-fast || :
 %{__python} ./x.py test --no-fail-fast || :
@@ -536,7 +588,7 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py*
 
 
 %files
 %files
 %license COPYRIGHT LICENSE-APACHE LICENSE-MIT
 %license COPYRIGHT LICENSE-APACHE LICENSE-MIT
-%license src/libbacktrace/LICENSE-libbacktrace
+#license src/libbacktrace/LICENSE-libbacktrace
 %doc README.md
 %doc README.md
 %{_bindir}/rustc
 %{_bindir}/rustc
 %{_bindir}/rustdoc
 %{_bindir}/rustdoc
@@ -548,6 +600,7 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py*
 %dir %{rustlibdir}/%{rust_triple}/lib
 %dir %{rustlibdir}/%{rust_triple}/lib
 %{rustlibdir}/%{rust_triple}/lib/*.so
 %{rustlibdir}/%{rust_triple}/lib/*.so
 %{rustlibdir}/%{rust_triple}/codegen-backends/
 %{rustlibdir}/%{rust_triple}/codegen-backends/
+%exclude %{_bindir}/*miri
 
 
 
 
 %files std-static
 %files std-static
@@ -566,6 +619,7 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py*
 %files gdb
 %files gdb
 %{_bindir}/rust-gdb
 %{_bindir}/rust-gdb
 %{rustlibdir}/etc/gdb_*.py*
 %{rustlibdir}/etc/gdb_*.py*
+%exclude %{_bindir}/rust-gdbgui
 
 
 
 
 %if %with lldb
 %if %with lldb
@@ -582,10 +636,14 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py*
 %{_docdir}/%{name}/html/*/
 %{_docdir}/%{name}/html/*/
 %{_docdir}/%{name}/html/*.html
 %{_docdir}/%{name}/html/*.html
 %{_docdir}/%{name}/html/*.css
 %{_docdir}/%{name}/html/*.css
+%{_docdir}/%{name}/html/*.ico
 %{_docdir}/%{name}/html/*.js
 %{_docdir}/%{name}/html/*.js
+%{_docdir}/%{name}/html/*.png
 %{_docdir}/%{name}/html/*.svg
 %{_docdir}/%{name}/html/*.svg
 %{_docdir}/%{name}/html/*.woff
 %{_docdir}/%{name}/html/*.woff
+%{_docdir}/%{name}/html/SourceSerifPro-LICENSE.md
 %license %{_docdir}/%{name}/html/*.txt
 %license %{_docdir}/%{name}/html/*.txt
+%license %{_docdir}/%{name}/html/*.md
 
 
 
 
 %files -n cargo
 %files -n cargo
@@ -608,24 +666,24 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py*
 %{_docdir}/cargo/html
 %{_docdir}/cargo/html
 
 
 
 
-%files -n rustfmt-preview
+%files -n rustfmt
 %{_bindir}/rustfmt
 %{_bindir}/rustfmt
 %{_bindir}/cargo-fmt
 %{_bindir}/cargo-fmt
 %doc src/tools/rustfmt/{README,CHANGELOG,Configurations}.md
 %doc src/tools/rustfmt/{README,CHANGELOG,Configurations}.md
 %license src/tools/rustfmt/LICENSE-{APACHE,MIT}
 %license src/tools/rustfmt/LICENSE-{APACHE,MIT}
 
 
 
 
-%files -n rls-preview
+%files -n rls
 %{_bindir}/rls
 %{_bindir}/rls
 %doc src/tools/rls/{README.md,COPYRIGHT,debugging.md}
 %doc src/tools/rls/{README.md,COPYRIGHT,debugging.md}
 %license src/tools/rls/LICENSE-{APACHE,MIT}
 %license src/tools/rls/LICENSE-{APACHE,MIT}
 
 
 
 
-%files -n clippy-preview
+%files -n clippy
 %{_bindir}/cargo-clippy
 %{_bindir}/cargo-clippy
 %{_bindir}/clippy-driver
 %{_bindir}/clippy-driver
 %doc src/tools/clippy/{README.md,CHANGELOG.md}
 %doc src/tools/clippy/{README.md,CHANGELOG.md}
-%license src/tools/clippy/LICENSE
+%license src/tools/clippy/LICENSE*
 
 
 
 
 %files src
 %files src
@@ -637,6 +695,10 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py*
 %{rustlibdir}/%{rust_triple}/analysis/
 %{rustlibdir}/%{rust_triple}/analysis/
 
 
 %changelog
 %changelog
+* Sat Sep 28 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 1.38.0-1
+- new upstream release.
+- erased "-preview" from the name of subpackages.
+
 * Wed Dec 05 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 1.30.1-1
 * Wed Dec 05 2018 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 1.30.1-1
 - new upstream release.
 - new upstream release.
 - dropped Patch1.
 - dropped Patch1.