README 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. See ../README.
  2. This is the runtime support library for the Go programming language.
  3. This library is intended for use with the Go frontend.
  4. This library should not be stripped when it is installed. Go code
  5. relies on being able to look up file/line information, which comes
  6. from the debugging info using the libbacktrace library.
  7. The library has only been tested on GNU/Linux using glibc, and on
  8. Solaris. It should not be difficult to port to other operating
  9. systems.
  10. Directories:
  11. go
  12. A copy of the Go library from http://golang.org/, with several
  13. changes for gccgo.
  14. runtime
  15. Runtime functions, written in C, which are called directly by the
  16. compiler or by the library.
  17. Contributing
  18. ============
  19. To contribute patches to the files in this directory, please see
  20. http://golang.org/doc/gccgo_contribute.html .
  21. The master copy of these files is hosted at
  22. http://code.google.com/p/gofrontend . Changes to these files require
  23. signing a Google contributor license agreement. If you are the
  24. copyright holder, you will need to agree to the individual contributor
  25. license agreement at
  26. http://code.google.com/legal/individual-cla-v1.0.html. This agreement
  27. can be completed online.
  28. If your organization is the copyright holder, the organization will
  29. need to agree to the corporate contributor license agreement at
  30. http://code.google.com/legal/corporate-cla-v1.0.html.
  31. If the copyright holder for your code has already completed the
  32. agreement in connection with another Google open source project, it
  33. does not need to be completed again.
  34. Debugging
  35. =========
  36. This describes how to test libgo when built as part of gccgo.
  37. To test a specific package, cd to the libgo build directory
  38. (TARGET/libgo) and run `make PKG/check`. For example, `make
  39. bytes/check`.
  40. To see the exact commands that it runs, including how the compiler is
  41. invoked, run `make GOTESTFLAGS=--trace bytes/check`. This will
  42. display the commands if the test fails. If the test passes, the
  43. commands and other output will be visible in a file named
  44. check-testlog in a subdirectory with the name of the package being
  45. checked. In the case of bytes/check, this will create
  46. bytes/check-testlog.
  47. To leave the test program behind, run `make GOTESTFLAGS=--keep
  48. bytes/check`. That will leave a gotestNNNN/test directory in the
  49. libgo build directory. In that directory you can run
  50. `LD_LIBRARY_PATH=../../.libs ./a.out -test.short` to run the tests.
  51. You can run specific failing tests using a -test.run option. You can
  52. see the tests being run with the -test.v option. You can run the
  53. program under a debugger such as gdb.