Makefile.solaris11 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. #
  2. # FreeSWITCH auto-build Makefile (Solaris 11.1 64bit Tonka Truck Edition)
  3. # http://www.freeswitch.org
  4. # put this file anywhere and type gmake to
  5. # create a fully-built freeswitch.git from scratch
  6. # in that same directory.
  7. #
  8. #
  9. FSPREFIX=/usr/local/freeswitch
  10. PREFIX=/usr/local/
  11. DOWNLOAD=http://files.freeswitch.org/downloads/libs
  12. JP=v8d
  13. SSL=1.0.1j
  14. SQLITE=autoconf-3080403
  15. PCRE=8.35
  16. CURL=7.35.0
  17. SPEEX=1.2rc1
  18. LIBEDIT=20140618-3.1
  19. LDNS=1.6.17
  20. PKGCFG=0.28
  21. PERL=5.18.2
  22. freeswitch: deps has-git freeswitch.git/Makefile
  23. cd freeswitch.git && gmake
  24. freeswitch.git/Makefile: freeswitch.git/configure
  25. export PATH=$PATH:$(PREFIX)/bin
  26. cd freeswitch.git && PKG_CONFIG_PATH=$(PREFIX)/lib/pkgconfig ./configure --enable-64 LDFLAGS='-L$(PREFIX)/lib -Wl,-rpath=$(PREFIX)/lib' CFLAGS='-I$(PREFIX)/include' --prefix=$(FSPREFIX)
  27. freeswitch.git/configure: freeswitch.git/bootstrap.sh
  28. cd freeswitch.git && sh bootstrap.sh
  29. freeswitch.git/bootstrap.sh: has-git
  30. test -d freeswitch.git || git clone https://github.com/signalwire/freeswitch.git freeswitch.git
  31. install: freeswitch
  32. cd freeswitch.git && gmake install cd-sounds-install cd-moh-install
  33. install-git:
  34. pkg install git autoconf automake libtool libjpeg gcc-45 wget
  35. has-git:
  36. @git --version || (echo "please install git by running 'gmake install-git'" && false)
  37. clean:
  38. @rm -rf openssl* ldns* jpeg* pcre* perl* pkg-config* speex* sqlite* libedit* curl* *~
  39. (cd freeswitch.git && git clean -fdx && git reset --hard HEAD && git pull)
  40. libjpeg: jpeg-8d/.done
  41. jpeg-8d/.done:
  42. (test -d jpeg-8d) || (wget -4 -O jpegsrc.$(JP).tar.gz $(DOWNLOAD)/jpegsrc.$(JP).tar.gz && tar zxfv jpegsrc.$(JP).tar.gz)
  43. (cd jpeg-8d && CFLAGS=-m64 LDFLAGS=-m64 ./configure --prefix=$(PREFIX) && gmake && sudo gmake install && touch .done)
  44. openssl: openssl-$(SSL)/.done
  45. openssl-$(SSL)/.done: openssl-$(SSL)
  46. openssl-$(SSL):
  47. (test -d $@) || (wget -4 -O $@.tar.gz $(DOWNLOAD)/$@.tar.gz && tar zxfv $@.tar.gz)
  48. (cd $@ && CFLAGS=-m64 LDFLAGS=-m64 ./Configure --prefix=$(PREFIX) solaris64-x86_64-gcc shared && gmake && sudo gmake install && touch .done)
  49. sqlite: sqlite-$(SQLITE)/.done
  50. sqlite-$(SQLITE)/.done: sqlite-$(SQLITE)
  51. sqlite-$(SQLITE):
  52. (test -d $@) || (wget -4 -O $@.tar.gz $(DOWNLOAD)/$@.tar.gz && tar zxfv $@.tar.gz)
  53. (cd $@ && CFLAGS=-m64 LDFLAGS=-m64 ./configure --prefix=$(PREFIX) && gmake && sudo gmake install && touch .done)
  54. pcre: pcre-$(PCRE)/.done
  55. pcre-$(PCRE)/.done: pcre-$(PCRE)
  56. pcre-$(PCRE):
  57. (test -d $@) || (wget -4 -O $@.tar.gz $(DOWNLOAD)/$@.tar.gz && tar zxfv $@.tar.gz)
  58. (cd $@ && CXXFLAGS=-m64 CFLAGS=-m64 LDFLAGS=-m64 ./configure --prefix=$(PREFIX) && gmake && sudo gmake install && touch .done)
  59. curl: curl-$(CURL)/.done
  60. curl-$(CURL)/.done: curl-$(CURL)
  61. curl-$(CURL):
  62. (test -d $@) || (wget -4 -O $@.tar.gz $(DOWNLOAD)/$@.tar.gz && tar zxfv $@.tar.gz)
  63. (cd $@ && CFLAGS=-m64 LDFLAGS=-m64 ./configure --prefix=$(PREFIX) && gmake && sudo gmake install && touch .done)
  64. speex: speex-$(SPEEX)/.done
  65. speex-$(SPEEX)/.done: speex-$(SPEEX)
  66. speex-$(SPEEX):
  67. (test -d $@) || (wget -4 -O $@.tar.gz $(DOWNLOAD)/$@.tar.gz && tar zxfv $@.tar.gz)
  68. (cd $@ && CFLAGS=-m64 LDFLAGS=-m64 ./configure --prefix=$(PREFIX) && gmake && sudo gmake install && touch .done)
  69. libedit: libedit-$(LIBEDIT)/.done
  70. libedit-$(LIBEDIT)/.done: libedit-$(LIBEDIT)
  71. libedit-$(LIBEDIT):
  72. (test -d $@) || (wget -4 -O $@.tar.gz $(DOWNLOAD)/$@.tar.gz && tar zxfv $@.tar.gz)
  73. (cd $@ && CFLAGS=-m64 LDFLAGS=-m64 ./configure --prefix=$(PREFIX) && gmake && sudo gmake install && touch .done)
  74. ldns: openssl ldns-$(LDNS)/.done
  75. ldns-$(LDNS)/.done: ldns-$(LDNS)
  76. ldns-$(LDNS):
  77. (test -d $@) || (wget -4 -O $@.tar.gz $(DOWNLOAD)/$@.tar.gz && tar zxfv $@.tar.gz)
  78. (cd $@ && CFLAGS=-m64 LDFLAGS=-m64 ./configure --with-ssl=$(PREFIX) --prefix=$(PREFIX) && gmake && sudo gmake install && touch .done)
  79. pkg-config: openssl pkg-config-$(PKGCFG)/.done
  80. pkg-config-$(PKGCFG)/.done: pkg-config-$(PKGCFG)
  81. pkg-config-$(PKGCFG):
  82. (test -d $@) || (wget -4 -O $@.tar.gz $(DOWNLOAD)/$@.tar.gz && tar zxfv $@.tar.gz)
  83. (cd $@ && CFLAGS=-m64 LDFLAGS=-m64 ./configure --with-internal-glib --prefix=$(PREFIX) && sudo gmake uninstall && gmake && sudo gmake install && \
  84. touch .done)
  85. perl: openssl perl-$(PERL)/.done
  86. perl-$(PERL)/.done: perl-$(PERL)
  87. perl-$(PERL):
  88. (test -d $@) || (wget -4 -O $@.tar.gz $(DOWNLOAD)/$@.tar.gz && tar zxfv $@.tar.gz)
  89. (cd $@ && CFLAGS=-m64 LDFLAGS=-m64 ./configure.gnu -Dcc=gcc --prefix=$(PREFIX) && gmake && sudo gmake install && touch .done)
  90. deps: has-git libjpeg openssl sqlite pcre curl speex libedit ldns pkg-config perl