get_libuv.sh 1.4 KB

12345678910111213141516171819202122232425262728293031323334
  1. #!/usr/bin/env bash
  2. # You may redistribute this program and/or modify it under the terms of
  3. # the GNU General Public License as published by the Free Software Foundation,
  4. # either version 3 of the License, or (at your option) any later version.
  5. #
  6. # This program is distributed in the hope that it will be useful,
  7. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  8. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  9. # GNU General Public License for more details.
  10. #
  11. # You should have received a copy of the GNU General Public License
  12. # along with this program. If not, see <http://www.gnu.org/licenses/>.
  13. # script meant to be run manually, for getting a deterministic copy of libuv for cjdns.
  14. # After running:
  15. # cd libuv
  16. # $ find ./ -type f -exec sha256sum {} \; | sort | sha256sum
  17. # 5cbd29365b03eb0655822f008115cf92bc1b9c19007ecff637585ba7eb91dafd -
  18. die() {
  19. echo "ERROR: $1";
  20. exit 100;
  21. }
  22. git clone http://github.com/joyent/libuv.git || die 'clone libuv'
  23. cd libuv || die 'cd libuv'
  24. git checkout 336a1825309744f920230ec3e427e78571772347 || die 'checkout revision of libuv'
  25. rm -rf ./.git || die 'rm -rf ./.git'
  26. mkdir -p build || die 'mkdir -p build'
  27. svn co https://gyp.googlecode.com/svn/trunk build/gyp || die 'failed checkout gyp'
  28. cd build/gyp || die 'failed cd build/gyp'
  29. svn up 1857 || die 'failed to checkout revision 1857'
  30. rm -rf ./.svn || die 'failed to remove .svn'