Re: [Cin] more patches for building on my slackware
right now I use those patches and Slackbuild for compiling on my x86 slackware... change from J to X was inspired by libdv patch doing reverse of this for gcc 4.1: https://sourceforge.net/p/libdv/mailman/message/2320559/ I also tried 'n' but build was failing too .. some description for those constraints: https://www.ibiblio.org/gferg/ldp/GCC-Inline-Assembly-HOWTO.html#s6 On Saturday, April 16, 2022, Andrew Randrianasulu wrote: > hold on, I am not sure what going on - I tried again with slightly > modified cin.Slackbuild and build was failing again until I replaced 'i' > with 'X' (anything goes here asm constrain). > > it seems to work afterwards - mpeg 2 / 4:2:2 encoding working at 7.5 fps > for fullhd vid.. but I want to double-check (uname -m must return i686 for > this code to even compile...) > > On Friday, April 15, 2022, Andrew Randrianasulu > wrote: > >> sorry, there was 4th patch >> >> On Friday, April 15, 2022, Andrew Randrianasulu >> wrote: >> >>> due to X libs/headers located in /usr/X11R7... >>> >>> but also due to some asm error in mpeg2enc when I build for i686 >>> target... >>> >>> http://forum.tinycorelinux.net/index.php/topic,18142.0.html? >>> PHPSESSID=cd4712cf278ad777dc1c3a2356e0bf9d >>> >>> >>> >>> I added -fomit-frame-pointer to only mpeg2enc cflags and it compiled... >>> not sure why I was not hit by this earlier, may be because I already had >>> this in cflags? >>> >>> >>> From d65312b7a0efcca01c60a5d3f5e2043ab14b1932 Mon Sep 17 00:00:00 2001 From: Andrew Randrianasulu Date: Fri, 15 Apr 2022 18:35:56 +0300 Subject: [PATCH 1/3] fix x11 linking in libzmpeg3 on my system --- cinelerra-5.1/libzmpeg3/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cinelerra-5.1/libzmpeg3/Makefile b/cinelerra-5.1/libzmpeg3/Makefile index b92a33b..d854fa9 100644 --- a/cinelerra-5.1/libzmpeg3/Makefile +++ b/cinelerra-5.1/libzmpeg3/Makefile @@ -89,7 +89,7 @@ endif LIBS += $(lib_a52dec) $(lib_djbfft) $(lib_libbthread) ifeq ($(DYNAMIC_FONTS), 1) -LIBS += -lX11 +LIBS += -lX11 `pkg-config --libs x11` else CFLAGS += -DBUILTIN_FONT_DATA OBJS += $(OBJDIR)/xfont1.o -- 2.14.5 From 48679d63a68637195acf14fff706c613f17d7e50 Mon Sep 17 00:00:00 2001 From: Andrew Randrianasulu Date: Fri, 15 Apr 2022 18:37:32 +0300 Subject: [PATCH 2/3] Fix i686 build on gcc 5 --- cinelerra-5.1/mpeg2enc/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cinelerra-5.1/mpeg2enc/Makefile b/cinelerra-5.1/mpeg2enc/Makefile index 54fd1a3..f517e52 100644 --- a/cinelerra-5.1/mpeg2enc/Makefile +++ b/cinelerra-5.1/mpeg2enc/Makefile @@ -7,7 +7,7 @@ CC = gcc CFLAGS += -I$(TOPDIR)/libzmpeg3 ifeq ($(OBJDIR), i686) -CFLAGS += -DX86_CPU +CFLAGS += -DX86_CPU -march=i686 -mcpu=i686 -fomit-frame-pointer NASMOBJ = \ $(OBJDIR)/bdist1_mmx.o \ $(OBJDIR)/bdist2_mmx.o \ -- 2.14.5 From 7d049f50f9b9f28feab876dc2043fa1cbddae221 Mon Sep 17 00:00:00 2001 From: Andrew Randrianasulu Date: Fri, 15 Apr 2022 18:38:17 +0300 Subject: [PATCH 3/3] fix libva libs for internal ffmpeg on my machine --- cinelerra-5.1/configure.ac | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cinelerra-5.1/configure.ac b/cinelerra-5.1/configure.ac index 37607b1..1b064d3 100644 --- a/cinelerra-5.1/configure.ac +++ b/cinelerra-5.1/configure.ac @@ -1079,12 +1079,12 @@ fi FFMPEG_EXTRA_LDFLAGS="" if test "x$WANT_VAAPI" != "xno" -a "x$HAVE_VAAPI" = "xyes"; then - FFMPEG_EXTRA_LDFLAGS+=' -lva' - EXTRA_LIBS+=' -lva' + FFMPEG_EXTRA_LDFLAGS+=' -lva `pkg-config --libs libva`' + EXTRA_LIBS+=' -lva ' WANT_VAAPI="yes" if test "x$HAVE_vaapi_x11" = "xyes"; then FFMPEG_EXTRA_LDFLAGS+=' -lva-x11' -EXTRA_LIBS+=' -lva-x11' +EXTRA_LIBS+=' -lva-x11 `pkg-config --libs x11`' fi if test "x$HAVE_vaapi_drm" = "xyes"; then FFMPEG_EXTRA_LDFLAGS+=' -lva-drm' -- 2.14.5 diff --git a/cinelerra-5.1/mpeg2enc/mmx.h b/cinelerra-5.1/mpeg2enc/mmx.h index c78e185..bb3c191 100644 --- a/cinelerra-5.1/mpeg2enc/mmx.h +++ b/cinelerra-5.1/mpeg2enc/mmx.h @@ -43,7 +43,7 @@ typedef union { #define mmx_si2r(op,imm,reg) \ __asm__ __volatile__ (#op " %0, %%" #reg \ : /* nothing */ \ - : "J" (imm) ) + : "X" (imm) ) #define mmx_m2r(op,mem,reg) \ __asm__ __volatile__ (#op " %0, %%" #reg \ cin.SlackBuild Description: Binary data -- Cin mailing list Cin@lists.cinelerra-gg.org https://lists.cinelerra-gg.org/mailman/listinfo/cin
Re: [Cin] opencv build trim
on topic of opencv I instalked opencv 4.5.5 on termux and tried to build cingg plugins against this. most plugins worked with hack - but for some reason final link faild to add opencv libs (no pkgconfig for them, it seems?) and so resulted plugins aborted cin on load. hack: $ git diff thirdparty/Makefile plugins/Makefile diff --git a/cinelerra-5.1/plugins/Makefile b/cinelerra-5.1/plugins/Makefile index e6718432..cb3a10e8 100644 --- a/cinelerra-5.1/plugins/Makefile +++ b/cinelerra-5.1/plugins/Makefile @@ -8,7 +8,8 @@ endif ifneq ($(WANT_OPENCV), no) want_var:=$(WANT_OPENCV) include $(TOPDIR)/opencv_build -OPENCV_OBJS := findobj flowobj gaborobj moveobj stylizeobj puzzleobj +#OPENCV_OBJS := findobj flowobj gaborobj moveobj stylizeobj puzzleobj +OPENCV_OBJS := flowobj gaborobj moveobj stylizeobj findobj $(OPENCV_OBJS): opencv endif ifneq ($(WANT_CUDA), no) err, not all changes... $ git diff thirdparty/Makefile plugins/Makefile plugins diff --git a/cinelerra-5.1/plugins/Makefile b/cinelerra-5.1/plugins/Makefile index e6718432..cb3a10e8 100644 --- a/cinelerra-5.1/plugins/Makefile +++ b/cinelerra-5.1/plugins/Makefile @@ -8,7 +8,8 @@ endif ifneq ($(WANT_OPENCV), no) want_var:=$(WANT_OPENCV) include $(TOPDIR)/opencv_build -OPENCV_OBJS := findobj flowobj gaborobj moveobj stylizeobj puzzleobj +#OPENCV_OBJS := findobj flowobj gaborobj moveobj stylizeobj puzzleobj +OPENCV_OBJS := flowobj gaborobj moveobj stylizeobj findobj $(OPENCV_OBJS): opencv endif ifneq ($(WANT_CUDA), no) diff --git a/cinelerra-5.1/plugins/findobj/findobj.h b/cinelerra-5.1/plugins/findobj/findobj.h index 2bea44af..541e9e6f 100644 --- a/cinelerra-5.1/plugins/findobj/findobj.h +++ b/cinelerra-5.1/plugins/findobj/findobj.h @@ -50,7 +50,7 @@ #include "opencv2/core/types.hpp" #include "opencv2/core/mat.hpp" #include "opencv2/imgproc/imgproc.hpp" -#include "opencv2/xfeatures2d.hpp" +#include "opencv2/features2d.hpp" #include "opencv2/calib3d.hpp" #include "opencv2/flann/defines.h" #include "opencv2/flann/params.h" @@ -60,7 +60,7 @@ using namespace std; using namespace cv; -using namespace cv::xfeatures2d; +//using namespace cv::xfeatures2d; using namespace cvflann; // enabled detectors diff --git a/cinelerra-5.1/plugins/puzzleobj/puzzleobj.h b/cinelerra-5.1/plugins/puzzleobj/puzzleobj.h index 197522f3..ebfe1881 100644 --- a/cinelerra-5.1/plugins/puzzleobj/puzzleobj.h +++ b/cinelerra-5.1/plugins/puzzleobj/puzzleobj.h @@ -28,7 +28,7 @@ #include "opencv2/core/mat.hpp" #include "opencv2/calib3d.hpp" #include "opencv2/photo.hpp" -#include "opencv2/ximgproc.hpp" +#include "opencv2/imgproc.hpp" #include "opencv2/video/video.hpp" #include @@ -36,7 +36,7 @@ using namespace std; using namespace cv; -using namespace cv::ximgproc; +//using namespace cv::ximgproc; class PuzzleObjConfig; class PuzzleObj; (END) === puzzleobj failed to build anyway, so I commented it out. may be on more standart Linux dynamuc/system build with this hack still will work (produce usable plugins?) On Saturday, April 16, 2022, Andrew Randrianasulu wrote: > https://github.com/Randrianasulu/CinelerraGG-slackbuild/blob/master/ > openCV4-static-gcc5_more-disable-3.diff > > basically re-applied locally because opencv build eats a bit too much > space... > > > -- Cin mailing list Cin@lists.cinelerra-gg.org https://lists.cinelerra-gg.org/mailman/listinfo/cin
Re: [Cin] more patches for building on my slackware
hold on, I am not sure what going on - I tried again with slightly modified cin.Slackbuild and build was failing again until I replaced 'i' with 'X' (anything goes here asm constrain). it seems to work afterwards - mpeg 2 / 4:2:2 encoding working at 7.5 fps for fullhd vid.. but I want to double-check (uname -m must return i686 for this code to even compile...) On Friday, April 15, 2022, Andrew Randrianasulu wrote: > sorry, there was 4th patch > > On Friday, April 15, 2022, Andrew Randrianasulu > wrote: > >> due to X libs/headers located in /usr/X11R7... >> >> but also due to some asm error in mpeg2enc when I build for i686 >> target... >> >> http://forum.tinycorelinux.net/index.php/topic,18142.0.html? >> PHPSESSID=cd4712cf278ad777dc1c3a2356e0bf9d >> >> >> >> I added -fomit-frame-pointer to only mpeg2enc cflags and it compiled... >> not sure why I was not hit by this earlier, may be because I already had >> this in cflags? >> >> >> -- Cin mailing list Cin@lists.cinelerra-gg.org https://lists.cinelerra-gg.org/mailman/listinfo/cin