Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wine not detected on Gentoo #4108

Closed
Metalhead33 opened this issue Jan 13, 2018 · 11 comments
Closed

Wine not detected on Gentoo #4108

Metalhead33 opened this issue Jan 13, 2018 · 11 comments

Comments

@Metalhead33
Copy link

Metalhead33 commented Jan 13, 2018

I am a user of Gentoo Linux, and "somewhat recently" (in November, 2017), the other Gentoo people decided to completely repackage wine. Gone were the days of having to emerge "app-emulation/wine", instead it's now a combination of "virtual/wine" and "app-emulation/wine-vanilla", "app-emulation/wine-staging" or "app-emulation/wine-d3d".

What does that mean?

That means that everything wine-related is found somewhere else than before, unless I manually symlink or something.

Which in turn means this:

-- The C compiler identification is GNU 7.2.0
-- The CXX compiler identification is GNU 7.2.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.28") 
-- Found Git: /usr/bin/git (found version "2.13.6") 

Configuring LMMS
--------------------------
* Project version             : 1.2.0-rc5.9
*   Major version             : 1
*   Minor version             : 2
*   Release version           : 0
*   Stage version             : rc5
*   Build version             : 9
*

Optional Version Usage:
--------------------------
*   Override version:           -DFORCE_VERSION=x.x.x-x
*   Ignore Git information:     -DFORCE_VERSION=internal

