Skip to content
Browse files

now depend on revision 127367 of branch LLVM 2.9

git-svn-id: http://svn.macosforge.org/repository/ruby/MacRuby/trunk@5272 23306eb0-4c56-4727-a40e-e92c0eb68959
  • Loading branch information...
1 parent d992548 commit 9be9a37dfbf72e187a180489db29a4310bdfa54d Laurent Sansonetti committed
Showing with 22 additions and 22 deletions.
  1. +12 −12 README.rdoc
  2. +1 −1 bridgesupport.cpp
  3. +3 −3 compiler.cpp
  4. +1 −1 compiler.h
  5. +1 −1 debugger.cpp
  6. +1 −1 llvm.h
  7. +3 −3 vm.cpp
View
24 README.rdoc
@@ -16,22 +16,22 @@ http://macruby.org
=== Requirements
-* An Intel machine. PowerPC machines are not supported anymore, but may still
- work. An Intel 64-bit machine (Intel Core Duo 2) is recommended.
+* An Intel 64-bit machine. PowerPC and Intel 32-bit machines are not supported
+ anymore, but may still work.
* Mac OS X 10.6 or later.
-* LLVM ToT, compiled for both i386 and x86_64.
+* LLVM ToT, compiled for x86_64.
LLVM is a moving target and breaks periodically. We recommend to install
- revision tag 2.8, being sure to specify the correct C and C++ compilers through
- environment variables.
+ revision 127367 of branch 2.9, being sure to specify the correct C and
+ C++ compilers through environment variables.
- $ svn co https://llvm.org/svn/llvm-project/llvm/tags/RELEASE_28 llvm-2.8
- $ cd llvm-2.8
- $ env UNIVERSAL=1 UNIVERSAL_ARCH="i386 x86_64" CC=/usr/bin/gcc CXX=/usr/bin/g++ ./configure --enable-bindings=none --enable-optimized --with-llvmgccdir=/tmp
- $ env UNIVERSAL=1 UNIVERSAL_ARCH="i386 x86_64" CC=/usr/bin/gcc CXX=/usr/bin/g++ make
- $ sudo env UNIVERSAL=1 UNIVERSAL_ARCH="i386 x86_64" CC=/usr/bin/gcc CXX=/usr/bin/g++ make install
+ $ svn co https://llvm.org/svn/llvm-project/llvm/branches/release_29@127367 llvm-2.9
+ $ cd llvm-2.9
+ $ env CC=/usr/bin/gcc CXX=/usr/bin/g++ ./configure --enable-bindings=none --enable-optimized --with-llvmgccdir=/tmp
+ $ env CC=/usr/bin/gcc CXX=/usr/bin/g++ make
+ $ sudo env CC=/usr/bin/gcc CXX=/usr/bin/g++ make install
Note that compiling LLVM can take quite a while. If you have a machine with
multiple cores, which is quite likely, you might want to speed up the process
@@ -40,14 +40,14 @@ http://macruby.org
option, where `N' stands for the number of cores you'd like to use. So for a
Core Duo the command would look like:
- $ env UNIVERSAL=1 UNIVERSAL_ARCH="i386 x86_64" CC=/usr/bin/gcc CXX=/usr/bin/g++ make -j2
+ $ env CC=/usr/bin/gcc CXX=/usr/bin/g++ make -j2
If you would prefer to update an existing LLVM Subversion working copy you
need to be careful to remove any previous build files before you compile:
$ svn status --no-ignore | awk '{print $2}' | xargs rm -rf
$ svn revert -R .
- $ svn switch https://llvm.org/svn/llvm-project/llvm/tags/RELEASE_28
+ $ svn switch <repository-URL>
=== Build Instructions
View
2 bridgesupport.cpp
@@ -18,7 +18,7 @@
# include <llvm/Instructions.h>
# include <llvm/Intrinsics.h>
# include <llvm/Analysis/DebugInfo.h>
-# if __SUPPORT_LLVM_29__
+# if !defined(LLVM_TOT)
# include <llvm/Analysis/DIBuilder.h>
# endif
# include <llvm/ExecutionEngine/JIT.h>
View
6 compiler.cpp
@@ -150,7 +150,7 @@ RoxorCompiler *RoxorCompiler::shared = NULL;
RoxorCompiler::RoxorCompiler(bool _debug_mode)
{
assert(RoxorCompiler::module != NULL);
-#if __SUPPORT_LLVM_29__
+#if !defined(LLVM_TOT)
debug_info = new DIBuilder(*RoxorCompiler::module);
#else
debug_info = new DIFactory(*RoxorCompiler::module);
@@ -839,7 +839,7 @@ void
RoxorCompiler::attach_current_line_metadata(Instruction *insn)
{
if (fname != NULL) {
-#if __SUPPORT_LLVM_29__
+#if !defined(LLVM_TOT)
Value *args[] = {
ConstantInt::get(Int32Ty, current_line),
ConstantInt::get(Int32Ty, 0),
@@ -4892,7 +4892,7 @@ RoxorCompiler::set_fname(const char *_fname)
assert(strlen(dir) > 0);
assert(strlen(base) > 0);
-#if __SUPPORT_LLVM_29__
+#if !defined(LLVM_TOT)
debug_info->createCompileUnit(DW_LANG_Ruby, base, dir,
RUBY_DESCRIPTION, true, "", 1);
debug_compile_unit = DICompileUnit(debug_info->getCU());
View
2 compiler.h
@@ -79,7 +79,7 @@ class RoxorCompiler {
void generate_location_path(std::string &path, DILocation loc);
protected:
-#if __SUPPORT_LLVM_29__
+#if !defined(LLVM_TOT)
DIBuilder *debug_info;
#else
DIFactory *debug_info;
View
2 debugger.cpp
@@ -15,7 +15,7 @@
#include <llvm/Instructions.h>
#include <llvm/Intrinsics.h>
#include <llvm/Analysis/DebugInfo.h>
-#if __SUPPORT_LLVM_29__
+#if !defined(LLVM_TOT)
# include <llvm/Analysis/DIBuilder.h>
#endif
#include <llvm/ExecutionEngine/JIT.h>
View
2 llvm.h
@@ -17,7 +17,7 @@
#include <llvm/Instructions.h>
#include <llvm/Intrinsics.h>
#include <llvm/Analysis/DebugInfo.h>
-#if __SUPPORT_LLVM_29__
+#if !defined(LLVM_TOT)
# include <llvm/Analysis/DIBuilder.h>
#endif
#include <llvm/ExecutionEngine/JIT.h>
View
6 vm.cpp
@@ -21,7 +21,7 @@
# include <llvm/Instructions.h>
# include <llvm/PassManager.h>
# include <llvm/Analysis/DebugInfo.h>
-# if __SUPPORT_LLVM_29__
+# if !defined(LLVM_TOT)
# include <llvm/Analysis/DIBuilder.h>
# endif
# include <llvm/Analysis/Verifier.h>
@@ -38,7 +38,7 @@
# include <llvm/Transforms/Scalar.h>
# include <llvm/Transforms/IPO.h>
# include <llvm/Support/raw_ostream.h>
-# if __SUPPORT_LLVM_29__
+# if !defined(LLVM_TOT)
# include <llvm/Support/system_error.h>
# endif
# include <llvm/Support/PrettyStackTrace.h>
@@ -4935,7 +4935,7 @@ Init_PreVM(void)
const char *kernel_file = getenv("VM_KERNEL_PATH");
if (kernel_file != NULL) {
std::string err;
-#if __SUPPORT_LLVM_29__
+#if !defined(LLVM_TOT)
OwningPtr<MemoryBuffer> MB;
error_code errcode = MemoryBuffer::getFile(kernel_file, MB);
if (errcode) {

0 comments on commit 9be9a37

Please sign in to comment.
Something went wrong with that request. Please try again.