aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitignore20
-rw-r--r--cmake/installdata/windows/dlls.txt1
-rw-r--r--cmake/modules/FindLibDvd.cmake2
-rw-r--r--cmake/scripts/windows/ArchSetup.cmake5
-rw-r--r--lib/libdvd/Makefile.in105
-rw-r--r--tools/buildsteps/windows/buildffmpeg.sh22
-rw-r--r--tools/buildsteps/windows/buildhelpers.sh2
-rw-r--r--tools/buildsteps/windows/buildlibdvd.sh24
-rw-r--r--tools/buildsteps/windows/download-msys2.bat4
-rw-r--r--tools/buildsteps/windows/make-mingwlibs.sh32
-rw-r--r--tools/buildsteps/windows/prepare-env.bat4
11 files changed, 28 insertions, 193 deletions
diff --git a/.gitignore b/.gitignore
index 4071615709..e87f5701e4 100644
--- a/.gitignore
+++ b/.gitignore
@@ -249,6 +249,7 @@ lib/cpluff/stamp-h1
/project/BuildDependencies/bin/swig
/project/BuildDependencies/bin/doxygen
/project/BuildDependencies/bin/json-rpc
+/project/BuildDependencies/mingwlibs
/project/BuildDependencies/x64
/project/BuildDependencies/win32
@@ -265,16 +266,7 @@ lib/cpluff/stamp-h1
/system/cec.dll
/system/libxslt.dll
/system/ssleay32.dll
-/system/avcodec-57.dll
-/system/avfilter-6.dll
-/system/avformat-57.dll
-/system/avutil-55.dll
-/system/postproc-54.dll
-/system/swscale-4.dll
-/system/swresample-2.dll
/system/libxml2.dll
-/system/libdvdcss-2.dll
-/system/libdvdnav.dll
/system/libass.dll
/system/libbluray*
/system/libcdio.dll
@@ -493,20 +485,10 @@ lib/cpluff/stamp-h1
/xbmc/windowing/Makefile
/xbmc/windowing/egl/Makefile
-# /lib/libdvd/
-/lib/libdvd/bin
-/lib/libdvd/include
-/lib/libdvd/lib
-/lib/libdvd/Makefile
-/lib/libdvd/share
-
#/lib/win32
/lib/win32/*.tar*
/lib/win32/pax_global_header
-#/lib/win32/ffmpeg
-/lib/win32/ffmpeg/
-
/lib/libUPnP/Makefile
# /portable_data
diff --git a/cmake/installdata/windows/dlls.txt b/cmake/installdata/windows/dlls.txt
index bfd9011ad8..e6ea5fff30 100644
--- a/cmake/installdata/windows/dlls.txt
+++ b/cmake/installdata/windows/dlls.txt
@@ -2,3 +2,4 @@ system/*.dll .
project/BuildDependencies/${ARCH}/bin/libbluray*.jar .
project/Win32BuildSetup/dependencies/python27.dll .
project/BuildDependencies/${ARCH}/bin/*.dll .
+project/BuildDependencies/mingwlibs/${ARCH}/bin/*.dll .
diff --git a/cmake/modules/FindLibDvd.cmake b/cmake/modules/FindLibDvd.cmake
index eeb416c2a5..86af89ce65 100644
--- a/cmake/modules/FindLibDvd.cmake
+++ b/cmake/modules/FindLibDvd.cmake
@@ -203,7 +203,7 @@ if(NOT WIN32)
endif()
else()
# Dynamically loaded on Windows
- find_path(LIBDVD_INCLUDE_DIR dvdcss/dvdcss.h PATHS ${CMAKE_SOURCE_DIR}/lib/libdvd/include)
+ find_path(LIBDVD_INCLUDE_DIR dvdcss/dvdcss.h)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(LibDvd REQUIRED_VARS LIBDVD_INCLUDE_DIR)
diff --git a/cmake/scripts/windows/ArchSetup.cmake b/cmake/scripts/windows/ArchSetup.cmake
index 1ab16113e7..63bf8d79d5 100644
--- a/cmake/scripts/windows/ArchSetup.cmake
+++ b/cmake/scripts/windows/ArchSetup.cmake
@@ -19,9 +19,8 @@ set(CORE_MAIN_SOURCE ${CMAKE_SOURCE_DIR}/xbmc/platform/win32/WinMain.cpp)
set(PRECOMPILEDHEADER_DIR ${PROJECT_BINARY_DIR}/${CORE_BUILD_CONFIG}/objs)
set(CMAKE_SYSTEM_NAME Windows)
-list(APPEND CMAKE_SYSTEM_PREFIX_PATH ${CMAKE_SOURCE_DIR}/lib/win32)
-list(APPEND CMAKE_SYSTEM_PREFIX_PATH ${CMAKE_SOURCE_DIR}/lib/win32/ffmpeg)
-list(APPEND CMAKE_SYSTEM_LIBRARY_PATH ${CMAKE_SOURCE_DIR}/lib/win32/ffmpeg/bin)
+list(APPEND CMAKE_SYSTEM_PREFIX_PATH ${CMAKE_SOURCE_DIR}/project/BuildDependencies/mingwlibs/${ARCH})
+list(APPEND CMAKE_SYSTEM_LIBRARY_PATH ${CMAKE_SOURCE_DIR}/project/BuildDependencies/mingwlibs/${ARCH}/bin)
list(APPEND CMAKE_SYSTEM_PREFIX_PATH ${CMAKE_SOURCE_DIR}/project/BuildDependencies/${ARCH})
list(APPEND CMAKE_SYSTEM_PREFIX_PATH ${CMAKE_SOURCE_DIR}/project/BuildDependencies)
diff --git a/lib/libdvd/Makefile.in b/lib/libdvd/Makefile.in
deleted file mode 100644
index 5a4508bfff..0000000000
--- a/lib/libdvd/Makefile.in
+++ /dev/null
@@ -1,105 +0,0 @@
-
-AR=@AR@
-ARCH=@ARCH@
-CC=@CC@
-CXX=@CXX@
-
-ifeq (@CROSS_COMPILING@,yes)
- DEPENDS_DIR = $(shell grep "^PREFIX=/" @abs_top_srcdir@/tools/depends/Makefile.include | sed 's/PREFIX=//g')
- DVDNAV_A = $(DEPENDS_DIR)/lib/libdvdnav.a
- DVDREAD_A = $(DEPENDS_DIR)/lib/libdvdread.a
- DVDCSS_A = $(DEPENDS_DIR)/lib/libdvdcss.a
-else
- DVDNAV_A = @abs_top_srcdir@/tools/depends/target/libdvdnav/dvdnav-install/lib/libdvdnav.a
- DVDREAD_A = @abs_top_srcdir@/tools/depends/target/libdvdread/dvdread-install/lib/libdvdread.a
- DVDCSS_A = @abs_top_srcdir@/tools/depends/target/libdvdcss/dvdcss-install/lib/libdvdcss.a
-endif
-
-SYSDIR = @abs_top_srcdir@/system/players/VideoPlayer
-SOS = libdvdnav-$(ARCH).so
-
-WRAPPER = @abs_top_srcdir@/xbmc/cores/DllLoader/exports/wrapper.o
-WRAPPER_DEF = @abs_top_srcdir@/xbmc/cores/DllLoader/exports/wrapper.def
-WRAPPER_MACH_ALIAS = @abs_top_srcdir@/xbmc/cores/DllLoader/exports/wrapper_mach_alias
-
-ifeq ($(findstring osx,$(ARCH)),osx)
- SO_LDFLAGS = $(LDFLAGS) -bundle -undefined dynamic_lookup -read_only_relocs suppress
-else
- SO_LDFLAGS = $(LDFLAGS) -shared -fPIC -rdynamic
-endif
-
-ifeq ($(ARCH), powerpc-osx)
- # Add -lbundle1.o for powerpc-osx
- BUNDLE1_O = -lbundle1.o
-endif
-
-ifeq ($(ARCH),arm-osx)
- BUILD_DVDCSS = 0
-else
- BUILD_DVDCSS = 1
-endif
-ifeq ($(BUILD_DVDCSS),1)
- SOS += libdvdcss-$(ARCH).so
- DVDREAD_DEPS = $(DVDCSS_A)
- DVDCSS_OBJS = libdvdcss/*.o
-endif
-
-
-SLIB = $(addprefix $(SYSDIR)/, $(SOS))
-
-DISTCLEAN_FILES=libdvdcss/* libdvdnav/* libdvdread/*
-
-all: $(SLIB)
-
-ifeq ($(findstring osx,$(ARCH)), osx)
-
-$(SYSDIR)/libdvdcss-$(ARCH).so: $(WRAPPER) $(DVDREAD_DEPS)
- [ -d libdvdcss ] || mkdir libdvdcss
- cd libdvdcss; $(AR) x $(DVDCSS_A)
- $(CC) $(SO_LDFLAGS) -Wl,-alias_list,$(WRAPPER_MACH_ALIAS) -o $@ \
- $(WRAPPER) $(DVDCSS_OBJS) $(BUNDLE1_O)
-
-$(SYSDIR)/libdvdnav-$(ARCH).so: $(WRAPPER) $(DVDNAV_A) $(DVDREAD_A) $(DVDREAD_DEPS)
- [ -d libdvdread ] || mkdir libdvdread
- [ -d libdvdnav ] || mkdir libdvdnav
- [ $(BUILD_DVDCSS) -eq 1 ] && { [ -d libdvdcss ] || mkdir libdvdcss; } || :
- [ $(BUILD_DVDCSS) -eq 1 ] && { cd libdvdcss && $(AR) x $(DVDCSS_A); } || :
- cd libdvdnav; $(AR) x $(DVDNAV_A)
- cd libdvdread; $(AR) x $(DVDREAD_A)
- $(CC) $(SO_LDFLAGS) -Wl,-alias_list,$(WRAPPER_MACH_ALIAS) -o $@ \
- $(WRAPPER) libdvdread/*.o libdvdnav/*.o $(DVDCSS_OBJS) $(BUNDLE1_O)
-
-else
-$(SYSDIR)/libdvdcss-$(ARCH).so: $(WRAPPER) $(WRAPPER_DEF) $(DVDCSS_A)
- [ -d libdvdcss ] || mkdir libdvdcss
- cd libdvdcss; $(AR) x $(DVDCSS_A)
- $(CC) -o $@ $(SO_LDFLAGS) -Wl,--soname,$@ $(DVDCSS_OBJS) -Wl,--unresolved-symbols=ignore-all -lm \
- `cat $(WRAPPER_DEF)` $(WRAPPER)
-
-$(SYSDIR)/libdvdnav-$(ARCH).so: $(WRAPPER) $(WRAPPER_DEF) $(DVDNAV_A) $(DVDREAD_A) $(DVDCSS_A)
- [ -d libdvdread ] || mkdir libdvdread
- [ -d libdvdnav ] || mkdir libdvdnav
- [ $(BUILD_DVDCSS) -eq 1 ] && { [ -d libdvdcss ] || mkdir libdvdcss; } || :
- [ $(BUILD_DVDCSS) -eq 1 ] && { cd libdvdcss && $(AR) x $(DVDCSS_A); } || :
- cd libdvdnav; $(AR) x $(DVDNAV_A)
- cd libdvdread; $(AR) x $(DVDREAD_A)
- $(CC) -o $@ $(SO_LDFLAGS) -Wl,--soname,$@ libdvdread/*.o libdvdnav/*.o $(DVDCSS_OBJS) -lm -Wl,--unresolved-symbols=ignore-all \
- `cat $(WRAPPER_DEF)` $(WRAPPER)
-endif
-
-$(WRAPPER_DEF):
- $(MAKE) -C @abs_top_srcdir@/xbmc/cores/DllLoader/exports wrapper.def
-
-$(DVDNAV_A): $(DVDREAD_A)
- $(MAKE) -C @abs_top_srcdir@/tools/depends/target/libdvdnav
-
-$(DVDREAD_A): $(DVDREAD_DEPS)
- $(MAKE) -C @abs_top_srcdir@/tools/depends/target/libdvdread
-
-ifeq ($(BUILD_DVDCSS),1)
-$(DVDCSS_A):
- $(MAKE) -C @abs_top_srcdir@/tools/depends/target/libdvdcss
-endif
-
-include @abs_top_srcdir@/Makefile.include
-
diff --git a/tools/buildsteps/windows/buildffmpeg.sh b/tools/buildsteps/windows/buildffmpeg.sh
index 67e375e012..7950533621 100644
--- a/tools/buildsteps/windows/buildffmpeg.sh
+++ b/tools/buildsteps/windows/buildffmpeg.sh
@@ -10,18 +10,7 @@ FFMPEG_DEFAULT_OPTS=""
FFMPEG_TARGET_OS=mingw32
do_loaddeps $FFMPEG_VERSION_FILE
-FFMPEGDESTDIR=/xbmc/lib/win32/$LIBNAME
-
-if [ "$(pathChanged $FFMPEGDESTDIR $FFMPEG_VERSION_FILE /xbmc/project/BuildDependencies/DownloadMingwBuildEnv.bat /xbmc/tools/buildsteps/windows)" == "0" ]
-then
- cp $FFMPEGDESTDIR/bin/*.dll /xbmc/system/
- if [ -f $BGPROCESSFILE ]; then
- rm $BGPROCESSFILE
- fi
- exit
-else
- git clean -dffx $FFMPEGDESTDIR
-fi
+FFMPEGDESTDIR=$PREFIX
do_getFFmpegConfig() {
if [[ -f "$FFMPEG_CONFIG_FILE" ]]; then
@@ -158,11 +147,4 @@ do_print_status "$LIBNAME-$VERSION (${BITS})" "$blue_color" "Configuring"
--disable-static --enable-shared $FFMPEG_OPTS_SHARED \
--extra-cflags="$extra_cflags" --extra-ldflags="$extra_ldflags"
-do_makelib &&
-cp $FFMPEGDESTDIR/bin/*.dll /xbmc/system/ &&
-tagSuccessFulBuild $FFMPEGDESTDIR $FFMPEG_VERSION_FILE /xbmc/project/BuildDependencies/DownloadMingwBuildEnv.bat /xbmc/tools/buildsteps/windows
-
-#remove the bgprocessfile for signaling the process end
-if [ -f $BGPROCESSFILE ]; then
- rm $BGPROCESSFILE
-fi
+do_makelib
diff --git a/tools/buildsteps/windows/buildhelpers.sh b/tools/buildsteps/windows/buildhelpers.sh
index 2b6cefaeb3..9a611b4574 100644
--- a/tools/buildsteps/windows/buildhelpers.sh
+++ b/tools/buildsteps/windows/buildhelpers.sh
@@ -162,7 +162,7 @@ function getBuildHash ()
shift 1
local hashStr
hashStr="$(git rev-list HEAD --max-count=1 -- $checkPath $@)"
- hashStr="$hashStr $@ $BITS $tools"
+ hashStr="$hashStr $@ $BITS $TOOLS"
echo $hashStr
}
diff --git a/tools/buildsteps/windows/buildlibdvd.sh b/tools/buildsteps/windows/buildlibdvd.sh
index 0e983db94f..7e1756adb6 100644
--- a/tools/buildsteps/windows/buildlibdvd.sh
+++ b/tools/buildsteps/windows/buildlibdvd.sh
@@ -3,22 +3,10 @@
[[ -f buildhelpers.sh ]] &&
source buildhelpers.sh
-LIBDVDPREFIX=/xbmc/lib/libdvd
+LIBDVDPREFIX=$PREFIX
PKG_CONFIG_PATH=$LIBDVDPREFIX/lib/pkgconfig
export PKG_CONFIG_PATH
-if [ "$(pathChanged $LIBDVDPREFIX /xbmc/tools/depends/target/libdvdcss/DVDCSS-VERSION /xbmc/tools/depends/target/libdvdread/DVDREAD-VERSION /xbmc/tools/depends/target/libdvdnav/DVDNAV-VERSION /xbmc/project/BuildDependencies/DownloadMingwBuildEnv.bat /xbmc/tools/buildsteps/windows)" == "0" ]
-then
- cp "$LIBDVDPREFIX/bin/libdvdcss-2.dll" /xbmc/system/
- cp $LIBDVDPREFIX/bin/libdvdnav.dll /xbmc/system/
- if [ -f $BGPROCESSFILE ]; then
- rm $BGPROCESSFILE
- fi
- exit
-else
- git clean -dffx $LIBDVDPREFIX
-fi
-
do_load_autoconf() {
do_loaddeps $1
do_clean_get $MAKEFLAGS
@@ -37,8 +25,7 @@ CC="gcc -static-libgcc" \
--build="$MINGW_CHOST"
do_makelib $MAKEFLAGS
-strip -S $LIBDVDPREFIX/bin/libdvdcss-2.dll &&
-cp "$LIBDVDPREFIX/bin/libdvdcss-2.dll" /xbmc/system/
+strip -S $LIBDVDPREFIX/bin/libdvdcss-2.dll
#libdvdread
do_load_autoconf /xbmc/tools/depends/target/libdvdread/DVDREAD-VERSION
@@ -74,11 +61,4 @@ gcc \
-static-libgcc
strip -S $LIBDVDPREFIX/bin/libdvdnav.dll &&
-cp $LIBDVDPREFIX/bin/libdvdnav.dll /xbmc/system/ &&
-tagSuccessFulBuild $LIBDVDPREFIX /xbmc/tools/depends/target/libdvdcss/DVDCSS-VERSION /xbmc/tools/depends/target/libdvdread/DVDREAD-VERSION /xbmc/tools/depends/target/libdvdnav/DVDNAV-VERSION /xbmc/project/BuildDependencies/DownloadMingwBuildEnv.bat /xbmc/tools/buildsteps/windows
do_print_status "libdvd (${BITS})" "$green_color" "Done"
-
-#remove the bgprocessfile for signaling the process end
-if [ -f $BGPROCESSFILE ]; then
- rm $BGPROCESSFILE
-fi \ No newline at end of file
diff --git a/tools/buildsteps/windows/download-msys2.bat b/tools/buildsteps/windows/download-msys2.bat
index 9452206e7c..6f3f9e8949 100644
--- a/tools/buildsteps/windows/download-msys2.bat
+++ b/tools/buildsteps/windows/download-msys2.bat
@@ -440,6 +440,8 @@ if %build32%==yes (
echo.
echo.BITS='32bit'
echo.export BITS
+ echo.ARCHITECTURE='win32'
+ echo.export ARCHITECTURE
)>>%instdir%\local32\etc\profile.local
)
@@ -493,6 +495,8 @@ if %build64%==yes (
echo.
echo.BITS='64bit'
echo.export BITS
+ echo.ARCHITECTURE='x64'
+ echo.export ARCHITECTURE
)>>%instdir%\local64\etc\profile.local
)
diff --git a/tools/buildsteps/windows/make-mingwlibs.sh b/tools/buildsteps/windows/make-mingwlibs.sh
index 50470cd8d3..b37fc9fa74 100644
--- a/tools/buildsteps/windows/make-mingwlibs.sh
+++ b/tools/buildsteps/windows/make-mingwlibs.sh
@@ -1,9 +1,8 @@
+[[ -f $(dirname $0)/buildhelpers.sh ]] &&
+ source $(dirname $0)/buildhelpers.sh
Win32BuildSetup=/xbmc/project/Win32BuildSetup
ERRORFILE=$Win32BuildSetup/errormingw
-NOPFILE=$Win32BuildSetup/noprompt
-MAKECLEANFILE=$Win32BuildSetup/makeclean
-BGPROCESSFILE=$Win32BuildSetup/bgprocess
TOUCH=/bin/touch
RM=/bin/rm
NOPROMPT=0
@@ -48,20 +47,13 @@ checkfiles() {
done
}
-#start the process backgrounded
-runBackgroundProcess() {
- $TOUCH $BGPROCESSFILE
- echo "backgrounding: sh $1 $BGPROCESSFILE $TOOLS & (workdir: $(PWD))"
- sh $1 $BGPROCESSFILE $targetBuild $TOOLS &
- echo "waiting on bgprocess..."
- while [ -f $BGPROCESSFILE ]; do
- echo -n "."
- sleep 5
- done
-}
-
-
buildProcess() {
+export PREFIX=/xbmc/project/BuildDependencies/mingwlibs/$ARCHITECTURE
+if [ "$(pathChanged $PREFIX /xbmc/tools/buildsteps/windows /xbmc/tools/depends/target/*/*-VERSION)" == "0" ]; then
+ return
+fi
+
+git clean -dffx $PREFIX
cd /xbmc/tools/buildsteps/windows
# compile our mingw dlls
@@ -79,8 +71,8 @@ echo -ne "\033]0;building FFmpeg $BITS\007"
echo "-------------------------------------------------"
echo " building FFmpeg $BITS"
echo "-------------------------------------------------"
-runBackgroundProcess "./buildffmpeg.sh $MAKECLEAN"
-setfilepath /xbmc/system
+./buildffmpeg.sh
+setfilepath $PREFIX/bin
checkfiles avcodec-57.dll avformat-57.dll avutil-55.dll postproc-54.dll swscale-4.dll avfilter-6.dll swresample-2.dll
echo "-------------------------------------------------"
echo " building of FFmpeg $BITS done..."
@@ -90,8 +82,7 @@ echo -ne "\033]0;building libdvd $BITS\007"
echo "-------------------------------------------------"
echo " building libdvd $BITS"
echo "-------------------------------------------------"
-runBackgroundProcess "./buildlibdvd.sh $MAKECLEAN"
-setfilepath /xbmc/system
+./buildlibdvd.sh
checkfiles libdvdcss-2.dll libdvdnav.dll
echo "-------------------------------------------------"
echo " building of libdvd $BITS done..."
@@ -103,6 +94,7 @@ echo "compile mingw libs $BITS done..."
echo
echo "-------------------------------------------------------------------------------"
+tagSuccessFulBuild $PREFIX /xbmc/tools/buildsteps/windows /xbmc/tools/depends/target/*/*-VERSION
}
run_builds() {
diff --git a/tools/buildsteps/windows/prepare-env.bat b/tools/buildsteps/windows/prepare-env.bat
index 8a0a1efd0e..7443f9d256 100644
--- a/tools/buildsteps/windows/prepare-env.bat
+++ b/tools/buildsteps/windows/prepare-env.bat
@@ -13,8 +13,8 @@ IF EXIST %WORKSPACE%\project\Win32BuildSetup\BUILD_WIN32 rmdir %WORKSPACE%\proje
rem we assume git in path as this is a requirement
rem git clean the untracked files and directories
rem but keep the downloaded dependencies
-ECHO running git clean -xffd -e "lib/libdvd" -e "lib/win32/ffmpeg" -e "project/BuildDependencies/downloads" -e "project/BuildDependencies/downloads2" -e "project/Win32BuildSetup/dependencies/vcredist"
-git clean -xffd -e "lib/libdvd" -e "lib/win32/ffmpeg" -e "project/BuildDependencies/downloads" -e "project/BuildDependencies/downloads2" -e "project/Win32BuildSetup/dependencies/vcredist"
+ECHO running git clean -xffd -e "project/BuildDependencies/downloads" -e "project/BuildDependencies/downloads2" -e "project/BuildDependencies/mingwlibs" -e "project/Win32BuildSetup/dependencies/vcredist"
+git clean -xffd -e "project/BuildDependencies/downloads" -e "project/BuildDependencies/downloads2" -e "project/BuildDependencies/mingwlibs" -e "project/Win32BuildSetup/dependencies/vcredist"
rem cleaning additional directories
ECHO delete build directories