PROCESSOR: x86_64
Machine: x86_64-pc-linux-gnu
-- Target host is 64 bit
-- Looking for include file stdint.h
-- Looking for include file stdint.h - found
-- Looking for include file stdlib.h
-- Looking for include file stdlib.h - found
-- Looking for include file pthread.h
-- Looking for include file pthread.h - found
-- Looking for include file semaphore.h
-- Looking for include file semaphore.h - found
-- Looking for include file unistd.h
-- Looking for include file unistd.h - found
-- Looking for include file sys/types.h
-- Looking for include file sys/types.h - found
-- Looking for include file sys/ipc.h
-- Looking for include file sys/ipc.h - found
-- Looking for include file sys/shm.h
-- Looking for include file sys/shm.h - found
-- Looking for include file sys/time.h
-- Looking for include file sys/time.h - found
-- Looking for include file sched.h
-- Looking for include file sched.h - found
-- Looking for include file sys/soundcard.h
-- Looking for include file sys/soundcard.h - found
-- Looking for include file soundcard.h
-- Looking for include file soundcard.h - not found
-- Looking for include file fcntl.h
-- Looking for include file fcntl.h - found
-- Looking for include file sys/ioctl.h
-- Looking for include file sys/ioctl.h - found
-- Looking for include file ctype.h
-- Looking for include file ctype.h - found
-- Looking for include file string.h
-- Looking for include file string.h - found
-- Looking for include file process.h
-- Looking for include file process.h - not found
-- Looking for include file locale.h
-- Looking for include file locale.h - found
-- Looking for Q_WS_X11
-- Looking for Q_WS_X11 - found
-- Looking for Q_WS_WIN
-- Looking for Q_WS_WIN - not 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 Qt4: /usr/bin/qmake (found suitable version "4.8.7", minimum required is "4.6.0;COMPONENTS;QtCore;QtGui;QtXml") 
-- Found Qt translations in /usr/share/qt4/translations
-- Checking for module 'sndfile>=1.0.11'
--   Found sndfile, version 1.0.26
-- Checking for module 'carla-standalone>=1.9.5'
--   Found carla-standalone, version 1.9.5
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE  
-- Found SDL: /usr/lib64/libSDL.so;-lpthread (found version "1.2.15") 
-- Checking for module 'portaudio-2.0'
--   Found portaudio-2.0, version 19
-- Found Portaudio: portaudio;asound;m;pthread
-- Could NOT find SOUNDIO (missing:  SOUNDIO_LIBRARY SOUNDIO_INCLUDE_DIR) 
-- Checking for module 'libpulse'
--   Found libpulse, version 11.1
-- Found PulseAudio Simple: /usr/lib64/libpulse.so
-- Found Lame: /usr/include  
-- Looking for vorbis_bitrate_addblock in vorbis
-- Looking for vorbis_bitrate_addblock in vorbis - found
-- Found OggVorbis: /usr/lib64/libogg.so;/usr/lib64/libvorbis.so;/usr/lib64/libvorbisfile.so;/usr/lib64/libvorbisenc.so
-- Looking for snd_seq_create_simple_port in asound
-- Looking for snd_seq_create_simple_port in asound - found
-- Found ALSA: /usr/lib64/libasound.so
-- Looking for include file machine/soundcard.h
-- Looking for include file machine/soundcard.h - not found
-- Looking for include file linux/awe_voice.h
-- Looking for include file linux/awe_voice.h - not found
-- Looking for include file awe_voice.h
-- Looking for include file awe_voice.h - not found
-- Looking for include file /usr/src/sys/i386/isa/sound/awe_voice.h
-- Looking for include file /usr/src/sys/i386/isa/sound/awe_voice.h - not found
-- Looking for include file /usr/src/sys/gnu/i386/isa/sound/awe_voice.h
-- Looking for include file /usr/src/sys/gnu/i386/isa/sound/awe_voice.h - not found
-- Looking for C++ include sys/asoundlib.h
-- Looking for C++ include sys/asoundlib.h - found
-- Looking for C++ include alsa/asoundlib.h
-- Looking for C++ include alsa/asoundlib.h - found
-- Looking for snd_pcm_resume in asound
-- Looking for snd_pcm_resume in asound - found
-- Checking for module 'jack>=0.77'
--   Found jack, version 1.9.10
-- Checking for module 'fftw3f>=3.0.0'
--   Found fftw3f, version 3.3.4
-- Found OpenGL: /usr/lib64/libGL.so  
-- Looking for XOpenDisplay in /usr/lib64/libX11.so;/usr/lib64/libXext.so
-- Looking for XOpenDisplay in /usr/lib64/libX11.so;/usr/lib64/libXext.so - found
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for connect
-- Looking for connect - found
-- Looking for remove
-- Looking for remove - found
-- Looking for shmat
-- Looking for shmat - found
-- Looking for IceConnectionNumber in ICE
-- Looking for IceConnectionNumber in ICE - found
-- Found X11: /usr/lib64/libX11.so
-- Found FLTK: /usr/lib64/fltk/libfltk_images.so;/usr/lib64/fltk/libfltk_forms.so;/usr/lib64/fltk/libfltk_gl.so;/usr/lib64/libGL.so;/usr/lib64/fltk/libfltk.so  
-- Checking for module 'fluidsynth>=1.0.7'
--   Found fluidsynth, version 1.1.6
-- Checking for module 'gig'
--   Found gig, version 4.0.0
-- Could NOT find Wine (missing:  WINE_LIBRARIES) 
-- Checking for module 'samplerate>=0.1.8'
--   Found samplerate, version 0.1.8
-- Setting build type to 'Release' as none was specified.
-- Found Doxygen: /usr/bin/doxygen (found version "1.8.13") 

Installation Summary
--------------------
* Install Directory           : /usr/local

Supported audio interfaces
--------------------------
* ALSA                        : OK
* JACK                        : OK (weak linking enabled)
* OSS                         : OK
* Sndio                       : 
* PortAudio                   : OK
* libsoundio                  : not found, please install libsoundio if you require libsoundio support
* PulseAudio                  : OK
* SDL                         : OK

Supported MIDI interfaces
-------------------------
* ALSA                        : OK
* OSS                         : OK
* Sndio                       : 
* JACK                        : OK (weak linking enabled)
* WinMM                       : <not supported on this platform>
* AppleMidi                   : <not supported on this platform>

