mirror of
https://git.proxmox.com/git/llvm-toolchain
synced 2025-06-14 17:54:50 +00:00
Update the debian/orig-tar.sh repack script to checkout specific branches
This commit is contained in:
parent
30808de913
commit
13ceab6281
24
debian/changelog
vendored
24
debian/changelog
vendored
@ -1,3 +1,27 @@
|
||||
llvm-toolchain (1:3.3~svn177020-1~exp1) experimental; urgency=low
|
||||
|
||||
* New snapshot release
|
||||
|
||||
-- Sylvestre Ledru <sylvestre@debian.org> Thu, 14 Mar 2013 12:30:14 +0100
|
||||
|
||||
llvm-toolchain (1:3.3~svn177016-1~exp1) experimental; urgency=low
|
||||
|
||||
* New snapshot release
|
||||
|
||||
-- Sylvestre Ledru <sylvestre@debian.org> Thu, 14 Mar 2013 10:04:00 +0100
|
||||
|
||||
llvm-toolchain (1:3.3~svn177016-1~exp1) experimental; urgency=low
|
||||
|
||||
* New snapshot release
|
||||
|
||||
-- Sylvestre Ledru <sylvestre@debian.org> Thu, 14 Mar 2013 10:00:47 +0100
|
||||
|
||||
llvm-toolchain (1:3.3~svn176628-1~exp1) experimental; urgency=low
|
||||
|
||||
* New snapshot release
|
||||
|
||||
-- Sylvestre Ledru <sylvestre@debian.org> Thu, 07 Mar 2013 14:07:36 +0100
|
||||
|
||||
llvm-toolchain (1:3.3~svn176476-1~exp1) experimental; urgency=low
|
||||
|
||||
* Draft of a snapshot release (3.3)
|
||||
|
2
debian/libclang1.install
vendored
2
debian/libclang1.install
vendored
@ -1 +1 @@
|
||||
usr/lib/llvm-3.3/lib/libclang.so.1
|
||||
usr/lib/llvm-3.3/lib/libclang.so.3.3
|
||||
|
42
debian/orig-tar.sh
vendored
42
debian/orig-tar.sh
vendored
@ -6,38 +6,64 @@
|
||||
# llvm-toolchain-3.2_3.2repack.orig-polly.tar.bz2
|
||||
# llvm-toolchain-3.2_3.2repack.orig.tar.bz2
|
||||
|
||||
SVN_URL=http://llvm.org/svn/llvm-project/
|
||||
REVISION=$(LANG=C svn info $SVN_URL|grep "^Revision:"|awk '{print $2}')
|
||||
SVN_CMD="svn export -r $REVISION $SVN_URL"
|
||||
SVN_BASE_URL=http://llvm.org/svn/llvm-project/
|
||||
|
||||
if test -n "$1"; then
|
||||
# http://llvm.org/svn/llvm-project/{cfe,llvm,compiler-rt,...}/branches/google/stable/
|
||||
BRANCH=$1
|
||||
fi
|
||||
|
||||
get_svn_url() {
|
||||
MODULE=$1
|
||||
BRANCH=$2
|
||||
if test -n "$BRANCH"; then
|
||||
SVN_URL="$SVN_BASE_URL/$MODULE/branches/$BRANCH"
|
||||
else
|
||||
SVN_URL="$SVN_BASE_URL/$MODULE/trunk/"
|
||||
fi
|
||||
echo $SVN_URL
|
||||
}
|
||||
|
||||
if test -n "$BRANCH"; then
|
||||
REVISION=$(LANG=C svn info $(get_svn_url llvm $BRANCH)|grep "^Last Changed Rev:"|awk '{print $4}')
|
||||
# Do not use the revision when exporting branch. We consider that all the
|
||||
# branch are sync
|
||||
SVN_CMD="svn export"
|
||||
else
|
||||
REVISION=$(LANG=C svn info $(get_svn_url llvm)|grep "^Revision:"|awk '{print $2}')
|
||||
SVN_CMD="svn export -r $REVISION"
|
||||
fi
|
||||
|
||||
MAJOR_VERSION=3.3
|
||||
|
||||
# LLVM
|
||||
LLVM_TARGET=llvm-toolchain_$MAJOR_VERSION~svn$REVISION
|
||||
$SVN_CMD/llvm/trunk $LLVM_TARGET
|
||||
$SVN_CMD $(get_svn_url llvm $BRANCH) $LLVM_TARGET
|
||||
tar jcvf llvm-toolchain_$MAJOR_VERSION~svn$REVISION.orig.tar.bz2 $LLVM_TARGET
|
||||
rm -rf $LLVM_TARGET
|
||||
|
||||
|
||||
# Clang
|
||||
CLANG_TARGET=clang_$MAJOR_VERSION~svn$REVISION
|
||||
$SVN_CMD/cfe/trunk $CLANG_TARGET
|
||||
$SVN_CMD $(get_svn_url cfe $BRANCH) $CLANG_TARGET
|
||||
tar jcvf llvm-toolchain_$MAJOR_VERSION~svn$REVISION.orig-clang.tar.bz2 $CLANG_TARGET
|
||||
rm -rf $CLANG_TARGET
|
||||
|
||||
# Compiler-rt
|
||||
COMPILER_RT_TARGET=compiler-rt_$MAJOR_VERSION~svn$REVISION
|
||||
$SVN_CMD/compiler-rt/trunk $COMPILER_RT_TARGET
|
||||
$SVN_CMD $(get_svn_url compiler-rt $BRANCH) $COMPILER_RT_TARGET
|
||||
tar jcvf llvm-toolchain_$MAJOR_VERSION~svn$REVISION.orig-compiler-rt.tar.bz2 $COMPILER_RT_TARGET
|
||||
rm -rf $COMPILER_RT_TARGET
|
||||
|
||||
# Polly
|
||||
POLLY_TARGET=polly_$MAJOR_VERSION~svn$REVISION
|
||||
$SVN_CMD/polly/trunk $POLLY_TARGET
|
||||
$SVN_CMD $(get_svn_url polly $BRANCH) $POLLY_TARGET
|
||||
tar jcvf llvm-toolchain_$MAJOR_VERSION~svn$REVISION.orig-polly.tar.bz2 $POLLY_TARGET
|
||||
rm -rf $POLLY_TARGET
|
||||
|
||||
# LLDB
|
||||
LLDB_TARGET=lldb_$MAJOR_VERSION~svn$REVISION
|
||||
$SVN_CMD/lldb/trunk $LLDB_TARGET
|
||||
$SVN_CMD $(get_svn_url lldb $BRANCH) $LLDB_TARGET
|
||||
tar jcvf llvm-toolchain_$MAJOR_VERSION~svn$REVISION.orig-lldb.tar.bz2 $LLDB_TARGET
|
||||
rm -rf $LLDB_TARGET
|
||||
|
||||
|
62
debian/rules
vendored
62
debian/rules
vendored
@ -57,8 +57,7 @@ endif
|
||||
|
||||
|
||||
%:
|
||||
dh $@
|
||||
# --buildsystem=cmake --builddirectory=$(TARGET_BUILD)
|
||||
dh $@ --buildsystem=cmake --builddirectory=$(TARGET_BUILD)
|
||||
|
||||
debian/%: debian/%.in
|
||||
sed -e 's|@DEB_HOST_MULTIARCH@|$(DEB_HOST_MULTIARCH)|g' -e "s|@OCAML_STDLIB_DIR@|$(OCAML_STDLIB_DIR)|g" -e "s|@LLVM_VERSION@|$(LLVM_VERSION)|g" $< > $@
|
||||
@ -96,24 +95,25 @@ override_dh_auto_configure: debian/lldb-$(LLVM_VERSION).install debian/lldb-$(LL
|
||||
readlink compiler-rt
|
||||
|
||||
# Start the actual configure
|
||||
cd $(TARGET_BUILD) && \
|
||||
../configure $(confargs) \
|
||||
--prefix=/usr/lib/llvm-$(LLVM_VERSION) \
|
||||
--bindir=\$${prefix}/bin/ \
|
||||
--disable-assertions \
|
||||
--enable-shared \
|
||||
--enable-optimized \
|
||||
--with-optimize-option=' $(opt_flags)' \
|
||||
--enable-pic \
|
||||
--enable-libffi \
|
||||
--with-ocaml-libdir=/usr/lib/ocaml/llvm-$(LLVM_VERSION) \
|
||||
--libdir=\$${prefix}/lib/$(DEB_HOST_MULTIARCH) \
|
||||
--with-binutils-include=/usr/include \
|
||||
--with-cloog --with-isl \
|
||||
--with-bug-report-url=http://bugs.debian.org/ \
|
||||
--enable-shared --enable-experimental-targets=R600 \
|
||||
CLANG_VENDOR=Debian || { cat config.log tools/polly/config.log; exit 1; }
|
||||
# cd $(TARGET_BUILD) && cmake ../ -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_VERBOSE_MAKEFILE=ON
|
||||
# cd $(TARGET_BUILD) && \
|
||||
# ../configure $(confargs) \
|
||||
# --prefix=/usr/lib/llvm-$(LLVM_VERSION) \
|
||||
# --bindir=\$${prefix}/bin/ \
|
||||
# --disable-assertions \
|
||||
# --enable-shared \
|
||||
# --enable-optimized \
|
||||
# --with-optimize-option=' $(opt_flags)' \
|
||||
# --enable-pic \
|
||||
# --enable-libffi \
|
||||
# --with-ocaml-libdir=/usr/lib/ocaml/llvm-$(LLVM_VERSION) \
|
||||
# --libdir=\$${prefix}/lib/$(DEB_HOST_MULTIARCH) \
|
||||
# --with-binutils-include=/usr/include \
|
||||
# --with-cloog --with-isl \
|
||||
# --with-bug-report-url=http://bugs.debian.org/ \
|
||||
# --enable-shared --enable-experimental-targets=R600 \
|
||||
# CLANG_VENDOR=Debian || { cat config.log tools/polly/config.log; exit 1; }
|
||||
cd $(TARGET_BUILD) && cmake ../ -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_INSTALL_PREFIX=/usr/lib/llvm-$(LLVM_VERSION) -DCMAKE_BUILD_TYPE=Release -DLLVM_ENABLE_FFI=ON -DFFI_INCLUDE_DIR=/usr/include/x86_64-linux-gnu/
|
||||
#-DBUILD_SHARED_LIBS=ON
|
||||
# mkdir build-compiler-rt && cd build-compiler-rt && cmake ../compiler-rt
|
||||
|
||||
|
||||
@ -125,14 +125,15 @@ override_dh_auto_build:
|
||||
cd $(CURDIR)/tools/clang/docs && make -f Makefile.sphinx
|
||||
|
||||
override_dh_auto_install:
|
||||
chrpath -d `find $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/bin/ -type f -executable`
|
||||
chrpath -d $(TARGET_BUILD)/Release/bin/clang
|
||||
$(MAKE) -C $(TARGET_BUILD) VERBOSE=1 install DESTDIR=$(CURDIR)/debian/tmp/
|
||||
chrpath -d `find $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/bin/ -type f -executable`
|
||||
mv $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/libLLVM-$(LLVM_VERSION)*.so $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/libLLVM-$(LLVM_VERSION).so.$(SONAME_EXT)
|
||||
mv $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/liblldb.so $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/liblldb.so.$(SONAME_EXT)
|
||||
dh_auto_install
|
||||
# chrpath -d `find $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/bin/ -type f -executable`
|
||||
# chrpath -d $(TARGET_BUILD)/Release/bin/clang
|
||||
# $(MAKE) -C $(TARGET_BUILD) VERBOSE=1 install DESTDIR=$(CURDIR)/debian/tmp/
|
||||
# chrpath -d `find $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/bin/ -type f -executable`
|
||||
# mv $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/libLLVM-$(LLVM_VERSION)*.so $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/libLLVM-$(LLVM_VERSION).so.$(SONAME_EXT)
|
||||
# mv $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/liblldb.so $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/liblldb.so.$(SONAME_EXT)
|
||||
|
||||
cd debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/ && mv libclang.so libclang.so.$(SONAME_EXT) && ln -s libclang.so.$(SONAME_EXT) libclang.so
|
||||
# cd debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/ && mv libclang.so libclang.so.$(SONAME_EXT) && ln -s libclang.so.$(SONAME_EXT) libclang.so
|
||||
# cd $(TARGET_BUILD)/tools/clang/runtime/compiler-rt/ && rm -rf $$(find . -iname "SubDir.lib*" -o -iname .dir) && rm -rf $$(find -empty)
|
||||
|
||||
mkdir -p $(CURDIR)/debian/clang-$(LLVM_VERSION)/usr/bin/
|
||||
@ -150,6 +151,9 @@ override_dh_auto_install:
|
||||
echo "Link $$f to `basename $$f`-$(LLVM_VERSION)"; \
|
||||
done
|
||||
|
||||
# mkdir -p $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/
|
||||
# mv $(CURDIR)/debian/tmp/usr/lib/*.a $(CURDIR)/debian/tmp/usr/lib/*.so* $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/lib/
|
||||
|
||||
# Rename manpages
|
||||
d=$(CURDIR)/docs/_build/man/; \
|
||||
cd $$d; \
|
||||
@ -157,10 +161,10 @@ override_dh_auto_install:
|
||||
echo "$$f"|grep "3\.2" || mv $$f `echo $$f|sed "s|\.1|-$(LLVM_VERSION).1|"`; \
|
||||
done
|
||||
|
||||
mv $(CURDIR)/build-llvm/tools/clang/docs/tools/clang.1 $(CURDIR)/build-llvm/tools/clang/docs/tools/clang-$(LLVM_VERSION).1
|
||||
# mv $(CURDIR)/build-llvm/tools/clang/docs/tools/clang.1 $(CURDIR)/build-llvm/tools/clang/docs/tools/clang-$(LLVM_VERSION).1
|
||||
|
||||
# Remove some license files
|
||||
rm $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/include/llvm/Support/LICENSE.TXT
|
||||
# rm $(CURDIR)/debian/tmp/usr/lib/llvm-$(LLVM_VERSION)/include/llvm/Support/LICENSE.TXT
|
||||
|
||||
# Managed in lldb-X.Y.links.in
|
||||
rm -f $(CURDIR)/build-llvm/Release/lib/python*/site-packages/lldb/_lldb.so
|
||||
|
Loading…
Reference in New Issue
Block a user