owncloud / client

🖥️ Desktop Syncing Client for ownCloud
GNU General Public License v2.0
1.39k stars 667 forks source link

Cross compile Windows Client 1.3.0 on opensuse 12.3 64bit #791

Closed treasuring closed 11 years ago

treasuring commented 11 years ago

Hi,

I am trying to cross compile the windows client 1.3.0 from the source archive present on http://download.owncloud.com/download/ocsync-0.80.0.tar.bz2 & http://download.owncloud.com/download/mirall-1.3.0.tar.bz2 or git clone git://git.csync.org/users/freitag/csync.git ocsync & git clone git://github.com/owncloud/mirall.git

This my compile setting:

//ocsync mingw32-cmake \ -DCMAKE_BUILD_TYPE="Debug" \ -DLOG_TO_CALLBACK=ON \ -DCMOCKA_LIBRARIES="..\cmocka-0.3.1\build\src" \ -DCMOCKA_INCLUDE_DIR="..\cmocka-0.3.1\src" \ ../ocsync

//mirall cmake \ -DCMAKE_BUILD_TYPE="Debug" \ -DCSYNC_BUILD_PATH=../ocsync-build \ -DCSYNC_INCLUDE_PATH=../ocsync/src \ -DSPHINX_EXECUTABLE=/usr/local \ -DJPEG_LIBRARY=/usr/local \ -DJPEG_INCLUDE_DIR=/usr/local \ -DTIFF_LIBRARY=/usr/local \ -DTIFF_INCLUDE_DIR=/usr/local \ -DINOTIFY_INCLUDE_DIR=/usr/local \ -DCMAKE_TOOLCHAIN_FILE=../mirall/admin/win/Toolchain-mingw32-openSUSE.cmake \ ../mirall

The Question :

I am able to compile ocsync but failing in compile mirall.

The Error Code:

owncloud-build:/opt/build/mirall-build # cmake \

-DCMAKE_BUILD_TYPE="Debug" \ -DCSYNC_BUILD_PATH=../ocsync-build \ -DCSYNC_INCLUDE_PATH=../ocsync-0.80.0/src \ -DSPHINX_EXECUTABLE=/usr/local/sphinx \ -DJPEG_LIBRARY=/usr/local/libjpeg \ -DJPEG_INCLUDE_DIR=/usr/local> -DJPEG_INCLUDE_DIR=/usr/local/libjpeg \ -DTIFF_LIBRARY=/usr/local/libtiff \ -DTIFF_INCLUDE_DIR=/usr/local/libtiff \ -DINOTIFY_INCLUDE_DIR=/usr/local/inotify \ ake \MAKE_TOOLCHAIN_FILE=../mirall-1.3.0/admin/win/Toolchain-mingw32-openSUSE.cm ../mirall-1.3.0 -- The C compiler identification is GNU 4.8.1 -- The CXX compiler identification is GNU 4.8.1 -- Check for working C compiler: /usr/bin/i686-w64-mingw32-gcc -- Check for working C compiler: /usr/bin/i686-w64-mingw32-gcc -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working CXX compiler: /usr/bin/i686-w64-mingw32-g++ -- Check for working CXX compiler: /usr/bin/i686-w64-mingw32-g++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done 7cd2f39f82d3044bc3e8bba3ade7379319a39430 -- Looking for Q_WS_X11 -- Looking for Q_WS_X11 - not found -- Looking for Q_WS_WIN -- Looking for Q_WS_WIN - found -- Looking for Q_WS_QWS -- Looking for Q_WS_QWS - not found -- Looking for Q_WS_MAC -- Looking for Q_WS_MAC - not found -- Found OpenGL: opengl32 -- Found ZLIB: /usr/i686-w64-mingw32/sys-root/mingw/lib/libz.dll.a (found version "1.2.7") -- Found PNG: /usr/i686-w64-mingw32/sys-root/mingw/lib/libpng.dll.a (found version "1.5.11") -- Found JPEG: /usr/local/libjpeg -- Found TIFF: /usr/local/libtiff -- Found Qt4: i686-w64-mingw32-qmake (found suitable version "4.8.4", minimum required is "4.6.0") -- Found Csync: ../ocsync-build/src/libocsync.dll -- Found INOTIFY: /usr/local/inotify -- Found Sphinx: /usr/local/sphinx -- Found PdfLatex: /usr/bin/pdflatex -- Found QtKeyChain: /usr/i686-w64-mingw32/sys-root/mingw/bin/libqtkeychain.dll -- Configuring done WARNING: Target "owncloud" requests linking to directory "/usr/local/libjpeg". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "owncloud" requests linking to directory "/usr/local/libtiff". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "owncloud" requests linking to directory "/usr/local/libjpeg". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "owncloud" requests linking to directory "/usr/local/libtiff". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "owncloudsync" requests linking to directory "/usr/local/libjpeg". Targets may link only to libraries. CMake is dropping the item. WARNING: Target "owncloudsync" requests linking to directory "/usr/local/libtiff". Targets may link only to libraries. CMake is dropping the item. -- Generating done -- Build files have been written to: /opt/build/mirall-build owncloud-build:/opt/build/mirall-build # make [ 1%] Generating mirall/moc_folderwatcher_win.cxx [ 2%] Generating mirall/moc_folderman.cxx [ 3%] Generating mirall/moc_folder.cxx [ 3%] Generating mirall/moc_folderwatcher.cxx [ 4%] Generating mirall/moc_owncloudfolder.cxx [ 5%] Generating mirall/moc_csyncthread.cxx [ 5%] Generating mirall/moc_owncloudinfo.cxx [ 6%] Generating mirall/moc_credentialstore.cxx [ 6%] Generating mirall/moc_logger.cxx [ 7%] Generating mirall/moc_connectionvalidator.cxx [ 8%] Generating mirall/moc_inotify.cxx [ 8%] Generating mirall/moc_folderwatcher_inotify.cxx Scanning dependencies of target owncloudsync [ 9%] Building CXX object src/CMakeFiles/owncloudsync.dir/mirall/folderman.cpp.obj In file included from /opt/build/mirall-1.3.0/src/mirall/syncresult.h:22:0, from /opt/build/mirall-1.3.0/src/mirall/folder.h:29, from /opt/build/mirall-1.3.0/src/mirall/folderman.h:22, from /opt/build/mirall-1.3.0/src/mirall/folderman.cpp:15: /opt/build/mirall-1.3.0/src/mirall/syncfileitem.h:6:19: fatal error: csync.h: No such file or directory

include

               ^

compilation terminated. make[2]: * [src/CMakeFiles/owncloudsync.dir/mirall/folderman.cpp.obj] Error 1 make[1]: * [src/CMakeFiles/owncloudsync.dir/all] Error 2 make: *\ [all] Error 2

Please advice. Thanks!

dragotin commented 11 years ago

Please use an absolute path in the cmake call, ie.

cmake \
-DCMAKE_BUILD_TYPE="Debug" \
-DCSYNC_BUILD_PATH=/home/treasuring/owncloud/ocsync-build \
-DCSYNC_INCLUDE_PATH=/home/treasuring/owncloud/ocsync/src \
-DSPHINX_EXECUTABLE=/usr/local \