Supported file formats for project export
-----------------------------------------
* WAVE                        : OK
* OGG/VORBIS                  : OK
* MP3/Lame                    : OK

Optional plugins
----------------
* Carla Patchbay & Rack       : OK
* SoundFont2 player           : OK
* Stk Mallets                 : not found, please install libstk0-dev (or similar) ;if you require the Mallets instrument
* VST-instrument hoster       : not found, please install (lib)wine-dev (or similar) - 64 bit systems additionally need gcc-multilib and g++-multilib
* VST-effect hoster           : not found, please install (lib)wine-dev (or similar) - 64 bit systems additionally need gcc-multilib and g++-multilib
* CALF LADSPA plugins         : OK
* CAPS LADSPA plugins         : OK
* CMT LADSPA plugins          : OK
* TAP LADSPA plugins          : OK
* SWH LADSPA plugins          : OK
* GIG player                  : OK


-----------------------------------------------------------------
IMPORTANT:
after installing missing packages, remove CMakeCache.txt before
running cmake again!
-----------------------------------------------------------------



-- Configuring done
CMake Error at src/3rdparty/rpmalloc/CMakeLists.txt:3 (add_library):
  Cannot find source file:

    rpmalloc/rpmalloc/rpmalloc.c

  Tried extensions .c .C .c++ .cc .cpp .cxx .m .M .mm .h .hh .h++ .hm .hpp
  .hxx .in .txx


CMake Error: Cannot determine link language for target "rpmalloc".
CMake Error: CMake can not determine linker language for target: rpmalloc

