diff --git a/debian/NEWS b/debian/NEWS index edd628b7..3bacb4d1 100644 --- a/debian/NEWS +++ b/debian/NEWS @@ -1,25 +1,9 @@ -llvm-toolchain-7 (1:7.0.1-1) unstable; urgency=medium +llvm-toolchain-14 (1:14.0.6-10) unstable; urgency=medium - * llvm-toolchain packages are built using clang itself (stage2) - - stage1 = build clang with gcc - - stage2 = clang building itself - This could lead to some unexpected (but rare) ABI issues. + * libclang-common-X.Y-dev has been splitted into libclang-rt-X.Y-dev, + libpolly-X.Y-dev, libclang-rt-14-dev-wasm32 and libclang-rt-14-dev-wasm64 + compiler-rt and polly moved to libclang-rt-X.Y-dev + libclang-common-X.Y-dev is now arch:any and contains headers + libclang-common-X.Y-dev recommends libclang-rt-X.Y-dev - -- Sylvestre Ledru Fri, 16 Nov 2018 13:00:39 +0100 - -llvm-toolchain-7 (1:7-1) unstable; urgency=medium - - * From version 7, llvm-toolchain also provides libc++, libc++abi - and OpenMP packages. Non-coinstallable on purpose. - * Packages, binaries and libraries have been renamed. - Instead of the X.Y naming, we moved to X to match the - naming from upstream. - As example, clang version 7 is named clang-7 (unlike clang-6.0) - - -- Sylvestre Ledru Wed, 17 Jan 2018 10:50:39 +0100 - -llvm-toolchain-snapshot (1:3.6~svn214630-1~exp1) experimental; urgency=medium - - * clang is now co-instalable. Available on version 3.4, 3.5 and 3.6 - - -- Sylvestre Ledru Sat, 02 Aug 2014 12:57:41 +0200 + -- Sylvestre Ledru Wed, 28 Dec 2022 12:36:23 +0100 diff --git a/debian/README b/debian/README index cdf5f885..aa6d4d2f 100644 --- a/debian/README +++ b/debian/README @@ -9,10 +9,15 @@ The current snapshot release is maintained in the "snapshot" branch. The easiest way to get all branches is probably to have one clone per version: -for f in 8 9 10 snapshot; do +for f in 14 15 snapshot; do git clone git@salsa.debian.org:pkg-llvm-team/llvm-toolchain.git -b $f $f done +debian/control is generated from debian/control.in by running: + +ebian/rules preconfigure + + Steps for manually building a snapshot release ============================================== @@ -78,6 +83,7 @@ Additional maintainer scripts The script qualify-clang.sh that is found at the git debian/ directory should be used to quickly test a newly built package. It runs a short set of sanity-check tests and regression tests. +It is executed in autopkgtest. The script releases/snapshot/debian/prepare-new-release.sh is used when preparing a new point release. It automatically replaces version numbers diff --git a/debian/changelog b/debian/changelog index 5101db81..aacc6ab9 100644 --- a/debian/changelog +++ b/debian/changelog @@ -301,13 +301,71 @@ llvm-toolchain-snapshot (1:15~++20220202093833+1a3137dc8451-1~exp1) experimental -- Sylvestre Ledru Sun, 13 Feb 2022 23:25:57 +0100 +llvm-toolchain-14 (1:14.0.6-10~exp6) UNRELEASED; urgency=medium + + * Move libPolly in libpolly-X.Y-dev for real + + -- Sylvestre Ledru Sun, 01 Jan 2023 11:42:14 +0100 + +llvm-toolchain-14 (1:14.0.6-10~exp5) experimental; urgency=medium + + * Create a libpolly-X.Y-dev package + * Fix the libclang-rt-14-dev-wasm64 description + + -- Sylvestre Ledru Wed, 28 Dec 2022 12:35:04 +0100 + +llvm-toolchain-14 (1:14.0.6-10~exp4) experimental; urgency=medium + + * Move the compiler-rt content into a new package called + libclang-rt-X.Y-dev (including polly) + * the wasm targets are shipped into libclang-rt-14-dev-wasm32 + and libclang-rt-14-dev-wasm64 + * libclang-common-X.Y-dev arch moved to all + then ${binary:Version} => ${source:Version} + to avoid not-binnmuable-any-depends-all + * link-grpc.diff: add the detection of other libs necessary for + grpc (Closes: #1025529) + + -- Sylvestre Ledru Wed, 21 Dec 2022 13:48:40 +0100 + +llvm-toolchain-14 (1:14.0.6-10~exp3) experimental; urgency=medium + + * Transform debian/control into debian/control.in (preparation for + flang support) + * Do not install wasm-libc if doesn't exist + + [ Faidon Liambotis ] + * Try to unbreak the builds with wasm + + -- Sylvestre Ledru Mon, 19 Dec 2022 11:09:58 +0100 + +llvm-toolchain-14 (1:14.0.6-10~exp1) experimental; urgency=medium + + * More WebAssembly (wasm32/wasm64) work: + - Update patch wasm-sysroot-usr to stop including /usr/include when + building for the non-OS (unknown) wasm targets, to avoid inadvertently + including the host's (glibc) headers. + - Re-enable builds on all architectures, previously disabled for + arm64 armel mips64el mipsel ppc64el armhf in 1:14.0.6-4, due to an FTBFS + related to the /usr/include issue above. + - Update patch wasm-sysroot-usr to adjust system include paths for C++ + headers as well. + - Build libc++ and libc++abi for wasm32-wasi, generating two new binary + packages, and introducing a build dependency on wasi-libc. + - Misc code organization fixes to debian/rules. + + -- Faidon Liambotis Fri, 18 Nov 2022 08:21:02 +0200 + llvm-toolchain-14 (1:14.0.6-9) unstable; urgency=medium + * Cherry-pick upstream commit c081bf4098c729afacf20303cc9df62bf13c3362 + to fix chromium failure in basic_string (Closes: #1025394) * Disable the MLIR testsuite run because of a freeze (Closes: #1024154) See https://github.com/llvm/llvm-project/issues/58357 + * Disable wasm on riscv64 - -- Sylvestre Ledru Tue, 15 Nov 2022 18:23:44 +0100 + -- Gianfranco Costamagna Sun, 04 Dec 2022 09:03:06 +0100 llvm-toolchain-14 (1:14.0.6-8) unstable; urgency=medium diff --git a/debian/control b/debian/control index 62b7be9f..f90fbacf 100644 --- a/debian/control +++ b/debian/control @@ -16,7 +16,7 @@ Build-Depends: debhelper (>= 10.0), cmake, ninja-build, lcov, procps, help2man, zlib1g-dev, g++-multilib [amd64 i386 kfreebsd-amd64 mips64 mips64el mipsel powerpc ppc64 s390 s390x sparc sparc64 x32], libjs-mathjax, python3-recommonmark, - doxygen, gfortran, + doxygen, ocaml-base [amd64 arm64 armhf ppc64el riscv64 s390x] | ocaml-nox [amd64 arm64 armhf ppc64el riscv64 s390x], ocaml-findlib [amd64 arm64 armhf ppc64el riscv64 s390x], libctypes-ocaml-dev [amd64 arm64 armhf ppc64el riscv64 s390x], @@ -25,6 +25,7 @@ Build-Depends: debhelper (>= 10.0), cmake, ninja-build, llvm-spirv-15 [ amd64 arm64 armel armhf mips64el mipsel ppc64el riscv64 s390x ] | llvm-spirv-14 [ amd64 arm64 armel armhf mips64el mipsel ppc64el riscv64 s390x ] | hello [!i386], spirv-tools [ linux-any ] | hello [ !i386], + wasi-libc | hello [ !i386], libcurl4-dev, libgrpc++-dev [amd64 arm64 armel armhf mips64el mipsel ppc64 ppc64el powerpc riscv64 s390x], protobuf-compiler-grpc [amd64 arm64 armel armhf mips64el mipsel ppc64 ppc64el powerpc riscv64 s390x], @@ -42,9 +43,15 @@ Vcs-Browser: https://salsa.debian.org/pkg-llvm-team/llvm-toolchain/tree/15 Package: clang-15 Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends}, ${dep:devlibs}, +<<<<<<< HEAD ${dep:devlibs-objc}, libclang-common-15-dev (= ${binary:Version}), llvm-15-linker-tools (= ${binary:Version}), libclang1-15 (= ${binary:Version}), libc6-dev, binutils +======= + ${dep:devlibs-objc}, libclang-common-14-dev (= ${source:Version}), + llvm-14-linker-tools (= ${binary:Version}), + libclang1-14 (= ${binary:Version}), libc6-dev, binutils +>>>>>>> origin/14 Provides: c-compiler, objc-compiler, c++-compiler Recommends: llvm-15-dev, python3 # libomp-15-dev @@ -101,7 +108,11 @@ Description: clang-based C++ linter tool Package: clangd-15 Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends}, +<<<<<<< HEAD libclang-common-15-dev (= ${binary:Version}) +======= + libclang-common-14-dev (= ${source:Version}) +>>>>>>> origin/14 Description: Language server that provides IDE-like features to editors clangd understands your C++ code and adds smart features to your editor: - code completion @@ -151,8 +162,15 @@ Package: libclang-15-dev Architecture: any Section: libdevel Depends: ${shlibs:Depends}, ${misc:Depends}, ${dep:devlibs}, +<<<<<<< HEAD ${dep:devlibs-objc}, libclang1-15 (= ${binary:Version}), libclang-common-15-dev (= ${binary:Version}) +======= + ${dep:devlibs-objc}, libclang1-14 (= ${binary:Version}), + libclang-common-14-dev (= ${source:Version}) +Breaks: llvm-14-dev (<< 1:14.0.4-2) +Replaces: llvm-14-dev (<< 1:14.0.4-2) +>>>>>>> origin/14 Description: Clang library - Development package Clang project is a C, C++, Objective C and Objective C++ front-end based on the LLVM compiler. Its goal is to offer a replacement to the @@ -164,10 +182,18 @@ Description: Clang library - Development package This package contains the Clang headers to develop extensions over libclang1-15. +<<<<<<< HEAD Package: libclang-common-15-dev Architecture: any Section: libdevel Depends: ${shlibs:Depends}, ${misc:Depends}, libllvm15 (= ${binary:Version}) +======= +Package: libclang-common-14-dev +Architecture: all +Section: libdevel +Depends: ${shlibs:Depends}, ${misc:Depends}, libllvm14 (>= ${source:Version}) +Recommends: libclang-rt-14-dev (>= 14.0.6-10~exp4) +>>>>>>> origin/14 Description: Clang library - Common development package Clang project is a C, C++, Objective C and Objective C++ front-end based on the LLVM compiler. Its goal is to offer a replacement to the @@ -176,8 +202,64 @@ Description: Clang library - Common development package Clang implements all of the ISO C++ 1998, 11, 14 and 17 standards and also provides most of the support of C++20. . - This package contains the Clang generic headers and some libraries - (profiling, etc). + This package contains the Clang generic headers. + +# ------------- compiler-rt ------------- + +Package: libclang-rt-14-dev +Architecture: any +Multi-Arch: same +Section: libdevel +Breaks: libclang-common-14-dev (<< 14.0.6-10~exp4) +Replaces: libclang-common-14-dev (<< 14.0.6-10~exp4) +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: Compiler-rt - development package + This package provides various libraries: + . + * builtins - Simple libraries that provide implementation of the + low-level target-specific hooks required by code generation + and other runtime components. + * sanitizer runtimes - AddressSanitizer, ThreadSanitizer, + UndefinedBehaviorSanitizer, MemorySanitizer, LeakSanitizer + DataFlowSanitizer, etc + * profile - Library which is used to collect coverage information. + +Package: libclang-rt-14-dev-wasm32 +Architecture: all +Multi-Arch: foreign +Section: libdevel +Breaks: libclang-common-14-dev (<< 14.0.6-10~exp4) +Replaces: libclang-common-14-dev (<< 14.0.6-10~exp4) +Depends: ${shlibs:Depends}, ${misc:Depends} +Recommends: libclang-common-14-dev (>= 14.0.6-10~exp4) +Description: Compiler-rt - wasm32 builtins + Provides the compiler-rt builtins for WebAssembly 32 bits + +Package: libclang-rt-14-dev-wasm64 +Architecture: all +Multi-Arch: foreign +Section: libdevel +Breaks: libclang-common-14-dev (<< 14.0.6-10~exp4) +Replaces: libclang-common-14-dev (<< 14.0.6-10~exp4) +Depends: ${shlibs:Depends}, ${misc:Depends} +Recommends: libclang-common-14-dev (>= 14.0.6-10~exp4) +Description: Compiler-rt - wasm64 builtins + Provides the compiler-rt builtins for WebAssembly 64 bits + +# ------------- polly ------------- + +Package: libpolly-14-dev +Architecture: any +Multi-Arch: same +Section: libdevel +Breaks: libclang-rt-14-dev (<< 14.0.6-10~exp6), libclang-common-14-dev (<< 14.0.6-10~exp6) +Replaces: libclang-rt-14-dev (<< 14.0.6-10~exp6), libclang-common-14-dev (<< 14.0.6-10~exp6) +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: High-level loop and data-locality optimizer + Uses an abstract mathematical representation based on integer polyhedra + to analyze and optimize the memory access pattern of a program + +# ------------- clang libraries ------------- Package: libclang-cpp15 Section: libs @@ -647,6 +729,29 @@ Description: LLVM C++ Standard library (development files) as exception objects, rtti and memory allocation. * Extensive unit tests. +Package: libc++-14-dev-wasm32 +Section: libdevel +Architecture: all +Multi-Arch: foreign +Depends: wasi-libc, libc++abi-14-dev-wasm32, ${misc:Depends} +Provides: libc++-x.y-dev-wasm32 +Conflicts: libc++-x.y-dev-wasm32 +Replaces: libc++-x.y-dev-wasm32 +Description: LLVM C++ Standard library (WASI) + libc++ is another implementation of the C++ standard library + . + Features and Goals + . + * Correctness as defined by the C++ standards. + * Fast execution. + * Minimal memory use. + * Fast compile times. + * ABI compatibility with gcc's libstdc++ for some low-level features such + as exception objects, rtti and memory allocation. + * Extensive unit tests. + . + This package provides a version for the 32-bit WebAssembly System Interface. + # ------------- libcxxabi ------------- Package: libc++abi1-15 @@ -686,6 +791,25 @@ Description: LLVM low level support for a standard C++ library (development file * Correctness as defined by the C++ standards. * Provide a portable sublayer to ease the porting of libc++ +Package: libc++abi-14-dev-wasm32 +Section: libdevel +Architecture: all +Multi-Arch: foreign +Depends: wasi-libc, ${misc:Depends} +Provides: libc++abi-x.y-dev-wasm32 +Conflicts: libc++abi-x.y-dev-wasm32 +Replaces: libc++abi-x.y-dev-wasm32 +Description: LLVM low level support for a standard C++ library (WASI) + libc++abi is another implementation of low level support for a standard C++ + library. + . + Features and Goals + . + * Correctness as defined by the C++ standards. + * Provide a portable sublayer to ease the porting of libc++ + . + This package provides a version for the 32-bit WebAssembly System Interface. + # ------------- libclc ------------- Package: libclc-15 diff --git a/debian/control.in b/debian/control.in new file mode 100644 index 00000000..c324ea2d --- /dev/null +++ b/debian/control.in @@ -0,0 +1,910 @@ +Source: llvm-toolchain-@LLVM_VERSION@ +Section: devel +Priority: optional +Rules-Requires-Root: no +Maintainer: LLVM Packaging Team +Uploaders: Sylvestre Ledru , Gianfranco Costamagna +Build-Depends: debhelper (>= 10.0), cmake, ninja-build, + chrpath, texinfo, sharutils, + libelf-dev, + libffi-dev, + lsb-release, patchutils, diffstat, xz-utils, python3-dev, + libedit-dev, libncurses5-dev, swig, python3-six, python3-sphinx (>= 1.3.6), + binutils-dev, + libxml2-dev, + libjsoncpp-dev, pkg-config, + lcov, procps, help2man, zlib1g-dev, + g++-multilib [amd64 i386 kfreebsd-amd64 mips64 mips64el mipsel powerpc ppc64 s390 s390x sparc sparc64 x32], + libjs-mathjax, python3-recommonmark, + doxygen, + ocaml-base [amd64 arm64 armhf ppc64el riscv64 s390x] | ocaml-nox [amd64 arm64 armhf ppc64el riscv64 s390x], + ocaml-findlib [amd64 arm64 armhf ppc64el riscv64 s390x], + libctypes-ocaml-dev [amd64 arm64 armhf ppc64el riscv64 s390x], + dh-exec, dh-ocaml [amd64 arm64 armhf ppc64el riscv64 s390x], + libpfm4-dev [linux-any], python3-setuptools, libz3-dev, + llvm-spirv-14 [ amd64 arm64 armel armhf mips64el mipsel ppc64el s390x ] | hello [!i386], + spirv-tools [ linux-any ] | hello [ !i386], + wasi-libc | hello [ !i386], + libcurl4-dev, + libgrpc++-dev [amd64 arm64 armel armhf mips64el mipsel ppc64 ppc64el powerpc riscv64 s390x], + protobuf-compiler-grpc [amd64 arm64 armel armhf mips64el mipsel ppc64 ppc64el powerpc riscv64 s390x], + libprotobuf-dev [amd64 arm64 armel armhf mips64el mipsel ppc64 ppc64el powerpc riscv64 s390x], + protobuf-compiler [amd64 arm64 armel armhf mips64el mipsel ppc64 ppc64el powerpc riscv64 s390x] +# "| hello" is for older buster/bionic distros without spirv support +Build-Conflicts: oprofile +Standards-Version: 4.2.1 +Homepage: https://www.llvm.org/ +Vcs-Git: https://salsa.debian.org/pkg-llvm-team/llvm-toolchain.git -b @BRANCH_NAME@ +Vcs-Browser: https://salsa.debian.org/pkg-llvm-team/llvm-toolchain/tree/@BRANCH_NAME@ + +# ------------- clang ------------- + +Package: clang-@LLVM_VERSION@ +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, ${dep:devlibs}, + ${dep:devlibs-objc}, libclang-common-@LLVM_VERSION@-dev (= ${source:Version}), + llvm-@LLVM_VERSION@-linker-tools (= ${binary:Version}), + libclang1-@LLVM_VERSION@ (= ${binary:Version}), libc6-dev, binutils +Provides: c-compiler, objc-compiler, c++-compiler +Recommends: llvm-@LLVM_VERSION@-dev, python3 +# libomp-@LLVM_VERSION@-dev +Suggests: clang-@LLVM_VERSION@-doc, wasi-libc +Description: C, C++ and Objective-C compiler + Clang project is a C, C++, Objective C and Objective C++ front-end + based on the LLVM compiler. Its goal is to offer a replacement to the + GNU Compiler Collection (GCC). + . + Clang implements all of the ISO C++ 1998, 11, 14 and 17 standards and also + provides most of the support of C++20. + +Package: clang-tools-@LLVM_VERSION@ +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, clang-@LLVM_VERSION@ (= ${binary:Version}), + python3 +Description: clang-based tools for C/C++ developments + Clang project is a C, C++, Objective C and Objective C++ front-end + based on the LLVM compiler. Its goal is to offer a replacement to the + GNU Compiler Collection (GCC). + . + Clang implements all of the ISO C++ 1998, 11, 14 and 17 standards and also + provides most of the support of C++20. + . + This package contains some clang-based tools like scan-build, clang-cl, etc. + +Package: clang-format-@LLVM_VERSION@ +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, python3, + libllvm@LLVM_VERSION@ (= ${binary:Version}) +Description: Tool to format C/C++/Obj-C code + Clang-format is both a library and a stand-alone tool with the goal of + automatically reformatting C++ sources files according to configurable + style guides. To do so, clang-format uses Clang's Lexer to transform an + input file into a token stream and then changes all the whitespace around + those tokens. The goal is for clang-format to both serve both as a user + tool (ideally with powerful IDE integrations) and part of other + refactoring tools, e.g. to do a reformatting of all the lines changed + during a renaming. + . + This package also provides vim and emacs plugins. + +Package: clang-tidy-@LLVM_VERSION@ +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, python3, + libllvm@LLVM_VERSION@ (= ${binary:Version}), libclang-common-@LLVM_VERSION@-dev, + clang-tools-@LLVM_VERSION@, python3-yaml +Description: clang-based C++ linter tool + Provide an extensible framework for diagnosing and fixing typical programming + errors, like style violations, interface misuse, or bugs that can be deduced + via static analysis. clang-tidy is modular and provides a convenient interface + for writing new checks. + +Package: clangd-@LLVM_VERSION@ +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, + libclang-common-@LLVM_VERSION@-dev (= ${source:Version}) +Description: Language server that provides IDE-like features to editors + clangd understands your C++ code and adds smart features to your editor: + - code completion + - compile errors + - go-to-definition + - and more. + . + clangd is a language server that implements the Language Server Protocol; + it can work with many editors through a plugin. + +Package: clang-@LLVM_VERSION@-doc +Architecture: all +Section: doc +Depends: ${shlibs:Depends}, ${misc:Depends}, libjs-mathjax +Description: C, C++ and Objective-C compiler - Documentation + Clang project is a C, C++, Objective C and Objective C++ front-end + based on the LLVM compiler. Its goal is to offer a replacement to the + GNU Compiler Collection (GCC). + . + Clang implements all of the ISO C++ 1998, 11, 14 and 17 standards and also + provides most of the support of C++20. + . + This package contains the documentation. + +Package: libclang1-@LLVM_VERSION@ +Section: libs +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Pre-Depends: ${misc:Pre-Depends} +Description: C interface to the Clang library + Clang project is a C, C++, Objective C and Objective C++ front-end + based on the LLVM compiler. Its goal is to offer a replacement to the + GNU Compiler Collection (GCC). + . + Clang implements all of the ISO C++ 1998, 11, 14 and 17 standards and also + provides most of the support of C++20. + . + This package contains the Clang library. + . + The C Interface to Clang provides a relatively small API that exposes + facilities for parsing source code into an abstract syntax tree (AST), + loading already-parsed ASTs, traversing the AST, associating physical source + locations with elements within the AST, and other facilities that support + Clang-based development tools. + +Package: libclang-@LLVM_VERSION@-dev +Architecture: any +Section: libdevel +Depends: ${shlibs:Depends}, ${misc:Depends}, ${dep:devlibs}, + ${dep:devlibs-objc}, libclang1-@LLVM_VERSION@ (= ${binary:Version}), + libclang-common-@LLVM_VERSION@-dev (= ${source:Version}) +Breaks: llvm-@LLVM_VERSION@-dev (<< 1:14.0.4-2) +Replaces: llvm-@LLVM_VERSION@-dev (<< 1:14.0.4-2) +Description: Clang library - Development package + Clang project is a C, C++, Objective C and Objective C++ front-end + based on the LLVM compiler. Its goal is to offer a replacement to the + GNU Compiler Collection (GCC). + . + Clang implements all of the ISO C++ 1998, 11, 14 and 17 standards and also + provides most of the support of C++20. + . + This package contains the Clang headers to develop extensions over + libclang1-@LLVM_VERSION@. + +Package: libclang-common-@LLVM_VERSION@-dev +Architecture: all +Section: libdevel +Depends: ${shlibs:Depends}, ${misc:Depends}, libllvm@LLVM_VERSION@ (>= ${source:Version}) +Recommends: libclang-rt-@LLVM_VERSION@-dev (>= 14.0.6-10~exp4) +Description: Clang library - Common development package + Clang project is a C, C++, Objective C and Objective C++ front-end + based on the LLVM compiler. Its goal is to offer a replacement to the + GNU Compiler Collection (GCC). + . + Clang implements all of the ISO C++ 1998, 11, 14 and 17 standards and also + provides most of the support of C++20. + . + This package contains the Clang generic headers. + +# ------------- compiler-rt ------------- + +Package: libclang-rt-@LLVM_VERSION@-dev +Architecture: any +Multi-Arch: same +Section: libdevel +Breaks: libclang-common-@LLVM_VERSION@-dev (<< 14.0.6-10~exp4) +Replaces: libclang-common-@LLVM_VERSION@-dev (<< 14.0.6-10~exp4) +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: Compiler-rt - development package + This package provides various libraries: + . + * builtins - Simple libraries that provide implementation of the + low-level target-specific hooks required by code generation + and other runtime components. + * sanitizer runtimes - AddressSanitizer, ThreadSanitizer, + UndefinedBehaviorSanitizer, MemorySanitizer, LeakSanitizer + DataFlowSanitizer, etc + * profile - Library which is used to collect coverage information. + +Package: libclang-rt-@LLVM_VERSION@-dev-wasm32 +Architecture: all +Multi-Arch: foreign +Section: libdevel +Breaks: libclang-common-@LLVM_VERSION@-dev (<< 14.0.6-10~exp4) +Replaces: libclang-common-@LLVM_VERSION@-dev (<< 14.0.6-10~exp4) +Depends: ${shlibs:Depends}, ${misc:Depends} +Recommends: libclang-common-@LLVM_VERSION@-dev (>= 14.0.6-10~exp4) +Description: Compiler-rt - wasm32 builtins + Provides the compiler-rt builtins for WebAssembly 32 bits + +Package: libclang-rt-@LLVM_VERSION@-dev-wasm64 +Architecture: all +Multi-Arch: foreign +Section: libdevel +Breaks: libclang-common-@LLVM_VERSION@-dev (<< 14.0.6-10~exp4) +Replaces: libclang-common-@LLVM_VERSION@-dev (<< 14.0.6-10~exp4) +Depends: ${shlibs:Depends}, ${misc:Depends} +Recommends: libclang-common-@LLVM_VERSION@-dev (>= 14.0.6-10~exp4) +Description: Compiler-rt - wasm64 builtins + Provides the compiler-rt builtins for WebAssembly 64 bits + +# ------------- polly ------------- + +Package: libpolly-@LLVM_VERSION@-dev +Architecture: any +Multi-Arch: same +Section: libdevel +Breaks: libclang-rt-@LLVM_VERSION@-dev (<< 14.0.6-10~exp6), libclang-common-@LLVM_VERSION@-dev (<< 14.0.6-10~exp5) +Replaces: libclang-rt-@LLVM_VERSION@-dev (<< 14.0.6-10~exp6), libclang-common-@LLVM_VERSION@-dev (<< 14.0.6-10~exp5) +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: High-level loop and data-locality optimizer + Uses an abstract mathematical representation based on integer polyhedra + to analyze and optimize the memory access pattern of a program + +# ------------- clang libraries ------------- + +Package: libclang-cpp@LLVM_VERSION@ +Section: libs +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, libllvm@LLVM_VERSION@ (= ${binary:Version}) +Pre-Depends: ${misc:Pre-Depends} +Description: C++ interface to the Clang library + Clang project is a C, C++, Objective C and Objective C++ front-end + based on the LLVM compiler. Its goal is to offer a replacement to the + GNU Compiler Collection (GCC). + . + Clang implements all of the ISO C++ 1998, 11, 14 and 17 standards and also + provides most of the support of C++20. + . + This package contains the Clang C++ library. + . + The C++ Interface to Clang provides an API that exposes + facilities for parsing source code into an abstract syntax tree (AST), + loading already-parsed ASTs, traversing the AST, associating physical source + locations with elements within the AST, and other facilities that support + Clang-based development tools. + +Package: libclang-cpp@LLVM_VERSION@-dev +Architecture: any +Section: libdevel +Depends: ${shlibs:Depends}, ${misc:Depends}, ${dep:devlibs}, + libclang-cpp@LLVM_VERSION@ (= ${binary:Version}) +# Move of libclang-cpp.so into libclang-cpp@LLVM_VERSION@.dev +Description: C++ interface to the Clang library + Clang project is a C, C++, Objective C and Objective C++ front-end + based on the LLVM compiler. Its goal is to offer a replacement to the + GNU Compiler Collection (GCC). + . + Clang implements all of the ISO C++ 1998, 11, 14 and 17 standards and also + provides most of the support of C++20. + . + This package contains the Clang C++ library. + . + The C++ Interface to Clang provides an API that exposes + facilities for parsing source code into an abstract syntax tree (AST), + loading already-parsed ASTs, traversing the AST, associating physical source + locations with elements within the AST, and other facilities that support + Clang-based development tools. + . + This package contains symlinks without a version number, which needed by + linker at build time. + + +Package: libfuzzer-@LLVM_VERSION@-dev +Architecture: linux-any +Section: libdevel +Depends: ${shlibs:Depends}, ${misc:Depends}, clang-@LLVM_VERSION@ (= ${binary:Version}) +Description: Library for coverage-guided fuzz testing + LibFuzzer is a library for in-process, coverage-guided, evolutionary fuzzing + of other libraries. + . + LibFuzzer is similar in concept to American Fuzzy Lop (AFL), but it performs + all of its fuzzing inside a single process. This in-process fuzzing can be + more restrictive and fragile, but is potentially much faster as there is no + overhead for process start-up. + . + The fuzzer is linked with the library under test, and feeds fuzzed inputs to + the library via a specific fuzzing entrypoint (aka 'target function'); the + fuzzer then tracks which areas of the code are reached, and generates mutations + on the corpus of input data in order to maximize the code coverage. The code + coverage information for libFuzzer is provided by LLVM's SanitizerCoverage + instrumentation. + + +Package: python3-clang-@LLVM_VERSION@ +Section: python +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, python3, libclang-@LLVM_VERSION@-dev +Replaces: python-clang-x.y, +Conflicts: python-clang-x.y +Provides: python-clang-x.y +Description: Clang Python Bindings + Clang project is a C, C++, Objective C and Objective C++ front-end + based on the LLVM compiler. Its goal is to offer a replacement to the + GNU Compiler Collection (GCC). + . + Clang implements all of the ISO C++ 1998, 11, 14 and 17 standards and also + provides most of the support of C++20. + . + This binding package provides access to the Clang compiler and libraries. + +Package: clang-@LLVM_VERSION@-examples +Architecture: any +Section: doc +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: Clang examples + Clang project is a C, C++, Objective C and Objective C++ front-end + based on the LLVM compiler. Its goal is to offer a replacement to the + GNU Compiler Collection (GCC). + . + Clang implements all of the ISO C++ 1998, 11, 14 and 17 standards and also + provides most of the support of C++20. + . + This package contains the Clang examples. + +# ------------- LLVM ------------- + +Package: libllvm@LLVM_VERSION@ +Architecture: any +Section: libs +Depends: ${shlibs:Depends}, ${misc:Depends} +Pre-Depends: ${misc:Pre-Depends} +Multi-Arch: same +Description: Modular compiler and toolchain technologies, runtime library + LLVM is a collection of libraries and tools that make it easy to build + compilers, optimizers, just-in-time code generators, and many other + compiler-related programs. + . + This package contains the LLVM runtime library. + +Package: llvm-@LLVM_VERSION@-linker-tools +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: Modular compiler and toolchain technologies - Plugins + LLVM is a collection of libraries and tools that make it easy to build + compilers, optimizers, just-in-time code generators, and many other + compiler-related programs. + . + This package contains the LLVMgold and LLVMPolly linker plugins. + +Package: llvm-@LLVM_VERSION@ +Architecture: any +Suggests: llvm-@LLVM_VERSION@-doc +Depends: llvm-@LLVM_VERSION@-runtime (= ${binary:Version}), + llvm-@LLVM_VERSION@-linker-tools (= ${binary:Version}), + ${shlibs:Depends}, ${misc:Depends} +Recommends: llvm-@LLVM_VERSION@-dev +Description: Modular compiler and toolchain technologies + LLVM is a collection of libraries and tools that make it easy to build + compilers, optimizers, just-in-time code generators, and many other + compiler-related programs. + . + LLVM uses a single, language-independent virtual instruction set both + as an offline code representation (to communicate code between + compiler phases and to run-time systems) and as the compiler internal + representation (to analyze and transform programs). This persistent + code representation allows a common set of sophisticated compiler + techniques to be applied at compile-time, link-time, install-time, + run-time, or "idle-time" (between program runs). + . + The strengths of the LLVM infrastructure are its extremely + simple design (which makes it easy to understand and use), + source-language independence, powerful mid-level optimizer, automated + compiler debugging support, extensibility, and its stability and + reliability. LLVM is currently being used to host a wide variety of + academic research projects and commercial projects. LLVM includes C + and C++ front-ends, a front-end for a Forth-like language (Stacker), + a young scheme front-end, and Java support is in development. LLVM can + generate code for X96, SparcV10, PowerPC or many other architectures. + +Package: llvm-@LLVM_VERSION@-runtime +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Recommends: binfmt-support | systemd +Description: Modular compiler and toolchain technologies, IR interpreter + LLVM is a collection of libraries and tools that make it easy to build + compilers, optimizers, just-in-time code generators, and many other + compiler-related programs. + . + LLVM uses a single, language-independent virtual instruction set both + as an offline code representation (to communicate code between + compiler phases and to run-time systems) and as the compiler internal + representation (to analyze and transform programs). This persistent + code representation allows a common set of sophisticated compiler + techniques to be applied at compile-time, link-time, install-time, + run-time, or "idle-time" (between program runs). + . + This package provides the minimal required to execute programs in LLVM + format. + +Package: llvm-@LLVM_VERSION@-dev +Architecture: any +Depends: ${shlibs:Depends}, libffi-dev, ${misc:Depends}, + llvm-@LLVM_VERSION@ (= ${binary:Version}), libllvm@LLVM_VERSION@ (= ${binary:Version}), libtinfo-dev, + llvm-@LLVM_VERSION@-tools (= ${binary:Version}), libclang-cpp@LLVM_VERSION@ (= ${binary:Version}), + libz3-dev, libxml2-dev +Description: Modular compiler and toolchain technologies, libraries and headers + LLVM is a collection of libraries and tools that make it easy to build + compilers, optimizers, just-in-time code generators, and many other + compiler-related programs. + . + LLVM uses a single, language-independent virtual instruction set both + as an offline code representation (to communicate code between + compiler phases and to run-time systems) and as the compiler internal + representation (to analyze and transform programs). This persistent + code representation allows a common set of sophisticated compiler + techniques to be applied at compile-time, link-time, install-time, + run-time, or "idle-time" (between program runs). + . + This package provides the libraries and headers to develop applications + using llvm. + +Package: llvm-@LLVM_VERSION@-tools +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, python3, + python3-pygments, python3-yaml, +# Because of yaml-bench +Description: Modular compiler and toolchain technologies, tools + LLVM is a collection of libraries and tools that make it easy to build + compilers, optimizers, just-in-time code generators, and many other + compiler-related programs. + . + LLVM uses a single, language-independent virtual instruction set both + as an offline code representation (to communicate code between + compiler phases and to run-time systems) and as the compiler internal + representation (to analyze and transform programs). This persistent + code representation allows a common set of sophisticated compiler + techniques to be applied at compile-time, link-time, install-time, + run-time, or "idle-time" (between program runs). + . + This package provides tools for testing. + +Package: libllvm-@LLVM_VERSION@-ocaml-dev +Section: ocaml +Architecture: amd64 arm64 armhf ppc64el s390x riscv64 +Suggests: llvm-@LLVM_VERSION@-doc +Depends: ${shlibs:Depends}, ${misc:Depends}, ${ocaml:Depends}, llvm-@LLVM_VERSION@-dev (= ${binary:Version}) +Replaces: libllvm-x.y-ocaml-dev +Conflicts: libllvm-x.y-ocaml-dev +Provides: ${ocaml:Provides}, libllvm-x.y-ocaml-dev +Description: Modular compiler and toolchain technologies, OCaml bindings + LLVM is a collection of libraries and tools that make it easy to build + compilers, optimizers, just-in-time code generators, and many other + compiler-related programs. + . + LLVM uses a single, language-independent virtual instruction set both + as an offline code representation (to communicate code between + compiler phases and to run-time systems) and as the compiler internal + representation (to analyze and transform programs). This persistent + code representation allows a common set of sophisticated compiler + techniques to be applied at compile-time, link-time, install-time, + run-time, or "idle-time" (between program runs). + . + This package provides the OCaml bindings to develop applications using llvm. + +Package: llvm-@LLVM_VERSION@-doc +Section: doc +Architecture: all +Depends: ${misc:Depends}, libjs-jquery, libjs-underscore +Description: Modular compiler and toolchain technologies, documentation + LLVM is a collection of libraries and tools that make it easy to build + compilers, optimizers, just-in-time code generators, and many other + compiler-related programs. + . + LLVM uses a single, language-independent virtual instruction set both + as an offline code representation (to communicate code between + compiler phases and to run-time systems) and as the compiler internal + representation (to analyze and transform programs). This persistent + code representation allows a common set of sophisticated compiler + techniques to be applied at compile-time, link-time, install-time, + run-time, or "idle-time" (between program runs). + . + This package contains all documentation (extensive). + +Package: llvm-@LLVM_VERSION@-examples +Section: doc +Architecture: all +Depends: ${misc:Depends}, llvm-@LLVM_VERSION@-dev (>= ${source:Version}), llvm-@LLVM_VERSION@-dev (<< ${source:Version}+c~) +Description: Modular compiler and toolchain technologies, examples + LLVM is a collection of libraries and tools that make it easy to build + compilers, optimizers, just-in-time code generators, and many other + compiler-related programs. + . + LLVM uses a single, language-independent virtual instruction set both + as an offline code representation (to communicate code between + compiler phases and to run-time systems) and as the compiler internal + representation (to analyze and transform programs). This persistent + code representation allows a common set of sophisticated compiler + techniques to be applied at compile-time, link-time, install-time, + run-time, or "idle-time" (between program runs). + . + This package contains examples for using LLVM, both in developing + extensions to LLVM and in using it to compile code. + + +# ------------- lld ------------- + +Package: lld-@LLVM_VERSION@ +Architecture: amd64 arm64 armel armhf i386 mipsel mips64el ppc64el kfreebsd-amd64 kfreebsd-i386 s390 s390x sparc alpha hppa m68k powerpcspe ppc64 sh4 sparc64 x32 riscv64 +# ia64 hurd powerpc have been removed +Depends: ${shlibs:Depends}, ${misc:Depends}, libllvm@LLVM_VERSION@ (= ${binary:Version}) +Pre-Depends: ${misc:Pre-Depends} +Description: LLVM-based linker + LLD is a new, high-performance linker. It is built as a set of reusable + components which highly leverage existing libraries in the larger LLVM + Project. + +Package: liblld-@LLVM_VERSION@ +Architecture: amd64 arm64 armel armhf i386 mipsel mips64el ppc64el kfreebsd-amd64 kfreebsd-i386 s390 s390x sparc alpha hppa m68k powerpcspe ppc64 sh4 sparc64 x32 riscv64 +# ia64 hurd powerpc have been removed +Depends: ${shlibs:Depends}, ${misc:Depends}, libllvm@LLVM_VERSION@ (= ${binary:Version}) +Pre-Depends: ${misc:Pre-Depends} +Section: libs +Description: LLVM-based linker, library + LLD is a new, high-performance linker. It is built as a set of reusable + components which highly leverage existing libraries in the larger LLVM + Project. + . + This package contains the LLD runtime library. + +Package: liblld-@LLVM_VERSION@-dev +Section: libdevel +Architecture: amd64 arm64 armel armhf i386 mipsel mips64el ppc64el kfreebsd-amd64 kfreebsd-i386 s390 s390x sparc alpha hppa m68k powerpcspe ppc64 sh4 sparc64 x32 riscv64 +# ia64 hurd powerpc have been removed +Depends: ${shlibs:Depends}, ${misc:Depends}, lld-@LLVM_VERSION@ (= ${binary:Version}), + liblld-@LLVM_VERSION@ (= ${binary:Version}) +Pre-Depends: ${misc:Pre-Depends} +Description: LLVM-based linker, header files + LLD is a new, high-performance linker. It is built as a set of reusable + components which highly leverage existing libraries in the larger LLVM + Project. + . + This package provides the header files to build extension over lld. + + +# ------------- lldb ------------- + +Package: lldb-@LLVM_VERSION@ +Architecture: amd64 arm64 armel armhf i386 ppc64el kfreebsd-amd64 kfreebsd-i386 s390 s390x sparc hppa m68k sh4 x32 +# ia64 hurd powerpc powerpcspe ppc64 alpha riscv64 s390x sparc64 mipsel mips64el have been removed +Depends: ${shlibs:Depends}, ${misc:Depends}, libllvm@LLVM_VERSION@ (= ${binary:Version}), llvm-@LLVM_VERSION@-dev, + python3-lldb-@LLVM_VERSION@ +Pre-Depends: ${misc:Pre-Depends} +Description: Next generation, high-performance debugger + LLDB is a next generation, high-performance debugger. It is built as a set of + reusable components which highly leverage existing libraries in the larger LLVM + Project, such as the Clang expression parser and LLVM disassembler. + +Package: liblldb-@LLVM_VERSION@ +Architecture: amd64 arm64 armel armhf i386 ppc64el kfreebsd-amd64 kfreebsd-i386 s390 s390x sparc hppa m68k sh4 x32 +# ia64 hurd powerpc powerpcspe ppc64 alpha riscv64 s390x sparc64 mipsel mips64el have been removed +Depends: ${shlibs:Depends}, ${misc:Depends}, libllvm@LLVM_VERSION@ (= ${binary:Version}) +Pre-Depends: ${misc:Pre-Depends} +Section: libs +Description: Next generation, high-performance debugger, library + LLDB is a next generation, high-performance debugger. It is built as a set of + reusable components which highly leverage existing libraries in the larger LLVM + Project, such as the Clang expression parser and LLVM disassembler. + . + This package contains the LLDB runtime library. + +Package: python3-lldb-@LLVM_VERSION@ +Section: python +Architecture: amd64 arm64 armel armhf i386 ppc64el kfreebsd-amd64 kfreebsd-i386 s390 s390x sparc hppa m68k sh4 x32 +# ia64 hurd powerpc powerpcspe ppc64 alpha riscv64 s390x sparc64 mipsel mips64el have been removed +Depends: ${shlibs:Depends}, ${misc:Depends}, ${python3:Depends}, liblldb-@LLVM_VERSION@ (= ${binary:Version}), python3-six +Conflicts: python3-lldb-x.y +Replaces: python3-lldb-x.y +Provides: python3-lldb-x.y +Pre-Depends: ${misc:Pre-Depends} +Description: Next generation, high-performance debugger, python3 lib + LLDB is a next generation, high-performance debugger. It is built as a set of + reusable components which highly leverage existing libraries in the larger LLVM + Project, such as the Clang expression parser and LLVM disassembler. + . + This binding package provides access to lldb. + +Package: liblldb-@LLVM_VERSION@-dev +Section: libdevel +Architecture: amd64 arm64 armel armhf i386 ppc64el kfreebsd-amd64 kfreebsd-i386 s390 s390x sparc hppa m68k sh4 x32 +# ia64 hurd powerpc powerpcspe ppc64 alpha riscv64 s390x sparc64 mipsel mips64el have been removed +Depends: ${shlibs:Depends}, ${misc:Depends}, lldb-@LLVM_VERSION@ (= ${binary:Version}) +Pre-Depends: ${misc:Pre-Depends} +Description: Next generation, high-performance debugger, header files + LLDB is a next generation, high-performance debugger. It is built as a set of + reusable components which highly leverage existing libraries in the larger LLVM + Project, such as the Clang expression parser and LLVM disassembler. + . + This package provides the header files to build extension over lldb. + + +# ------------- openmp ------------- +# 44 because it was the first version in which openmp & libc++ have been +# managed in llvm-defaults + +Package: libomp-@LLVM_VERSION@-dev +Section: libdevel +Architecture: amd64 arm64 armhf i386 mips64el ppc64el ppc64 riscv64 +Depends: libomp5-@LLVM_VERSION@ (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends} +Suggests: libomp-@LLVM_VERSION@-doc +Breaks: libiomp-dev (<< 3.7-1), libomp-dev (<< 44), llvm-@LLVM_VERSION@ (<< 1:14~++20211011113307+f7ca54289c14) +Provides: libomp-x.y-dev +Conflicts: libomp-x.y-dev +Replaces: libomp-x.y-dev, llvm-@LLVM_VERSION@ (<< 1:14~++20211011113307+f7ca54289c14) +Description: LLVM OpenMP runtime - dev package + The runtime is the part of the OpenMP implementation that your code is + linked against, and that manages the multiple threads in an OpenMP program + while it is executing. + +Package: libomp5-@LLVM_VERSION@ +Multi-Arch: same +Architecture: amd64 arm64 armhf i386 mips64el ppc64el ppc64 riscv64 +Depends: ${shlibs:Depends}, ${misc:Depends} +Breaks: libomp5 (<< 44) +Provides: libomp-x.y +Conflicts: libomp-x.y +Replaces: libomp-x.y +Description: LLVM OpenMP runtime + The runtime is the part of the OpenMP implementation that your code is + linked against, and that manages the multiple threads in an OpenMP program + while it is executing. + +Package: libomp-@LLVM_VERSION@-doc +Section: doc +Architecture: amd64 arm64 armhf i386 mips64el ppc64el ppc64 riscv64 +Depends: ${shlibs:Depends}, ${misc:Depends}, libjs-jquery +Replaces: libiomp-x.y-doc +Breaks: libiomp-x.y-doc +Description: LLVM OpenMP runtime - Documentation + The runtime is the part of the OpenMP implementation that your code is + linked against, and that manages the multiple threads in an OpenMP program + while it is executing. + . + This package contains the documentation of this package. + +# ------------- libcxx ------------- + +Package: libc++1-@LLVM_VERSION@ +Section: libs +Architecture: any +Multi-Arch: same +Pre-Depends: ${misc:Pre-Depends} +Depends: ${shlibs:Depends}, ${misc:Depends} +Suggests: clang +Breaks: libc++1 (<< 44) +Provides: libc++-x.y +Conflicts: libc++-x.y +Replaces: libc++-x.y +Description: LLVM C++ Standard library + libc++ is another implementation of the C++ standard library. + . + Features and Goals + . + * Correctness as defined by the C++ standards. + * Fast execution. + * Minimal memory use. + * Fast compile times. + * ABI compatibility with gcc's libstdc++ for some low-level features such + as exception objects, rtti and memory allocation. + * Extensive unit tests. + +Package: libc++-@LLVM_VERSION@-dev +Section: libdevel +Architecture: any +Multi-Arch: same +Depends: libc++1-@LLVM_VERSION@ (= ${binary:Version}), ${misc:Depends}, + libunwind-@LLVM_VERSION@-dev [amd64 arm64 armhf i386 mips64el ppc64el ppc64 riscv64] +Breaks: libc++-dev (<< 44) +Provides: libc++-x.y-dev +Conflicts: libc++-x.y-dev +Replaces: libc++-x.y-dev +Description: LLVM C++ Standard library (development files) + libc++ is another implementation of the C++ standard library + . + Features and Goals + . + * Correctness as defined by the C++ standards. + * Fast execution. + * Minimal memory use. + * Fast compile times. + * ABI compatibility with gcc's libstdc++ for some low-level features such + as exception objects, rtti and memory allocation. + * Extensive unit tests. + +Package: libc++-@LLVM_VERSION@-dev-wasm32 +Section: libdevel +Architecture: all +Multi-Arch: foreign +Depends: wasi-libc, libc++abi-@LLVM_VERSION@-dev-wasm32, ${misc:Depends} +Provides: libc++-x.y-dev-wasm32 +Conflicts: libc++-x.y-dev-wasm32 +Replaces: libc++-x.y-dev-wasm32 +Description: LLVM C++ Standard library (WASI) + libc++ is another implementation of the C++ standard library + . + Features and Goals + . + * Correctness as defined by the C++ standards. + * Fast execution. + * Minimal memory use. + * Fast compile times. + * ABI compatibility with gcc's libstdc++ for some low-level features such + as exception objects, rtti and memory allocation. + * Extensive unit tests. + . + This package provides a version for the 32-bit WebAssembly System Interface. + +# ------------- libcxxabi ------------- + +Package: libc++abi1-@LLVM_VERSION@ +Section: libs +Architecture: any +Multi-Arch: same +Pre-Depends: ${misc:Pre-Depends} +Depends: ${shlibs:Depends}, ${misc:Depends} +Breaks: libc++abi1 (<< 44) +Provides: libc++abi-x.y +Conflicts: libc++abi-x.y +Replaces: libc++abi-x.y +Description: LLVM low level support for a standard C++ library + libc++abi is another implementation of low level support for a standard C++ + library. + . + Features and Goals + . + * Correctness as defined by the C++ standards. + * Provide a portable sublayer to ease the porting of libc++ + +Package: libc++abi-@LLVM_VERSION@-dev +Section: libdevel +Architecture: any +Multi-Arch: same +Depends: libc++abi1-@LLVM_VERSION@ (= ${binary:Version}), ${misc:Depends} +Breaks: libc++abi-dev (<= 44) +Provides: libc++abi-x.y-dev +Conflicts: libc++abi-x.y-dev +Replaces: libc++abi-x.y-dev +Description: LLVM low level support for a standard C++ library (development files) + libc++abi is another implementation of low level support for a standard C++ + library. + . + Features and Goals + . + * Correctness as defined by the C++ standards. + * Provide a portable sublayer to ease the porting of libc++ + +Package: libc++abi-@LLVM_VERSION@-dev-wasm32 +Section: libdevel +Architecture: all +Multi-Arch: foreign +Depends: wasi-libc, ${misc:Depends} +Provides: libc++abi-x.y-dev-wasm32 +Conflicts: libc++abi-x.y-dev-wasm32 +Replaces: libc++abi-x.y-dev-wasm32 +Description: LLVM low level support for a standard C++ library (WASI) + libc++abi is another implementation of low level support for a standard C++ + library. + . + Features and Goals + . + * Correctness as defined by the C++ standards. + * Provide a portable sublayer to ease the porting of libc++ + . + This package provides a version for the 32-bit WebAssembly System Interface. + +# ------------- libclc ------------- + +Package: libclc-@LLVM_VERSION@ +Section: libs +Architecture: all +Multi-Arch: foreign +Depends: + ${misc:Depends}, + libclc-@LLVM_VERSION@-dev (= ${binary:Version}), + libclang-common-@LLVM_VERSION@-dev, +Breaks: libclc-amdgcn, libclc-ptx, libclc-r600 +Provides: libclc-x.y +Conflicts: libclc-x.y +Replaces: libclc-x.y, libclc-amdgcn, libclc-ptx, libclc-r600, +Description: OpenCL C language implementation - platform support + libclc is an open implementation of the OpenCL C programming language, + as specified by the OpenCL 1.1 Specification. + . + This package contains support for the amdgcn (AMD GPU), PTX and r600 + platforms. + +Package: libclc-@LLVM_VERSION@-dev +Section: libdevel +Architecture: all +Multi-Arch: foreign +Depends: + ${misc:Depends}, +Breaks: libclc-dev +Provides: libclc-x.y-dev +Conflicts: libclc-x.y-dev +Replaces: libclc-dev, libclc-x.y-dev +Description: OpenCL C language implementation - development files + libclc is an open implementation of the OpenCL C programming language, + as specified by the OpenCL 1.1 Specification. + . + This package contains development header files. + +# ------------- libunwind ------------- + +Package: libunwind-@LLVM_VERSION@ +Section: libs +Architecture: amd64 arm64 armhf i386 mips64el ppc64el ppc64 riscv64 +Multi-Arch: same +Depends: ${shlibs:Depends}, + ${misc:Depends} +Provides: libunwind-x.y +Conflicts: libunwind-x.y +Replaces: libunwind-x.y +Description: production-quality unwinder + libunwind is a production-quality unwinder, with platform support for DWARF + unwind info, SjLj, and ARM EHABI. + . + The low level libunwind API was designed to work either in-process (aka local) + or to operate on another process (aka remote), but only the local path has + been implemented. Remote unwinding remains as future work. + +Package: libunwind-@LLVM_VERSION@-dev +Section: libdevel +Architecture: amd64 arm64 armhf i386 mips64el ppc64el ppc64 riscv64 +Multi-Arch: same +Depends: + ${misc:Depends}, + libunwind-@LLVM_VERSION@ (= ${binary:Version}) +Provides: libunwind-dev, libunwind-x.y-dev +Conflicts: libunwind-dev, libunwind-x.y-dev +Replaces: libunwind-dev, libunwind-x.y-dev +Description: production-quality unwinder + libunwind is a production-quality unwinder, with platform support for DWARF + unwind info, SjLj, and ARM EHABI. + . + The low level libunwind API was designed to work either in-process (aka local) + or to operate on another process (aka remote), but only the local path has + been implemented. Remote unwinding remains as future work. + +# ------------- mlir ------------- + +Package: mlir-@LLVM_VERSION@-tools +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Description: Multi-Level Intermediate Representation tools + Novel approach to building reusable and extensible compiler infrastructure. + MLIR aims to address software fragmentation, improve compilation for + heterogeneous hardware, significantly reduce the cost of building domain + specific compilers, and aid in connecting existing compilers together. + . + This package provides tools. + +Package: libmlir-@LLVM_VERSION@ +Section: libs +Architecture: any +Multi-Arch: same +Depends: ${shlibs:Depends}, + ${misc:Depends} +Provides: libmlir-x.y +Conflicts: libmlir-x.y +Replaces: libmlir-x.y +Description: Multi-Level Intermediate Representation library + Novel approach to building reusable and extensible compiler infrastructure. + MLIR aims to address software fragmentation, improve compilation for + heterogeneous hardware, significantly reduce the cost of building domain + specific compilers, and aid in connecting existing compilers together. + + +Package: libmlir-@LLVM_VERSION@-dev +Section: libdevel +Architecture: any +Multi-Arch: same +Depends: + ${misc:Depends}, + libmlir-@LLVM_VERSION@ (= ${binary:Version}) +Breaks: libmlir-dev +Provides: libmlir-x.y-dev +Conflicts: libmlir-x.y-dev +Replaces: libmlir-dev, libmlir-x.y-dev +Description: Multi-Level Intermediate Representation library + Novel approach to building reusable and extensible compiler infrastructure. + MLIR aims to address software fragmentation, improve compilation for + heterogeneous hardware, significantly reduce the cost of building domain + specific compilers, and aid in connecting existing compilers together. + + diff --git a/debian/libc++-X.Y-dev-wasm32.install.in b/debian/libc++-X.Y-dev-wasm32.install.in new file mode 100644 index 00000000..13c31f09 --- /dev/null +++ b/debian/libc++-X.Y-dev-wasm32.install.in @@ -0,0 +1,3 @@ +usr/lib/llvm-@LLVM_VERSION@/lib/wasm32-wasi/libc++.a +usr/lib/llvm-@LLVM_VERSION@/include/wasm32-wasi/c++/ +usr/lib/llvm-@LLVM_VERSION@/include/wasm32-wasi/c++/v1/ diff --git a/debian/libc++-X.Y-dev-wasm32.links.in b/debian/libc++-X.Y-dev-wasm32.links.in new file mode 100644 index 00000000..465536e9 --- /dev/null +++ b/debian/libc++-X.Y-dev-wasm32.links.in @@ -0,0 +1,2 @@ +usr/lib/llvm-@LLVM_VERSION@/lib/wasm32-wasi/libc++.a /usr/lib/wasm32-wasi/libc++.a +usr/lib/llvm-@LLVM_VERSION@/include/wasm32-wasi/c++/v1 /usr/include/wasm32-wasi/c++/v1 diff --git a/debian/libc++-X.Y-dev-wasm32.lintian-overrides.in b/debian/libc++-X.Y-dev-wasm32.lintian-overrides.in new file mode 100644 index 00000000..4cad189a --- /dev/null +++ b/debian/libc++-X.Y-dev-wasm32.lintian-overrides.in @@ -0,0 +1 @@ +libc++-@LLVM_VERSION@-dev-wasm32: arch-independent-package-contains-binary-or-object usr/lib/llvm-@LLVM_VERSION@/lib/wasm32-wasi/libc++.a \ No newline at end of file diff --git a/debian/libc++abi-X.Y-dev-wasm32.install.in b/debian/libc++abi-X.Y-dev-wasm32.install.in new file mode 100644 index 00000000..1d6e8500 --- /dev/null +++ b/debian/libc++abi-X.Y-dev-wasm32.install.in @@ -0,0 +1 @@ +usr/lib/llvm-@LLVM_VERSION@/lib/wasm32-wasi/libc++abi.a diff --git a/debian/libc++abi-X.Y-dev-wasm32.links.in b/debian/libc++abi-X.Y-dev-wasm32.links.in new file mode 100644 index 00000000..c1655fbf --- /dev/null +++ b/debian/libc++abi-X.Y-dev-wasm32.links.in @@ -0,0 +1 @@ +usr/lib/llvm-@LLVM_VERSION@/lib/wasm32-wasi/libc++abi.a /usr/lib/wasm32-wasi/libc++abi.a diff --git a/debian/libc++abi-X.Y-dev-wasm32.lintian-overrides.in b/debian/libc++abi-X.Y-dev-wasm32.lintian-overrides.in new file mode 100644 index 00000000..76ba43d2 --- /dev/null +++ b/debian/libc++abi-X.Y-dev-wasm32.lintian-overrides.in @@ -0,0 +1 @@ +libc++abi-@LLVM_VERSION@-dev-wasm32: arch-independent-package-contains-binary-or-object usr/lib/llvm-@LLVM_VERSION@/lib/wasm32-wasi/libc++abi.a \ No newline at end of file diff --git a/debian/libclang-common-X.Y-dev.install.in b/debian/libclang-common-X.Y-dev.install.in index 303ed2ca..89fbf8a3 100644 --- a/debian/libclang-common-X.Y-dev.install.in +++ b/debian/libclang-common-X.Y-dev.install.in @@ -1,9 +1,9 @@ -#!/usr/bin/dh-exec -usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/include -usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/lib -usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/*.txt -usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/share/*.txt - -[!powerpc !powerpcspe] usr/lib/llvm-@LLVM_VERSION@/lib/libPolly*.a +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/include/*.h +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/include/module.modulemap +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/include/xray/ +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/include/profile/ +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/include/ppc_wrappers/ +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/include/openmp_wrappers/ +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/include/cuda_wrappers/ diff --git a/debian/libclang-rt-X.Y-dev-wasm32.install.in b/debian/libclang-rt-X.Y-dev-wasm32.install.in new file mode 100644 index 00000000..2f223e7f --- /dev/null +++ b/debian/libclang-rt-X.Y-dev-wasm32.install.in @@ -0,0 +1,2 @@ +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/lib/wasi/libclang_rt.builtins-wasm32.a + diff --git a/debian/libclang-rt-X.Y-dev-wasm32.lintian-overrides.in b/debian/libclang-rt-X.Y-dev-wasm32.lintian-overrides.in new file mode 100644 index 00000000..47b7f52f --- /dev/null +++ b/debian/libclang-rt-X.Y-dev-wasm32.lintian-overrides.in @@ -0,0 +1,4 @@ +libclang-rt-@LLVM_VERSION@-dev-wasm32: arch-independent-package-contains-binary-or-object *usr/lib/llvm-@LLVM_VERSION@/lib/* +libclang-rt-@LLVM_VERSION@-dev-wasm32: arch-dependent-file-not-in-arch-specific-directory *usr/lib/llvm-@LLVM_VERSION@/lib/* +# wasm code +libclang-rt-@LLVM_VERSION@-dev-wasm32: no-code-sections *usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/lib/wasi/libclang_rt.builtins-wasm32.a* diff --git a/debian/libclang-rt-X.Y-dev-wasm64.install.in b/debian/libclang-rt-X.Y-dev-wasm64.install.in new file mode 100644 index 00000000..b8594282 --- /dev/null +++ b/debian/libclang-rt-X.Y-dev-wasm64.install.in @@ -0,0 +1,2 @@ +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/lib/wasi/libclang_rt.builtins-wasm64.a + diff --git a/debian/libclang-rt-X.Y-dev-wasm64.lintian-overrides.in b/debian/libclang-rt-X.Y-dev-wasm64.lintian-overrides.in new file mode 100644 index 00000000..a3a81721 --- /dev/null +++ b/debian/libclang-rt-X.Y-dev-wasm64.lintian-overrides.in @@ -0,0 +1,4 @@ +libclang-rt-@LLVM_VERSION@-dev-wasm64: arch-independent-package-contains-binary-or-object *usr/lib/llvm-@LLVM_VERSION@/lib/* +libclang-rt-@LLVM_VERSION@-dev-wasm64: arch-dependent-file-not-in-arch-specific-directory *usr/lib/llvm-@LLVM_VERSION@/lib/* +# wasm code +libclang-rt-@LLVM_VERSION@-dev-wasm64: no-code-sections *usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/lib/wasi/libclang_rt.builtins-wasm64.a* diff --git a/debian/libclang-rt-X.Y-dev.install.in b/debian/libclang-rt-X.Y-dev.install.in new file mode 100644 index 00000000..49a9d2f8 --- /dev/null +++ b/debian/libclang-rt-X.Y-dev.install.in @@ -0,0 +1,5 @@ +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/share/*.txt +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/include/sanitizer/ +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/lib/linux/*clang_rt* +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/README.txt +usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/include/fuzzer/ diff --git a/debian/libclang-rt-X.Y-dev.lintian-overrides.in b/debian/libclang-rt-X.Y-dev.lintian-overrides.in new file mode 100644 index 00000000..5c99be12 --- /dev/null +++ b/debian/libclang-rt-X.Y-dev.lintian-overrides.in @@ -0,0 +1,2 @@ +libclang-rt-@LLVM_VERSION@-dev: arch-dependent-file-not-in-arch-specific-directory *usr/lib/llvm-@LLVM_VERSION@/lib/* +libclang-rt-@LLVM_VERSION@-dev: no-code-sections *usr/lib/llvm-@LLVM_VERSION@/lib/clang/@LLVM_VERSION@*/lib/linux/libclang_rt.asan_static-i386.a* \ No newline at end of file diff --git a/debian/libpolly-X.Y-dev.install.in b/debian/libpolly-X.Y-dev.install.in new file mode 100644 index 00000000..12c1309d --- /dev/null +++ b/debian/libpolly-X.Y-dev.install.in @@ -0,0 +1,3 @@ +#!/usr/bin/dh-exec + +[!powerpc !powerpcspe] usr/lib/llvm-@LLVM_VERSION@/lib/libPolly*.a diff --git a/debian/libpolly-X.Y-dev.lintian-overrides.in b/debian/libpolly-X.Y-dev.lintian-overrides.in new file mode 100644 index 00000000..0e12e159 --- /dev/null +++ b/debian/libpolly-X.Y-dev.lintian-overrides.in @@ -0,0 +1 @@ +libpolly-@LLVM_VERSION@-dev: arch-dependent-file-not-in-arch-specific-directory *usr/lib/llvm-@LLVM_VERSION@/lib/libPolly*.a* diff --git a/debian/patches/basic_string.patch b/debian/patches/basic_string.patch new file mode 100644 index 00000000..ceefe082 --- /dev/null +++ b/debian/patches/basic_string.patch @@ -0,0 +1,87 @@ +From c081bf4098c729afacf20303cc9df62bf13c3362 Mon Sep 17 00:00:00 2001 +From: serge-sans-paille +Date: Sat, 18 Jun 2022 13:48:41 +0200 +Subject: [PATCH] [clang] Enforce instantiation of constexpr template functions + during non-constexpr evaluation + +Otherwise these functions are not instantiated and we end up with an undefined +symbol. + +Fix #55560 + +Differential Revision: https://reviews.llvm.org/D128119 +--- + clang/lib/Sema/SemaTemplateInstantiateDecl.cpp | 5 +++-- + .../CodeGenCXX/constexpr-late-instantiation.cpp | 17 +++++++++++++++++ + .../SemaCXX/constexpr-late-instantiation.cpp | 15 +++++++++++++++ + 3 files changed, 35 insertions(+), 2 deletions(-) + create mode 100644 clang/test/CodeGenCXX/constexpr-late-instantiation.cpp + create mode 100644 clang/test/SemaCXX/constexpr-late-instantiation.cpp + +diff --git a/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp b/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp +index 467372c71496a..293782822e839 100644 +--- a/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp ++++ b/clang/lib/Sema/SemaTemplateInstantiateDecl.cpp +@@ -4826,7 +4826,8 @@ void Sema::InstantiateFunctionDefinition(SourceLocation PointOfInstantiation, + /*Complain*/DefinitionRequired)) { + if (DefinitionRequired) + Function->setInvalidDecl(); +- else if (TSK == TSK_ExplicitInstantiationDefinition) { ++ else if (TSK == TSK_ExplicitInstantiationDefinition || ++ (Function->isConstexpr() && !Recursive)) { + // Try again at the end of the translation unit (at which point a + // definition will be required). + assert(!Recursive); +@@ -4841,7 +4842,7 @@ void Sema::InstantiateFunctionDefinition(SourceLocation PointOfInstantiation, + Diag(PatternDecl->getLocation(), diag::note_forward_template_decl); + if (getLangOpts().CPlusPlus11) + Diag(PointOfInstantiation, diag::note_inst_declaration_hint) +- << Function; ++ << Function; + } + } + +diff --git a/clang/test/CodeGenCXX/constexpr-late-instantiation.cpp b/clang/test/CodeGenCXX/constexpr-late-instantiation.cpp +new file mode 100644 +index 0000000000000..1c8eef73f2dda +--- /dev/null ++++ b/clang/test/CodeGenCXX/constexpr-late-instantiation.cpp +@@ -0,0 +1,17 @@ ++// Make sure foo is instantiated and we don't get a link error ++// RUN: %clang_cc1 -S -emit-llvm -triple %itanium_abi_triple %s -o- | FileCheck %s ++ ++template ++constexpr T foo(T a); ++ ++// CHECK-LABEL: define {{.*}} @main ++int main() { ++ // CHECK: call {{.*}} @_Z3fooIiET_S0_ ++ int k = foo(5); ++} ++// CHECK: } ++ ++template ++constexpr T foo(T a) { ++ return a; ++} +diff --git a/clang/test/SemaCXX/constexpr-late-instantiation.cpp b/clang/test/SemaCXX/constexpr-late-instantiation.cpp +new file mode 100644 +index 0000000000000..ec8e071217c1d +--- /dev/null ++++ b/clang/test/SemaCXX/constexpr-late-instantiation.cpp +@@ -0,0 +1,15 @@ ++// RUN: %clang_cc1 %s -fsyntax-only -verify ++ ++template ++constexpr T foo(T a); // expected-note {{declared here}} ++ ++int main() { ++ int k = foo(5); // Ok ++ constexpr int j = // expected-error {{constexpr variable 'j' must be initialized by a constant expression}} ++ foo(5); // expected-note {{undefined function 'foo' cannot be used in a constant expression}} ++} ++ ++template ++constexpr T foo(T a) { ++ return a; ++} diff --git a/debian/patches/series b/debian/patches/series index bee43cb8..570f3b66 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -153,7 +153,6 @@ bolt-disable-emit-relocs.patch D124841-fix-powerpc-miscompile.patch mips/mips-assert-size.diff protobuf_3.21.patch - # upstream cherry-pick for mesa build add-arm-vcmpz-test.patch fix-mesa-build.patch diff --git a/debian/patches/wasm/wasm-sysroot-usr.diff b/debian/patches/wasm/wasm-sysroot-usr.diff index ae73057b..e3270aa2 100644 --- a/debian/patches/wasm/wasm-sysroot-usr.diff +++ b/debian/patches/wasm/wasm-sysroot-usr.diff @@ -17,17 +17,25 @@ if (!DriverArgs.hasArg(options::OPT_nobuiltininc)) { SmallString<128> P(D.ResourceDir); -@@ -427,10 +428,10 @@ void WebAssembly::AddClangSystemIncludeA +@@ -427,10 +428,18 @@ void WebAssembly::AddClangSystemIncludeA ++ // add the multiarch path on e.g. wasm32-wasi if (getTriple().getOS() != llvm::Triple::UnknownOS) { const std::string MultiarchTriple = - getMultiarchTriple(D, getTriple(), D.SysRoot); - addSystemInclude(DriverArgs, CC1Args, D.SysRoot + "/include/" + MultiarchTriple); + getMultiarchTriple(D, getTriple(), SysRoot); ++ addSystemInclude(DriverArgs, CC1Args, SysRoot + "/local/include/" + MultiarchTriple); ++ addSystemInclude(DriverArgs, CC1Args, SysRoot + "/local/include"); + addSystemInclude(DriverArgs, CC1Args, SysRoot + "/include/" + MultiarchTriple); } - addSystemInclude(DriverArgs, CC1Args, D.SysRoot + "/include"); -+ addSystemInclude(DriverArgs, CC1Args, SysRoot + "/include"); ++ ++ // also add the non-multiarch path, only on a known OS (as above), or when ++ // a sysroot is given, for backwards compatibility with the original driver ++ if (getTriple().getOS() != llvm::Triple::UnknownOS || ++ !getDriver().SysRoot.empty()) ++ addSystemInclude(DriverArgs, CC1Args, SysRoot + "/include"); } void WebAssembly::AddClangCXXStdlibIncludeArgs(const ArgList &DriverArgs, diff --git a/debian/qualify-clang.sh b/debian/qualify-clang.sh index d4ef73eb..0f042330 100755 --- a/debian/qualify-clang.sh +++ b/debian/qualify-clang.sh @@ -9,7 +9,8 @@ VERSION=$(dpkg-parsechangelog | sed -rne "s,^Version: 1:([0-9]+).*,\1,p") DETAILED_VERSION=$(dpkg-parsechangelog | sed -rne "s,^Version: 1:([0-9.]+)(~|-)(.*),\1\2\3,p") DEB_HOST_ARCH=$(dpkg-architecture -qDEB_HOST_ARCH) -LIST="libomp5-${VERSION}_${DETAILED_VERSION}_amd64.deb libomp-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb lldb-${VERSION}_${DETAILED_VERSION}_amd64.deb python3-lldb-${VERSION}_${DETAILED_VERSION}_amd64.deb libllvm${VERSION}_${DETAILED_VERSION}_amd64.deb llvm-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb liblldb-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libclang1-${VERSION}_${DETAILED_VERSION}_amd64.deb libclang-common-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb llvm-${VERSION}_${DETAILED_VERSION}_amd64.deb liblldb-${VERSION}_${DETAILED_VERSION}_amd64.deb llvm-${VERSION}-runtime_${DETAILED_VERSION}_amd64.deb lld-${VERSION}_${DETAILED_VERSION}_amd64.deb libfuzzer-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libclang-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libc++-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libc++abi-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libc++1-${VERSION}_${DETAILED_VERSION}_amd64.deb libc++abi1-${VERSION}_${DETAILED_VERSION}_amd64.deb clang-${VERSION}_${DETAILED_VERSION}_amd64.deb llvm-${VERSION}-tools_${DETAILED_VERSION}_amd64.deb clang-tools-${VERSION}_${DETAILED_VERSION}_amd64.deb clangd-${VERSION}_${DETAILED_VERSION}_amd64.deb libclang-cpp${VERSION}_${DETAILED_VERSION}_amd64.deb clang-tidy-${VERSION}_${DETAILED_VERSION}_amd64.deb libclang-cpp${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libclc-${VERSION}_${DETAILED_VERSION}_all.deb libclc-${VERSION}-dev_${DETAILED_VERSION}_all.deb llvm-${VERSION}-linker-tools_${DETAILED_VERSION}_amd64.deb libunwind-${VERSION}_${DETAILED_VERSION}_amd64.deb libunwind-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libmlir-${VERSION}_${DETAILED_VERSION}_amd64.deb libmlir-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb bolt-${VERSION}_${DETAILED_VERSION}_amd64.deb libbolt-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb" +LIST="libomp5-${VERSION}_${DETAILED_VERSION}_amd64.deb libomp-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb lldb-${VERSION}_${DETAILED_VERSION}_amd64.deb python3-lldb-${VERSION}_${DETAILED_VERSION}_amd64.deb libllvm${VERSION}_${DETAILED_VERSION}_amd64.deb llvm-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb liblldb-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libclang1-${VERSION}_${DETAILED_VERSION}_amd64.deb libclang-common-${VERSION}-dev_${DETAILED_VERSION}_all.deb llvm-${VERSION}_${DETAILED_VERSION}_amd64.deb liblldb-${VERSION}_${DETAILED_VERSION}_amd64.deb llvm-${VERSION}-runtime_${DETAILED_VERSION}_amd64.deb lld-${VERSION}_${DETAILED_VERSION}_amd64.deb libfuzzer-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libclang-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libc++-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libc++abi-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libc++1-${VERSION}_${DETAILED_VERSION}_amd64.deb libc++abi1-${VERSION}_${DETAILED_VERSION}_amd64.deb clang-${VERSION}_${DETAILED_VERSION}_amd64.deb llvm-${VERSION}-tools_${DETAILED_VERSION}_amd64.deb clang-tools-${VERSION}_${DETAILED_VERSION}_amd64.deb clangd-${VERSION}_${DETAILED_VERSION}_amd64.deb libclang-cpp${VERSION}_${DETAILED_VERSION}_amd64.deb clang-tidy-${VERSION}_${DETAILED_VERSION}_amd64.deb libclang-cpp${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libclc-${VERSION}_${DETAILED_VERSION}_all.deb libclc-${VERSION}-dev_${DETAILED_VERSION}_all.deb llvm-${VERSION}-linker-tools_${DETAILED_VERSION}_amd64.deb libunwind-${VERSION}_${DETAILED_VERSION}_amd64.deb libunwind-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libmlir-${VERSION}_${DETAILED_VERSION}_amd64.deb libmlir-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libclang-rt-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb libclang-rt-${VERSION}-dev-wasm32_${DETAILED_VERSION}_all.deb libclang-rt-${VERSION}-dev-wasm64_${DETAILED_VERSION}_all.deb libc++abi-${VERSION}-dev-wasm32_${DETAILED_VERSION}_all.deb libc++-${VERSION}-dev-wasm32_${DETAILED_VERSION}_all.deb libpolly-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb bolt-${VERSION}_${DETAILED_VERSION}_amd64.deb libbolt-${VERSION}-dev_${DETAILED_VERSION}_amd64.deb" + echo "To install everything:" echo "sudo apt --purge remove 'libomp5-*' 'libc++*dev' 'libc++*' 'python3-lldb-*' 'libunwind-*' 'libclc-*' 'libclc-*dev' 'libmlir-*'" echo "sudo dpkg -i $LIST" @@ -1211,11 +1212,11 @@ clang++-$VERSION foo.cpp -unwindlib=libunwind -rtlib=compiler-rt -I/usr/include/ ./a.out||true if test ! -f /usr/lib/llvm-$VERSION/include/polly/LinkAllPasses.h; then - echo "Install libclang-common-$VERSION-dev for polly"; + echo "Install libpolly-$VERSION-dev for polly"; exit -1; fi -echo "Testing polly (libclang-common-$VERSION-dev) ..." +echo "Testing polly (libpolly-$VERSION-dev) ..." # Polly echo " @@ -1361,22 +1362,36 @@ fi if dpkg -l|grep -q wasi-libc; then cat < printf.c #include - int main(int argc, char *argv[]) - { - printf("%s\n", "Hello world!"); + int main(int argc, char *argv[]) { + printf("%s\n", "Hello World!"); } EOF - clang-$VERSION -target wasm32-unknown-wasi -o printf printf.c + # wasi-libc supports only wasm32 right now + clang-$VERSION -target wasm32-wasi -o printf printf.c file printf &> foo.log if ! grep -q "WebAssembly" foo.log; then echo "the generated file isn't a WebAssembly file?" exit 1 fi rm -f printf.c printf + + cat < cout.cpp + #include + int main() { + std::cout << "Hello World!" << std::endl; + } +EOF + # libcxx requires wasi-libc, which only exists for wasm32 right now + clang++-$VERSION --target=wasm32-wasi -o cout cout.cpp + file cout &> foo.log + if ! grep -q "WebAssembly" foo.log; then + echo "the generated file isn't a WebAssembly file?" + exit 1 + fi + rm -f cout.cpp cout +else + echo "wasi-libc not installed" fi -echo '#include ' > foo.cpp -# Fails for now -clang++-$VERSION --target=wasm32-wasi -o foo.o -c foo.cpp||true echo ' #include diff --git a/debian/rules b/debian/rules index edea5da9..aecb768c 100755 --- a/debian/rules +++ b/debian/rules @@ -20,6 +20,13 @@ ifeq ($(LLVM_VERSION),$(LLVM_VERSION_FULL)) LLVM_VERSION_FULL := $(LLVM_VERSION).0.0 endif +SOURCE_NAME := $(shell dpkg-parsechangelog -S Source) +ifneq (,$(findstring snapshot,$(SOURCE_NAME))) + BRANCH_NAME=snapshot +else + BRANCH_NAME=$(LLVM_VERSION) +endif + SONAME_EXT := 1 SONAME_OPENMP := 5 # Manage the case when the version is 3.5~svn213052-1~exp1 or 3.4.2-1 @@ -322,12 +329,6 @@ ifeq ($(LIBUNWIND_ENABLE),yes) endif endif -COMPILER_RT_WASM_ENABLE=yes - -ifneq (,$(filter $(DEB_HOST_ARCH), arm64 armel mips64el mipsel ppc64el armhf riscv64)) - COMPILER_RT_WASM_ENABLE=no -endif - # Do not install objects STAGE_ALL_CMAKE_EXTRA += -DMLIR_INSTALL_AGGREGATE_OBJECTS=OFF @@ -498,6 +499,7 @@ preconfigure: f2=$$(echo $$f | sed 's/\.in$$//;s/X\.Y/$(LLVM_VERSION)/'); \ echo "$$f => $$f2"; \ sed -e 's|@DEB_HOST_MULTIARCH@|$(DEB_HOST_MULTIARCH)|g' \ + -e "s|@BRANCH_NAME@|$(BRANCH_NAME)|g" \ -e "s|@OCAML_STDLIB_DIR@|$(OCAML_STDLIB_DIR)|g" \ -e "s|@LLVM_VERSION_FULL@|$(LLVM_VERSION_FULL)|g" \ -e "s|@LLVM_VERSION@|$(LLVM_VERSION)|g" $$f > $$f2; \ @@ -507,7 +509,7 @@ preconfigure: chmod +x \ debian/clang-tools-$(LLVM_VERSION).install \ debian/libclang-$(LLVM_VERSION)-dev.install \ - debian/libclang-common-$(LLVM_VERSION)-dev.install \ + debian/libpolly-$(LLVM_VERSION)-dev.install \ debian/libomp-$(LLVM_VERSION)-dev.install \ debian/llvm-$(LLVM_VERSION)-dev.install \ debian/llvm-$(LLVM_VERSION)-linker-tools.install \ @@ -743,17 +745,17 @@ ifndef LLVM_SPIRV endif touch $@ -debian-rtlib-wasm-build: -ifeq (${COMPILER_RT_WASM_ENABLE},yes) - echo "Using cmake: $(CMAKE_BIN)" - for build in wasm32 wasm64; do \ - mkdir -p build-compiler-rt-$$build; \ - $(CMAKE_BIN) -B build-compiler-rt-$$build -S compiler-rt/lib/builtins/ \ +build-wasm/compiler-rt-%: cpu = $(@:build-wasm/compiler-rt-%=%) +build-wasm/compiler-rt-%: + @echo "Building compiler-rt for $(cpu)" + @echo "Using cmake: $(CMAKE_BIN)" + mkdir -p "$@" + $(CMAKE_BIN) -B "$@" -S compiler-rt/lib/builtins/ \ -G Ninja \ $(SCCACHE_CMAKE) \ - -DCMAKE_C_COMPILER_TARGET=$$build-unknown-unknown \ - -DCMAKE_CXX_COMPILER_TARGET=$$build-unknown-unknown \ - -DCMAKE_ASM_COMPILER_TARGET=$$build-unknown-unknown \ + -DCMAKE_C_COMPILER_TARGET=$(cpu)-unknown-unknown \ + -DCMAKE_CXX_COMPILER_TARGET=$(cpu)-unknown-unknown \ + -DCMAKE_ASM_COMPILER_TARGET=$(cpu)-unknown-unknown \ -DCMAKE_C_COMPILER=$(STAGE_2_BIN_DIR)/clang \ -DCMAKE_CXX_COMPILER=$(STAGE_2_BIN_DIR)/clang++ \ -DCMAKE_C_FLAGS="$(opt_flags) $(STAGE_2_CFLAGS)" \ @@ -770,15 +772,95 @@ ifeq (${COMPILER_RT_WASM_ENABLE},yes) -DCOMPILER_RT_INCLUDE_TESTS=OFF \ -DCOMPILER_RT_USE_LIBCXX=OFF \ -DCOMPILER_RT_USE_BUILTINS_LIBRARY=ON \ - -DCOMPILER_RT_DEFAULT_TARGET_TRIPLE=$$build-unknown-unknown \ - -DCOMPILER_RT_OS_DIR=wasi || exit 1; \ - ninja -C build-compiler-rt-$$build -j $(NJOBS) $(VERBOSE) || exit 1; \ - done -else - echo "Skip on this arch" -endif - touch $@ + -DCOMPILER_RT_DEFAULT_TARGET_TRIPLE=$(cpu)-unknown-unknown \ + -DCOMPILER_RT_OS_DIR=wasi + ninja -C "$@" $(NJOBS) $(VERBOSE) +build-wasm/libcxx-%-wasi: cpu = $(@:build-wasm/libcxx-%-wasi=%) +build-wasm/libcxx-%-wasi: build-wasm/compiler-rt-% + @echo "Building libcxx for $(cpu)" + @echo "Using cmake: $(CMAKE_BIN)" + + # We need a functioning clang, which in turn requires a linker. We + # patch clang to use a versioned wasm-ld (cf. wasm-ld-path.diff), so + # create wasm-ld-$(LLVM_VERSION) in the stage2 bin dir manually. + cp $(STAGE_2_BIN_DIR)/wasm-ld $(STAGE_2_BIN_DIR)/wasm-ld-$(LLVM_VERSION) + + # We need a wasm compiler-rt. Depend on the make target that builds it, + # and manually copy it to the stage2 lib dir from there + mkdir -p \ + $(STAGE_2_LIB_DIR)/clang/$(LLVM_VERSION_FULL)/lib/wasi/ + cp build-wasm/compiler-rt-$(cpu)/lib/wasi/libclang_rt.builtins-$(cpu).a \ + $(STAGE_2_LIB_DIR)/clang/$(LLVM_VERSION_FULL)/lib/wasi/ + + # Notes: + # - Uses $(LDFLAGS) instead of $(STAGE_2_LDFLAGS), because wasm-ld does not + # support --build-id yet. Upstream is working on it, cf. D107662. + # - Pass -fno-stack-protector to disable -fstack-protector-strong that is + # passed by default, as this is not supported yet in WebAssembly, cf. + # https://github.com/WebAssembly/wasi-libc/issues/157 + # - Use llvm-ar and llvm-ranlib, as binutils does not currently support + # WebAssembly and creates invalid indexes. + # - Use LLVM_LIBDIR_SUFFIX to install to /usr/lib/wasm32-wasi. To be + # replaced by CMAKE_INSTALL_LIBDIR=lib/$(cpu)-wasi when D130586 + # ships. + mkdir -p "$@" + $(CMAKE_BIN) -B "$@" -S runtimes \ + -G $(GENERATOR) \ + $(SCCACHE_CMAKE) \ + -DCMAKE_C_COMPILER_WORKS=ON \ + -DCMAKE_CXX_COMPILER_WORKS=ON \ + -DLLVM_COMPILER_CHECKED=ON \ + -DCMAKE_C_COMPILER_TARGET=$(cpu)-unknown-wasi \ + -DCMAKE_CXX_COMPILER_TARGET=$(cpu)-unknown-wasi \ + -DCMAKE_ASM_COMPILER_TARGET=$(cpu)-unknown-wasi \ + -DCMAKE_C_COMPILER=$(STAGE_2_BIN_DIR)/clang \ + -DCMAKE_CXX_COMPILER=$(STAGE_2_BIN_DIR)/clang++ \ + -DCMAKE_AR=$(STAGE_2_BIN_DIR)/llvm-ar \ + -DCMAKE_RANLIB=$(STAGE_2_BIN_DIR)/llvm-ranlib \ + -DCMAKE_C_FLAGS="$(opt_flags) $(STAGE_2_CFLAGS) -fno-stack-protector" \ + -DCMAKE_CXX_FLAGS="$(opt_flags) $(STAGE_2_CXXFLAGS) -fno-stack-protector" \ + -DCMAKE_SHARED_LINKER_FLAGS="$(LDFLAGS) -L$(STAGE_2_LIB_DIR)" \ + -DCMAKE_MODULE_LINKER_FLAGS="$(LDFLAGS) -L$(STAGE_2_LIB_DIR)" \ + -DCMAKE_EXE_LINKER_FLAGS="$(LDFLAGS) -L$(STAGE_2_LIB_DIR)" \ + -DCMAKE_INSTALL_PREFIX=/usr/lib/llvm-$(LLVM_VERSION) \ + -DCMAKE_INSTALL_INCLUDEDIR=include/$(cpu)-wasi \ + -DLLVM_LIBDIR_SUFFIX=/$(cpu)-wasi \ + -DLLVM_CONFIG=$(STAGE_2_BIN_DIR)/llvm-config \ + -DLLVM_ENABLE_RUNTIMES="libcxx;libcxxabi" \ + -DLIBCXX_USE_COMPILER_RT=ON \ + -DLIBCXXABI_USE_COMPILER_RT=ON \ + -DLIBCXX_ENABLE_STATIC_ABI_LIBRARY=ON \ + -DLIBCXX_STATICALLY_LINK_ABI_IN_STATIC_LIBRARY=ON \ + -DLIBCXX_STATICALLY_LINK_ABI_IN_SHARED_LIBRARY=OFF \ + -DCMAKE_BUILD_TYPE=RelWithDebugInfo \ + -DLIBCXX_CXX_ABI=libcxxabi \ + -DLIBCXX_ABI_VERSION=2 \ + -DLIBCXX_HAS_MUSL_LIBC:BOOL=ON \ + -DLIBCXX_ENABLE_SHARED:BOOL=OFF \ + -DLIBCXX_ENABLE_EXPERIMENTAL_LIBRARY:BOOL=OFF \ + -DLIBCXX_ENABLE_EXCEPTIONS:BOOL=OFF \ + -DLIBCXX_ENABLE_FILESYSTEM:BOOL=OFF \ + -DLIBCXX_ENABLE_THREADS:BOOL=OFF \ + -DLIBCXX_HAS_PTHREAD_API:BOOL=OFF \ + -DLIBCXX_HAS_EXTERNAL_THREAD_API:BOOL=OFF \ + -DLIBCXX_BUILD_EXTERNAL_THREAD_LIBRARY:BOOL=OFF \ + -DLIBCXXABI_ENABLE_SHARED:BOOL=OFF \ + -DLIBCXXABI_ENABLE_EXCEPTIONS:BOOL=OFF \ + -DLIBCXXABI_SILENT_TERMINATE:BOOL=ON \ + -DLIBCXXABI_ENABLE_THREADS:BOOL=OFF \ + -DLIBCXXABI_HAS_PTHREAD_API:BOOL=OFF \ + -DLIBCXXABI_HAS_EXTERNAL_THREAD_API:BOOL=OFF \ + -DLIBCXXABI_BUILD_EXTERNAL_THREAD_LIBRARY:BOOL=OFF + ninja -C "$@" $(NJOBS) $(VERBOSE) + +# Build compiler-rt for wasm32 and wasm64. Build libcxx only for wasm32, as +# libcxx requires wasi-libc, which only exists for wasm32 right now. +debian-wasm-build: \ + build-wasm/compiler-rt-wasm32 \ + build-wasm/libcxx-wasm32-wasi \ + build-wasm/compiler-rt-wasm64 + touch $@ sccache-stats: # If we used sccache, shows stats @@ -790,7 +872,12 @@ sccache-stats: fi touch $@ -override_dh_auto_build: debian-full-build debian-libfuzzer-build debian-libclc-build debian-rtlib-wasm-build sccache-stats +override_dh_auto_build: \ + debian-full-build \ + debian-libfuzzer-build \ + debian-libclc-build \ + debian-wasm-build \ + sccache-stats override_dh_prep: build_doc dh_prep @@ -851,6 +938,7 @@ endif cd openmp/runtime && doxygen doc/doxygen/config; cd -; \ cd openmp/runtime/doc/doxygen/generated/html/ && rm jquery.js && ln -s /usr/share/javascript/jquery/jquery.js; \ fi + touch $@ override_dh_auto_install: # Clean up temporary files to make sure the install works @@ -873,6 +961,8 @@ override_dh_auto_install: # Only run on executable, not script chrpath -d `find $(DEB_INST)/usr/lib/llvm-$(LLVM_VERSION)/bin/ -type f -executable -exec file -i '{}' \; | grep 'x-executable; charset=binary'|cut -d: -f1` + # To fix custom-library-search-path + chrpath -d $(DEB_INST)/usr/lib/llvm-$(LLVM_VERSION)/lib/clang/$(LLVM_VERSION)*/lib/linux/*.so : # libclang cd debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/ && \ @@ -936,10 +1026,9 @@ endif DESTDIR=$(DEB_INST) ninja $(VERBOSE) -C libclc/build install -ifeq (${COMPILER_RT_WASM_ENABLE},yes) - DESTDIR=$(DEB_INST) ninja $(VERBOSE) -C build-compiler-rt-wasm32 install - DESTDIR=$(DEB_INST) ninja $(VERBOSE) -C build-compiler-rt-wasm64 install -endif + DESTDIR=$(DEB_INST) ninja $(VERBOSE) -C build-wasm/compiler-rt-wasm32 install + DESTDIR=$(DEB_INST) ninja $(VERBOSE) -C build-wasm/compiler-rt-wasm64 install + DESTDIR=$(DEB_INST) ninja $(VERBOSE) -C build-wasm/libcxx-wasm32-wasi install # Rename binaries mkdir -p $(DEB_INST)/usr/bin/ @@ -1002,12 +1091,12 @@ endif # Manage the polly files. Sometimes, we build them. Sometimes not. if test "$(POLLY_ENABLE)" = yes; then \ - mkdir -p $(CURDIR)/debian/libclang-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/lib/ $(CURDIR)/debian/libclang-common-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/include/polly/; \ + mkdir -p $(CURDIR)/debian/libclang-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/lib/ $(CURDIR)/debian/libpolly-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/include/polly/; \ mv -f $(DEB_INST)/usr/lib/llvm-$(LLVM_VERSION)/lib/libPolly* \ - $(CURDIR)/debian/libclang-common-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/lib/; \ - rm -rf $(CURDIR)/debian/libclang-common-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/include/polly; \ + $(CURDIR)/debian/libpolly-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/lib/; \ + rm -rf $(CURDIR)/debian/libpolly-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/include/polly; \ mv -f $(DEB_INST)/usr/lib/llvm-$(LLVM_VERSION)/include/polly/ \ - $(CURDIR)/debian/libclang-common-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/include/; \ + $(CURDIR)/debian/libpolly-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/include/; \ fi mkdir -p $(CURDIR)/debian/usr/share/doc/llvm-$(LLVM_VERSION)-doc/ $(CURDIR)/debian/usr/share/doc/clang-$(LLVM_VERSION)-doc/ @@ -1038,6 +1127,7 @@ endif # Delete the target build directory to save some space on the build systems # All the files have been installed in $(CURDIR)/debian/tmp/ already rm -rf $(TARGET_BUILD) + touch $@ override_dh_makeshlibs: @@ -1093,14 +1183,14 @@ ifeq ($(shell dpkg --compare-versions $(shell dpkg-query -W -f '$${Version}' bin else # GNU strip doesn't recognize WebAssembly binaries, and actually corrupts them. # llvm-strip (as of 15.0.2) fails with --strip-debug (but works with --strip-all) - dh_strip -a -v -Xlibclang_rt.builtins-wasm32.a -Xlibclang_rt.builtins-wasm64.a + dh_strip -a -v -Xlibclang_rt.builtins-wasm32.a -Xlibclang_rt.builtins-wasm64.a -Xusr/lib/wasm32-wasi endif override_dh_install: ifeq (${POLLY_ENABLE},yes) # only for arch:any builds -ifneq (,$(filter libclang-common-$(LLVM_VERSION)-dev, $(shell dh_listpackages))) - dh_install -p libclang-common-$(LLVM_VERSION)-dev usr/lib/llvm-$(LLVM_VERSION)/lib/cmake/polly/*.cmake usr/lib/llvm-$(LLVM_VERSION)/lib/cmake/polly +ifneq (,$(filter libpolly-$(LLVM_VERSION)-dev, $(shell dh_listpackages))) + dh_install -p libpolly-$(LLVM_VERSION)-dev usr/lib/llvm-$(LLVM_VERSION)/lib/cmake/polly/*.cmake usr/lib/llvm-$(LLVM_VERSION)/lib/cmake/polly # On old Debian & Ubuntu, removing the files is necessary rm -rf debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/cmake/polly/*.cmake else @@ -1108,6 +1198,16 @@ else endif endif dh_install --fail-missing +# Move the libc+ abi files from libc++ to libc++-abi for the wasm32 packages +# These packages are arch: all, so only do so when the packages are built +ifneq (,$(filter libc++-$(LLVM_VERSION)-dev-wasm32, $(shell dh_listpackages))) + mkdir -p $(CURDIR)/debian/libc++abi-$(LLVM_VERSION)-dev-wasm32/usr/lib/llvm-$(LLVM_VERSION)/include/wasm32-wasi/c++/v1 + mv $(CURDIR)/debian/libc++-$(LLVM_VERSION)-dev-wasm32/usr/lib/llvm-$(LLVM_VERSION)/include/wasm32-wasi/c++/v1/__cxxabi_config.h \ + $(CURDIR)/debian/libc++abi-$(LLVM_VERSION)-dev-wasm32/usr/lib/llvm-$(LLVM_VERSION)/include/wasm32-wasi/c++/v1/__cxxabi_config.h + mv $(CURDIR)/debian/libc++-$(LLVM_VERSION)-dev-wasm32/usr/lib/llvm-$(LLVM_VERSION)/include/wasm32-wasi/c++/v1/cxxabi.h \ + $(CURDIR)/debian/libc++abi-$(LLVM_VERSION)-dev-wasm32/usr/lib/llvm-$(LLVM_VERSION)/include/wasm32-wasi/c++/v1/cxxabi.h +endif + repack_a_llvm_ir: @@ -1132,6 +1232,7 @@ override_dh_installdeb: repack_a_llvm_ir # Remove some libc++ abi files in the libc++ file. See bug #969274 rm -f $(CURDIR)/debian/libc++-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/include/c++/__cxxabi_config.h $(CURDIR)/debian/libc++-$(LLVM_VERSION)-dev/usr/lib/llvm-$(LLVM_VERSION)/include/c++/cxxabi.h + # Remove auto generated python pyc find $(CURDIR)/debian/llvm-$(LLVM_VERSION)-tools/usr/lib/llvm-$(LLVM_VERSION)/ -name '*.pyc' | xargs -r rm -f @@ -1228,25 +1329,23 @@ override_dh_auto_clean: rm -rf $(TARGET_BUILD) llvm/docs/_build/ clang/docs/_build tools/clang/docs/_html/ # QA tools rm -rf cov-int/ reports/ - rm -f `ls debian/*.in|sed -e "s|.in$$||g"` + rm -f `ls debian/*.in|grep -v control.in|sed -e "s|.in$$||g"` find utils -name '*.pyc' | xargs -r rm -f # Use -I because a test has a space in its name find lldb/test -iname '*.pyc' | xargs -I{} -r rm -f {} - find test -name '*.pyc' -o -name '*.cm[ix]' | xargs -r rm -f - find test/Bindings -name '*.o' | xargs -r rm -f - rm -f tools/clang tools/polly tools/lld tools/lldb projects/compiler-rt - rm -rf tools/clang/tools/extra clang/tools/extra/ rm -f $(CURDIR)/utils/vim/llvm-$(LLVM_VERSION).vim $(CURDIR)/utils/vim/tablegen-$(LLVM_VERSION).vim rm -f $(CURDIR)/clang/tools/clang-format/clang-format-diff-$(LLVM_VERSION) rm -f $(CURDIR)/clang/tools/clang-format/clang-format-$(LLVM_VERSION).py rm -rf libclc/build - rm -rf build-compiler-rt-wasm32 build-compiler-rt-wasm64 + rm -rf build-wasm if test -f lld/docs/ld.lld-$(LLVM_VERSION).1; then \ mv lld/docs/ld.lld-$(LLVM_VERSION).1 lld/docs/ld.lld.1; \ fi for f in debian/*.in; do \ - f2=$$(echo $$f | sed 's/\.in$$//;s/X\.Y/$(LLVM_VERSION)/'); \ - rm -f $$f2; \ + if ! echo $$f|grep control; then \ + f2=$$(echo $$f | sed 's/\.in$$//;s/X\.Y/$(LLVM_VERSION)/'); \ + rm -f $$f2; \ + fi; \ done if test "$(SCAN_BUILD)" = "yes"; then \ patch -f -R -p1 < debian/patches/on-the-fly/use-scan-build-runtimes.diff||true; \ @@ -1254,6 +1353,6 @@ override_dh_auto_clean: : # for some reason, the docs are written to debian/usr and debian/man ... rm -rf debian/usr debian/man : # remove extra stamps - rm -f debian-*-build + rm -f debian-*-build override_dh_auto_install sccache-stats build_doc -.PHONY: override_dh_strip preconfigure debian-full-build debian-libfuzzer-build debian-libclc-build debian-rtlib-wasm-build +.PHONY: override_dh_strip preconfigure