Teknik is a suite of services with attractive and functional interfaces. https://www.teknik.io/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

build-xhprof.sh 1.0KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. #!/bin/bash
  2. if ! type phpize &> /dev/null; then
  3. echo "phpize missing, skipping build"
  4. echo "If you installed PHP via Aptitude, you can install phpize w/ 'sudo apt-get install php5-dev'"
  5. exit
  6. fi
  7. if ! type make &> /dev/null; then
  8. echo "make missing, skipping build"
  9. exit
  10. fi
  11. if ! [ -d "vendor/facebook/xhprof/extension" ]; then
  12. echo "xhprof missing, skipping build"
  13. exit
  14. fi
  15. mkdir -p tmp/xhprof-logs
  16. cd vendor/facebook/xhprof/extension
  17. echo "Building xhprof..."
  18. if ! phpize &> ../../../../tmp/xhprof-logs/phpize.log; then
  19. echo "Fatal error: phpize failed! View tmp/xhprof-logs/phpize.log for more info."
  20. exit 1
  21. fi
  22. if ! ./configure &> ../../../../tmp/xhprof-logs/configure.log; then
  23. echo "Fatal error: configure script failed! View tmp/xhprof-logs/configure.log for more info."
  24. exit 2
  25. fi
  26. if ! make &> ../../../../tmp/xhprof-logs/make.log; then
  27. echo "Fatal error: could not build extension (make failed)! View tmp/xhprof-logs/make.log for more info."
  28. exit 3
  29. fi
  30. echo "Done."