I want VST support, which is precisely why I am willing to clone the git source and compile from there instead of emerging "media-sound/lmms" (which doesn't have VST support). Will this be remedied eventually? Or do I have to manually symlink?

By the way, I have "=app-emulation/wine-vanilla-2.0.3" and "=app-emulation/wine-vanilla-2.20"

@lukas-w
Copy link
Member

lukas-w commented Jan 14, 2018

@Metalhead33 Instead of symlinking, you can try passing -DCMAKE_PREFIX_PATH=/path/to/your/wine to CMake.

Did the location of Wine on the file system change with those packaging changes? If so, where to? Maybe we can add that path to our FindWine.cmake script.

@Metalhead33
Copy link
Author

Metalhead33 commented Jan 14, 2018

@lukas-w Thank you! Both "cmake .. -DCMAKE_PREFIX_PATH=/usr/lib/wine-vanilla-2.20" and "cmake .. -DCMAKE_PREFIX_PATH=/usr/lib/wine-vanilla-2.0.3" worked fine (at least as far as executing cmake and making it recognize wine, didn't try compiling yet).
But yes, it now packs wine into its own individual folders per version, like the ones I listed previously. Also, there is now "/usr/include/wine-vanilla-2.0.3/wine" and "/usr/include/wine-vanilla-2.20/wine" instead of the previous "/usr/include/wine".
There exists wine-vanilla, wine-staging and wine-d3d, all three of them constantly being updated at a separate pace.

@Metalhead33
Copy link
Author

Metalhead33 commented Jan 14, 2018

Aaaaaand, error!

[ 83%] Generating moc_VstPlugin.cxx
[ 83%] Generating ../RemoteVstPlugin
x86_64-pc-linux-gnu-ld: Relocatable linking with relocations from format elf64-x86-64 (/usr/lib64/wine-vanilla-2.20/wine/libwinecrt0.a(exe_entry.o)) to format elf32-i386 (RemoteVstPlugin.gH5dp8.o) is not supported
winebuild: x86_64-pc-linux-gnu-ld failed with status 1
winegcc: winebuild failed
make[2]: *** [plugins/vst_base/CMakeFiles/vstbase.dir/build.make:63: plugins/RemoteVstPlugin] Error 2
make[1]: *** [CMakeFiles/Makefile2:8028: plugins/vst_base/CMakeFiles/vstbase.dir/all] Error 2
make: *** [Makefile:150: all] Error 2

Maybe if I tried with "cmake .. -DCMAKE_PREFIX_PATH=/usr/lib32/wine-vanilla-2.20" intead of "cmake .. -DCMAKE_PREFIX_PATH=/usr/lib/wine-vanilla-2.20"?

Edit: Nope, even with that command, the same error happens.

@lukas-w lukas-w changed the title Wine not detected Wine not detected on Gentoo Jan 14, 2018
@lukas-w
Copy link
Member

lukas-w commented Jan 14, 2018

@Metalhead33 That's a known bug with winegcc. It automatically links to 64bit libraries even when building 32bit binaries using the -m32 flag.

What's the output of winegcc -v -m32 /dev/zero on your system?

@Metalhead33
Copy link
Author

I have found a temporary workaround:

/tmp/lmms/plugins/vst_base/CMakeLists.txt:

IF(LMMS_SUPPORT_VST)

INCLUDE(BuildPlugin)

IF(LMMS_BUILD_WIN32)
	ADD_DEFINITIONS(-DPTW32_STATIC_LIB)
	ADD_EXECUTABLE(RemoteVstPlugin "${CMAKE_CURRENT_SOURCE_DIR}/RemoteVstPlugin.cpp")

	IF(QT5)
		TARGET_LINK_LIBRARIES(RemoteVstPlugin Qt5::Core)
	ELSE()
		TARGET_LINK_LIBRARIES(RemoteVstPlugin -lQtCore4)
	ENDIF()
	TARGET_LINK_LIBRARIES(RemoteVstPlugin -lpthread -lgdi32 -lws2_32)
	SET_TARGET_PROPERTIES(RemoteVstPlugin PROPERTIES COMPILE_FLAGS "${COMPILE_FLAGS} -O0")
	ADD_CUSTOM_COMMAND(TARGET RemoteVstPlugin POST_BUILD COMMAND "${STRIP}" "$<TARGET_FILE:RemoteVstPlugin>")
	INSTALL(TARGETS RemoteVstPlugin RUNTIME DESTINATION "${PLUGIN_DIR}")

	# FIXME: 32-bit VST fails on MSYS
	IF(LMMS_BUILD_WIN64 AND NOT LMMS_BUILD_MSYS)
		# build 32 bit version of RemoteVstPlugin for Win64 so we can load
		# 32 bit VST plugins
		ADD_SUBDIRECTORY(Win64)
	ENDIF(LMMS_BUILD_WIN64 AND NOT LMMS_BUILD_MSYS)
ENDIF(LMMS_BUILD_WIN32)

SET(REMOTE_VST_PLUGIN_FILEPATH "RemoteVstPlugin" CACHE STRING "Relative file path to RemoteVstPlugin")

ADD_DEFINITIONS(-DREMOTE_VST_PLUGIN_FILEPATH="${REMOTE_VST_PLUGIN_FILEPATH}")
BUILD_PLUGIN(vstbase vst_base.cpp VstPlugin.cpp VstPlugin.h communication.h MOCFILES VstPlugin.h)

IF(LMMS_BUILD_LINUX AND WANT_QT5)
	TARGET_LINK_LIBRARIES(vstbase qx11embedcontainer)
ENDIF()

IF(LMMS_BUILD_LINUX AND NOT WANT_VST_NOWINE)

IF(LMMS_HOST_X86_64)
	SET(EXTRA_FLAGS -m32)
	SET(EXTRA_FLAGS ${EXTRA_FLAGS} -nodefaultlibs /usr/lib32/wine-vanilla-2.20/wine/libwinecrt0.a -L/usr/lib32/wine-vanilla-2.20/wine/ -luser32 -lkernel32 -lgdi32)
ENDIF(LMMS_HOST_X86_64)

SET(WINE_CXX_FLAGS "" CACHE STRING "Extra flags passed to wineg++")

STRING(REPLACE "include/wine" "include" WINE_INCLUDE_BASE_DIR ${WINE_INCLUDE_DIR})
STRING(REPLACE "lib/libwine.so" "lib" WINE_LIBRARY_DIR ${WINE_LIBRARY})
STRING(REPLACE " " ";" WINE_BUILD_FLAGS ${CMAKE_CXX_FLAGS} " " ${CMAKE_EXE_LINKER_FLAGS} " " ${WINE_CXX_FLAGS})

SET(WINE_CXX_ARGS
	-I${CMAKE_BINARY_DIR}
	-I${CMAKE_SOURCE_DIR}/include
	-I${WINE_INCLUDE_BASE_DIR}
	-L${WINE_LIBRARY_DIR}
	${CMAKE_CURRENT_SOURCE_DIR}/RemoteVstPlugin.cpp
	-std=c++0x
	-mwindows -lpthread ${EXTRA_FLAGS} -fno-omit-frame-pointer
	${WINE_BUILD_FLAGS}
	-o ../RemoteVstPlugin
)

# winegcc fails if winebuild is not in path
GET_FILENAME_COMPONENT(WINE_BINDIR ${WINE_CXX} PATH)
FIND_PROGRAM(WINEBUILD winebuild NO_CMAKE_PATH NO_CMAKE_ENVIRONMENT_PATH NO_CMAKE_SYSTEM_PATH)
IF(NOT WINEBUILD)
	IF(CMAKE_VERSION VERSION_LESS 3.1)
		MESSAGE(WARNING "winebuild is not in PATH. Building RemoteVstPlugin may fail.")
	ELSE()
		SET(WINE_CXX_ARGS -E env PATH=$ENV{PATH}:${WINE_BINDIR} ${WINE_CXX} ${WINE_CXX_ARGS})
		SET(WINE_CXX "${CMAKE_COMMAND}")
	ENDIF()
ENDIF()

set(ENV{PATH} "$ENV{PATH}:${WINE_BINDIR}")

ADD_CUSTOM_COMMAND(
	SOURCE "${CMAKE_CURRENT_SOURCE_DIR}/RemoteVstPlugin.cpp"
	COMMAND export
		ARGS "PATH=$PATH:${WINE_BINDIR}"
	COMMAND ${WINE_CXX}
	ARGS ${WINE_CXX_ARGS}
	# Ensure correct file extension
	COMMAND sh -c "mv ../RemoteVstPlugin.exe ../RemoteVstPlugin || true"
	TARGET vstbase
	OUTPUTS ../RemoteVstPlugin
	VERBATIM
)

SET_DIRECTORY_PROPERTIES(PROPERTIES ADDITIONAL_MAKE_CLEAN_FILES ../RemoteVstPlugin.exe.so)
INSTALL(PROGRAMS "${CMAKE_CURRENT_BINARY_DIR}/../RemoteVstPlugin" "${CMAKE_CURRENT_BINARY_DIR}/../RemoteVstPlugin.exe.so" DESTINATION "${PLUGIN_DIR}")
ENDIF(LMMS_BUILD_LINUX AND NOT WANT_VST_NOWINE)


ENDIF(LMMS_SUPPORT_VST)

/tmp/lmms/cmake/modules/FindWine.cmake:

# - Try to find the wine libraries
# Once done this will define
#
#  WINE_FOUND - System has wine
#  WINE_INCLUDE_DIRS - The wine include directories
#  WINE_LIBRARIES - The libraries needed to use wine
#  WINE_DEFINITIONS - Compiler switches required for using wine
#

LIST(APPEND CMAKE_PREFIX_PATH /opt/wine-stable /opt/wine-devel /opt/wine-staging)

FIND_PATH(WINE_INCLUDE_DIR windows/windows.h PATH_SUFFIXES wine)
FIND_LIBRARY(WINE_LIBRARY NAMES wine PATH_SUFFIXES wine i386-linux-gnu/wine)
FIND_PROGRAM(WINE_CXX NAMES wineg++ winegcc winegcc64 winegcc32)

set(WINE_INCLUDE_DIRS "/usr/include/wine-vanilla-2.20/wine")
set(WINE_INCLUDE_DIR "/usr/include/wine-vanilla-2.20/wine")
set(WINE_LIBRARIES "/usr/lib32/wine-vanilla-2.20")
set(WINE_LIBRARY "/usr/lib32/wine-vanilla-2.20")
# set(WINE_LIBRARY_FIX "/usr/lib32/")
set(WINE_FOUND true)

include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(Wine DEFAULT_MSG WINE_LIBRARIES WINE_INCLUDE_DIRS)
mark_as_advanced(WINE_INCLUDE_DIR WINE_LIBRARY)

@Metalhead33
Copy link
Author

@lukas-w
This:

➜  build git:(stable-1.2) ✗ winegcc -v -m32 /dev/zero
x86_64-pc-linux-gnu-gcc -m64 -m32 -fshort-wchar -DWINE_UNICODE_NATIVE -D_REENTRANT -fPIC -DWIN32 -D_WIN32 -D__WIN32 -D__WIN32__ -D__WINNT -D__WINNT__ -D__stdcall=__attribute__((__stdcall__)) __attribute__((__force_align_arg_pointer__)) -D__cdecl=__attribute__((__cdecl__)) __attribute__((__force_align_arg_pointer__)) -D_stdcall=__attribute__((__stdcall__)) __attribute__((__force_align_arg_pointer__)) -D_cdecl=__attribute__((__cdecl__)) __attribute__((__force_align_arg_pointer__)) -D__fastcall=__attribute__((__fastcall__)) -D_fastcall=__attribute__((__fastcall__)) -D__declspec(x)=__declspec_##x -D__declspec_align(x)=__attribute__((aligned(x))) -D__declspec_allocate(x)=__attribute__((section(x))) -D__declspec_deprecated=__attribute__((deprecated)) -D__declspec_dllimport=__attribute__((dllimport)) -D__declspec_dllexport=__attribute__((dllexport)) -D__declspec_naked=__attribute__((naked)) -D__declspec_noinline=__attribute__((noinline)) -D__declspec_noreturn=__attribute__((noreturn)) -D__declspec_nothrow=__attribute__((nothrow)) -D__declspec_novtable=__attribute__(()) -D__declspec_selectany=__attribute__((weak)) -D__declspec_thread=__thread -D__int8=char -D__int16=short -D__int32=int -D__int64=long long -D__WINE__ -c -o zero-puO7Vv.o -v -m32 /dev/zero -isystem/usr/include/wine-vanilla-2.0.3/wine/windows 
Using built-in specs.
COLLECT_GCC=x86_64-pc-linux-gnu-gcc
Target: x86_64-pc-linux-gnu
Configured with: /home/legacy/porttmp/portage/sys-devel/gcc-7.2.0/work/gcc-7.2.0/configure --host=x86_64-pc-linux-gnu --build=x86_64-pc-linux-gnu --prefix=/usr --bindir=/usr/x86_64-pc-linux-gnu/gcc-bin/7.2.0 --includedir=/usr/lib/gcc/x86_64-pc-linux-gnu/7.2.0/include --datadir=/usr/share/gcc-data/x86_64-pc-linux-gnu/7.2.0 --mandir=/usr/share/gcc-data/x86_64-pc-linux-gnu/7.2.0/man --infodir=/usr/share/gcc-data/x86_64-pc-linux-gnu/7.2.0/info --with-gxx-include-dir=/usr/lib/gcc/x86_64-pc-linux-gnu/7.2.0/include/g++-v7 --with-python-dir=/share/gcc-data/x86_64-pc-linux-gnu/7.2.0/python --enable-languages=c,c++,fortran --enable-obsolete --enable-secureplt --disable-werror --with-system-zlib --enable-nls --without-included-gettext --enable-checking=release --with-bugurl=https://bugs.gentoo.org/ --with-pkgversion='Gentoo 7.2.0 p1.1' --disable-esp --enable-libstdcxx-time --enable-shared --enable-threads=posix --enable-__cxa_atexit --enable-clocale=gnu --enable-multilib --with-multilib-list=m32,m64 --disable-altivec --disable-fixed-point --enable-targets=all --disable-libgcj --enable-libgomp --disable-libmudflap --disable-libssp --disable-libcilkrts --disable-libmpx --enable-vtable-verify --enable-libvtv --enable-lto --without-isl --enable-libsanitizer --disable-default-pie --enable-default-ssp
Thread model: posix
gcc version 7.2.0 (Gentoo 7.2.0 p1.1) 
COMPILER_PATH=/usr/libexec/gcc/x86_64-pc-linux-gnu/7.2.0/:/usr/libexec/gcc/x86_64-pc-linux-gnu/7.2.0/:/usr/libexec/gcc/x86_64-pc-linux-gnu/:/usr/lib/gcc/x86_64-pc-linux-gnu/7.2.0/:/usr/lib/gcc/x86_64-pc-linux-gnu/:/usr/lib/gcc/x86_64-pc-linux-gnu/7.2.0/../../../../x86_64-pc-linux-gnu/bin/
LIBRARY_PATH=/usr/lib/gcc/x86_64-pc-linux-gnu/7.2.0/32/:/usr/lib/gcc/x86_64-pc-linux-gnu/7.2.0/../../../../lib32/:/lib/../lib32/:/usr/lib/../lib32/:/usr/lib/gcc/x86_64-pc-linux-gnu/7.2.0/:/usr/lib/gcc/x86_64-pc-linux-gnu/7.2.0/../../../../x86_64-pc-linux-gnu/lib/:/usr/lib/gcc/x86_64-pc-linux-gnu/7.2.0/../../../:/lib/:/usr/lib/
COLLECT_GCC_OPTIONS='-fshort-wchar' '-D' 'WINE_UNICODE_NATIVE' '-D' '_REENTRANT' '-fPIC' '-D' 'WIN32' '-D' '_WIN32' '-D' '__WIN32' '-D' '__WIN32__' '-D' '__WINNT' '-D' '__WINNT__' '-D' '__stdcall=__attribute__((__stdcall__)) __attribute__((__force_align_arg_pointer__))' '-D' '__cdecl=__attribute__((__cdecl__)) __attribute__((__force_align_arg_pointer__))' '-D' '_stdcall=__attribute__((__stdcall__)) __attribute__((__force_align_arg_pointer__))' '-D' '_cdecl=__attribute__((__cdecl__)) __attribute__((__force_align_arg_pointer__))' '-D' '__fastcall=__attribute__((__fastcall__))' '-D' '_fastcall=__attribute__((__fastcall__))' '-D' '__declspec(x)=__declspec_##x' '-D' '__declspec_align(x)=__attribute__((aligned(x)))' '-D' '__declspec_allocate(x)=__attribute__((section(x)))' '-D' '__declspec_deprecated=__attribute__((deprecated))' '-D' '__declspec_dllimport=__attribute__((dllimport))' '-D' '__declspec_dllexport=__attribute__((dllexport))' '-D' '__declspec_naked=__attribute__((naked))' '-D' '__declspec_noinline=__attribute__((noinline))' '-D' '__declspec_noreturn=__attribute__((noreturn))' '-D' '__declspec_nothrow=__attribute__((nothrow))' '-D' '__declspec_novtable=__attribute__(())' '-D' '__declspec_selectany=__attribute__((weak))' '-D' '__declspec_thread=__thread' '-D' '__int8=char' '-D' '__int16=short' '-D' '__int32=int' '-D' '__int64=long long' '-D' '__WINE__' '-c' '-o' 'zero-puO7Vv.o' '-v' '-m32' '-isystem' '/usr/include/wine-vanilla-2.0.3/wine/windows' '-mtune=generic' '-march=x86-64'
x86_64-pc-linux-gnu-gcc: warning: /dev/zero: linker input file unused because linking not done
winebuild -v -fno-asynchronous-unwind-tables --cc-cmd=x86_64-pc-linux-gnu-gcc -m64 --ld-cmd=x86_64-pc-linux-gnu-ld -m32 -D_REENTRANT -fPIC --exe -o a.out-eZ23wV.spec.o -F a.out --subsystem console -L/usr/lib64/wine-vanilla-2.0.3/wine -L/usr/lib64/wine-vanilla-2.0.3 -- zero-puO7Vv.o /usr/lib64/wine-vanilla-2.0.3/wine/libadvapi32.def /usr/lib64/wine-vanilla-2.0.3/wine/libuser32.def /usr/lib64/wine-vanilla-2.0.3/wine/libwinecrt0.a /usr/lib64/wine-vanilla-2.0.3/wine/libkernel32.def /usr/lib64/wine-vanilla-2.0.3/wine/libntdll.def 
winebuild: zero-puO7Vv.o is an empty file
winegcc: winebuild failed

@tresf tresf reopened this Jan 14, 2018
@tresf
Copy link
Member

tresf commented Jan 14, 2018

Reopening because this is likely something we can improve upon.

@vrghost242
Copy link

vrghost242 commented Jan 19, 2018

So tried this, seemed to work (thank you Metalhead33), but now getting

[ 66%] Building CXX object plugins/vst_base/CMakeFiles/vstbase.dir/VstPlugin.cpp.o
/mnt/stripe/media/lmmsbuild/lmms/plugins/vst_base/VstPlugin.cpp:41:33: fatal error: X11EmbedContainer.h: No such file or directory
 #  include "X11EmbedContainer.h"
                                 ^
compilation terminated.
make[2]: *** [plugins/vst_base/CMakeFiles/vstbase.dir/build.make:97: plugins/vst_base/CMakeFiles/vstbase.dir/VstPlugin.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:8072: plugins/vst_base/CMakeFiles/vstbase.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 66%] Building CXX object plugins/watsyn/CMakeFiles/watsyn.dir/moc_Watsyn.cpp.o

Not certain where X11EmbedContainer.h comes from, any idea? (Using Gentoo as well, relatively up to date system, and using Wine 2.0.3

@tresf
Copy link
Member

tresf commented Feb 16, 2018

Not certain where X11EmbedContainer.h comes from, any idea? (Using Gentoo as well, relatively up to date system, and using Wine 2.0.3

@PhysSong explains this in #4124. Assuming you're on master, this was fixed in 5c3c052.

I have found a temporary workaround:

@Metalhead33 can you see if this patch helps? bdfb26a Edit: b28d159 Instead of hard-coding a bunch of volatile os-dependant paths, I've switched the logic to a search/replace which should scale better to various Linux distros.

tresf added a commit to tresf/lmms that referenced this issue Feb 16, 2018
tresf added a commit that referenced this issue Feb 23, 2018
@tresf
Copy link
Member

tresf commented Mar 6, 2018

@Metalhead33 final bump on this. It's already merged, but we'd love to know this platform is supported. I gave up trying to setup a Gentoo build environment so we'll have to defer this to someone more comfortable with the platform.

@PhysSong
Copy link
Member

PhysSong commented Mar 9, 2019

FYI, I found that Gentoo supports two different multilib layouts. That may not be an issue because Wine 3.21 fixes the linking issue: wine-mirror/wine@2dfff7e
However, I still believe the moudule won't be able to find WINE_INCLUDE_DIR and WINE_LIBRARY because they are not in the default search directory. I think the output of winegcc may useful for detecting them.

sdasda7777 pushed a commit to sdasda7777/lmms that referenced this issue Jun 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants