File tree 3 files changed +19
-11
lines changed
build_tools/packaging/wheel
3 files changed +19
-11
lines changed Original file line number Diff line number Diff line change 28
28
29
29
# build mad, statically
30
30
pushd libmad-0.15.1b
31
+ # See https://stackoverflow.com/a/12864879/23845
32
+ sed -i.bak ' s/-march=i486//' configure
31
33
./configure --disable-shared --enable-static --prefix=" $PREFIX /audio/third_party/mad" CFLAGS=-fPIC CXXFLAGS=-fPIC \
32
34
--with-pic --disable-debug --disable-dependency-tracking
33
35
make -s -j && make install
34
36
popd
35
37
36
38
# build sox, statically
39
+ # --without-png makes OS X build less hazardous; somehow the build
40
+ # finds png and enables it. We don't want it; we'd need to package
41
+ # it statically if we do.
37
42
pushd sox-14.4.2
38
43
./configure --disable-shared --enable-static --prefix=" $PREFIX /audio/third_party/sox" \
39
44
LDFLAGS=" -L$PREFIX /audio/third_party/lame/lib -L$PREFIX /audio/third_party/flac/lib -L$PREFIX /audio/third_party/mad/lib" \
40
45
CPPFLAGS=" -I$PREFIX /audio/third_party/lame/include -I$PREFIX /audio/third_party/flac/include -I$PREFIX /audio/third_party/mad/include" \
41
- --with-lame --with-flac --with-mad --without-oggvorbis --without-oss --without-sndfile CFLAGS=-fPIC CXXFLAGS=-fPIC --with-pic --disable-debug --disable-dependency-tracking
46
+ --with-lame --with-flac --with-mad --without-png --without- oggvorbis --without-oss --without-sndfile CFLAGS=-fPIC CXXFLAGS=-fPIC --with-pic --disable-debug --disable-dependency-tracking
42
47
make -s -j && make install
43
48
popd
Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ if [ "$#" -ne 1 ]; then
5
5
fi
6
6
export CUVER=" $1 " # cu90 cu100 cpu
7
7
8
- export TORCHAUDIO_BUILD_VERSION=" 0.2 .0"
8
+ export TORCHAUDIO_BUILD_VERSION=" 0.3 .0"
9
9
export TORCHAUDIO_BUILD_NUMBER=" 1"
10
10
export OUT_DIR=" /remote/$CUVER "
11
11
@@ -27,13 +27,18 @@ export PREFIX="/tmp"
27
27
cd /tmp/audio
28
28
29
29
for PYDIR in " ${python_installations[@]} " ; do
30
- # wheels for numba does not work with python 2.7
31
- if [[ " $PYDIR " == " /opt/python/cp27-cp27m/" || " $PYDIR " == " /opt/python/cp27-cp27mu/" ]]; then
32
- continue ;
33
- fi
34
30
export PATH=$PYDIR /bin:$OLD_PATH
35
31
pip install --upgrade pip
36
- pip install -r requirements.txt
32
+
33
+ # For true hermetic builds, you ought to be constructing the docker
34
+ # from scratch each time. But this makes things marginally safer if
35
+ # you aren't doing this.
36
+ pip uninstall -y torch || true
37
+ pip uninstall -y torch_nightly || true
38
+
39
+ # NB: do not actually install requirements.txt; that is only needed for
40
+ # testing
41
+ pip install torch numpy future
37
42
IS_WHEEL=1 python setup.py clean
38
43
IS_WHEEL=1 python setup.py bdist_wheel
39
44
mkdir -p $OUT_DIR
Original file line number Diff line number Diff line change @@ -11,7 +11,7 @@ wget -q https://repo.anaconda.com/miniconda/Miniconda3-latest-MacOSX-x86_64.sh &
11
11
12
12
. ~ /minconda_wheel_env_tmp/bin/activate
13
13
14
- export TORCHAUDIO_BUILD_VERSION=" 0.2 .0"
14
+ export TORCHAUDIO_BUILD_VERSION=" 0.3 .0"
15
15
export TORCHAUDIO_BUILD_NUMBER=" 1"
16
16
export OUT_DIR=~ /torchaudio_wheels
17
17
40
40
conda create -yn $env_name python=" $desired_python "
41
41
conda activate $env_name
42
42
43
- # install torchaudio dependencies
44
- pip install -r requirements.txt
45
-
43
+ pip install torch numpy future
46
44
IS_WHEEL=1 python setup.py clean
47
45
IS_WHEEL=1 python setup.py bdist_wheel
48
46
mkdir -p $OUT_DIR
You can’t perform that action at this time.
0 commit comments