From: Good Guy Date: Mon, 16 Sep 2019 01:07:51 +0000 (-0600) Subject: disable inline mmx for clang builds X-Git-Tag: 2019-09~7 X-Git-Url: https://git.cinelerra-gg.org/git/?a=commitdiff_plain;h=a2ebbc5e88800bd740652a32285f8145a1acfdc6;p=goodguy%2Fcinelerra.git disable inline mmx for clang builds --- diff --git a/cinelerra-5.1/guicast/bcwindowbase.C b/cinelerra-5.1/guicast/bcwindowbase.C index 1ff14928..1f1d0d30 100644 --- a/cinelerra-5.1/guicast/bcwindowbase.C +++ b/cinelerra-5.1/guicast/bcwindowbase.C @@ -460,8 +460,16 @@ int BC_WindowBase::create_window(BC_WindowBase *parent_window, const char *title vis = get_glx_visual(display); if( !vis ) #endif + { + int mask = VisualDepthMask | VisualClassMask; + static XVisualInfo vinfo = { .depth = 24, .c_class = DirectColor, }; + int nitems = 0; + XVisualInfo *vis_info = XGetVisualInfo(display, mask, &vinfo, &nitems); + vis = vis_info && nitems>0 ? vis_info[0].visual : 0; + if( vis_info ) XFree(vis_info); + } + if( !vis ) vis = DefaultVisual(display, screen); - default_depth = DefaultDepth(display, screen); client_byte_order = (*(const u_int32_t*)"a ") & 0x00000001; diff --git a/cinelerra-5.1/libzmpeg3/Makefile b/cinelerra-5.1/libzmpeg3/Makefile index b256c736..aeade023 100644 --- a/cinelerra-5.1/libzmpeg3/Makefile +++ b/cinelerra-5.1/libzmpeg3/Makefile @@ -3,7 +3,8 @@ include $(TOPDIR)/global_config ifneq ($(WANT_LIBZMPEG),no) -CC = gcc +# for mmx inlines +#CC = gcc NASM = nasm USE_MMX ?= 0 DYNAMIC_FONTS ?= 1 diff --git a/cinelerra-5.1/libzmpeg3/video/reconstruct.C b/cinelerra-5.1/libzmpeg3/video/reconstruct.C index 9cc819fc..1977d3be 100644 --- a/cinelerra-5.1/libzmpeg3/video/reconstruct.C +++ b/cinelerra-5.1/libzmpeg3/video/reconstruct.C @@ -1,8 +1,10 @@ #include "../libzmpeg3.h" +#ifndef __clang__ #ifdef __x86_64__ #define USE_MMX #endif +#endif #define MMX_ACCURATE #ifdef USE_MMX diff --git a/cinelerra-5.1/libzmpeg3/video/slice.C b/cinelerra-5.1/libzmpeg3/video/slice.C index b880f7ff..8bb238eb 100644 --- a/cinelerra-5.1/libzmpeg3/video/slice.C +++ b/cinelerra-5.1/libzmpeg3/video/slice.C @@ -1,8 +1,10 @@ #include "../libzmpeg3.h" +#ifndef __clang__ #ifdef __x86_64__ #define USE_MMX #endif +#endif #ifdef USE_MMX #include "mmx.h" #if defined(__x86_64__)