Merge pull request #1129 from LuaAndC/waf

[WIP] add package waf and use it from jack and aubio
This commit is contained in:
Timothy Gu 2016-01-06 17:11:21 -08:00
commit 967d3a9c0d
4 changed files with 32 additions and 3 deletions

View File

@ -2569,6 +2569,10 @@ local-pkg-list: $(LOCAL_PKG_LIST)</pre>
<td class="package">vtk6</td>
<td class="website"><a href="http://www.vtk.org/">VTK6</a></td>
</tr>
<tr>
<td class="package">waf</td>
<td class="website"><a href="https://waf.io/">Waf: the meta build system</a></td>
</tr>
<tr>
<td class="package">wavpack</td>
<td class="website"><a href="http://www.wavpack.com/">WavPack</a></td>

View File

@ -8,7 +8,7 @@ $(PKG)_CHECKSUM := 1cc58e0fed2b9468305b198ad06b889f228b797a082c2ede716dc30fcb4f8
$(PKG)_SUBDIR := aubio-$($(PKG)_VERSION)
$(PKG)_FILE := aubio-$($(PKG)_VERSION).tar.bz2
$(PKG)_URL := http://www.aubio.org/pub/$($(PKG)_FILE)
$(PKG)_DEPS := gcc ffmpeg fftw jack libsamplerate libsndfile
$(PKG)_DEPS := gcc ffmpeg fftw jack libsamplerate libsndfile waf
define $(PKG)_UPDATE
$(WGET) -q -O- 'http://www.aubio.org/download' | \
@ -17,11 +17,13 @@ define $(PKG)_UPDATE
endef
define $(PKG)_BUILD
rm -rf '$(1)/waf' '$(1)/waflib'
cd '$(1)' && \
AR='$(TARGET)-ar' \
CC='$(TARGET)-gcc' \
PKGCONFIG='$(TARGET)-pkg-config' \
./waf configure \
'$(PREFIX)/$(BUILD)/bin/waf' \
configure \
-j '$(JOBS)' \
--with-target-platform='win$(BITS)' \
--prefix='$(PREFIX)/$(TARGET)' \
@ -33,7 +35,7 @@ define $(PKG)_BUILD
# disable txt2man and doxygen
$(SED) -i '/\(TXT2MAN\|DOXYGEN\)/d' '$(1)/build/c4che/_cache.py'
cd '$(1)' && ./waf build install
cd '$(1)' && '$(PREFIX)/$(BUILD)/bin/waf' build install
# It is not trivial to adjust the installation in waf-based builds
$(if $(BUILD_STATIC), \

View File

@ -17,6 +17,7 @@ define $(PKG)_UPDATE
endef
define $(PKG)_BUILD
# TODO: use waf installed by MXE package waf
cd '$(1)' && \
AR='$(TARGET)-ar' \
CC='$(TARGET)-gcc' \

22
src/waf.mk Normal file
View File

@ -0,0 +1,22 @@
# This file is part of MXE.
# See index.html for further information.
PKG := waf
$(PKG)_IGNORE :=
$(PKG)_VERSION := 1.8.17
$(PKG)_CHECKSUM := 63c53b03dd23afde1008dced06a011dad581d24392818c8069a40af99f6ac2b6
$(PKG)_SUBDIR := $(PKG)-$($(PKG)_VERSION)
$(PKG)_FILE := $(PKG)-$($(PKG)_VERSION).tar.bz2
$(PKG)_URL := https://waf.io/$($(PKG)_FILE)
$(PKG)_TARGETS := $(BUILD) $(MXE_TARGETS)
define $(PKG)_UPDATE
$(WGET) -q -O- 'https://waf.io/' | \
$(SED) -n 's,.*waf-\([0-9][^>]*\)\.tar.*,\1,p' | \
head -1
endef
define $(PKG)_BUILD_$(BUILD)
mkdir -p '$(PREFIX)/$(BUILD)/bin'
cp '$(1)/waf' '$(PREFIX)/$(BUILD)/bin/waf'
endef