add configure without-thirdparty, without-libzmpeg, without-commercial
authorGood Guy <good1.2guy@gmail.com>
Mon, 18 Jun 2018 00:54:36 +0000 (18:54 -0600)
committerGood Guy <good1.2guy@gmail.com>
Mon, 18 Jun 2018 00:54:36 +0000 (18:54 -0600)
33 files changed:
cinelerra-5.1/Makefile.am
cinelerra-5.1/Makefile.devel
cinelerra-5.1/arch.bld [new file with mode: 0755]
cinelerra-5.1/cinelerra/Makefile
cinelerra-5.1/cinelerra/aboutprefs.C
cinelerra-5.1/cinelerra/assetedit.C
cinelerra-5.1/cinelerra/dvbtune.C
cinelerra-5.1/cinelerra/ffmpeg.C
cinelerra-5.1/cinelerra/file.C
cinelerra-5.1/cinelerra/fileac3.C
cinelerra-5.1/cinelerra/fileac3.h
cinelerra-5.1/cinelerra/filedv.h
cinelerra-5.1/cinelerra/fileffmpeg.C
cinelerra-5.1/cinelerra/filempeg.C
cinelerra-5.1/cinelerra/filempeg.h
cinelerra-5.1/cinelerra/fileogg.h
cinelerra-5.1/cinelerra/mainmenu.C
cinelerra-5.1/cinelerra/mwindow.C
cinelerra-5.1/cinelerra/mwindowedit.C
cinelerra-5.1/cinelerra/mwindowgui.C
cinelerra-5.1/cinelerra/pluginfclient.C
cinelerra-5.1/cinelerra/record.C
cinelerra-5.1/cinelerra/renderfarmclient.C
cinelerra-5.1/configure.ac
cinelerra-5.1/db/Makefile
cinelerra-5.1/db/utils/Makefile
cinelerra-5.1/deb.bld [new file with mode: 0755]
cinelerra-5.1/libzmpeg3/Makefile
cinelerra-5.1/libzmpeg3/libzmpeg3.h
cinelerra-5.1/mpeg2enc/Makefile
cinelerra-5.1/mplexlo/Makefile
cinelerra-5.1/rpm.bld [new file with mode: 0755]
cinelerra-5.1/thirdparty/Makefile

index 9b9e7cbdaeac8390615fb8dd91d933e2e4855ba0..9b78846c3ec2ca32d7ccfdd8a801d25e7044cb6d 100644 (file)
@@ -42,7 +42,7 @@ binstall:     install-recursive
          if [ $$d = picon/cinfinity ]; then continue; fi; \
          cp -a $$d bin/plugins/picon/.; \
        done
-       cp -a db/utils/new_db "bin/cin_db"
+       -cp -a db/utils/new_db "bin/cin_db"
        cp -av lv2_blacklist.txt bin/.
 
 buninstall:
@@ -53,7 +53,9 @@ cinstall:
        cd bin; $(inst_sh) "$(DESTDIR)$(bindir)" "$(WANT_CIN)" \
                cin_db zmpeg3{cat,cc2txt,ifochk,show,toc}
        cd bin; $(inst_sh) "$(DESTDIR)$(WANT_CINLIB_DIR)" \
-               bdwrite cutads lv2ui hveg2enc mpeg2enc mplex mplexlo
+               bdwrite cutads lv2ui
+       -cd bin; $(inst_sh) "$(DESTDIR)$(WANT_CINLIB_DIR)" \
+               hveg2enc mpeg2enc mplex mplexlo
        cd bin; $(inst_sh) "$(DESTDIR)$(datadir)/$(WANT_CIN)" \
                COPYING README models Cinelerra_factory ffmpeg msg info tips doc \
                lv2 lv2_blacklist.txt
index 30d169f1c4bf684fcf693d58b2a8f332f95fd40c..ef516090bf6a766ec4f795e88363fd72c33613c3 100644 (file)
@@ -8,8 +8,8 @@ cpus:=$(shell grep -c "^proc" /proc/cpuinfo)
 jobs:=-j$(shell echo $$(($(cpus) + $(cpus)/2 +2)))
 MAKEJ := $(MAKE) $(jobs)
 
-SUBDIRS := thirdparty libzmpeg3 mpeg2enc mplexlo\
- db guicast cinelerra plugins doc po
+SUBDIRS = thirdparty libzmpeg3 mpeg2enc mplexlo \
      db guicast cinelerra plugins doc po
 
 all:
        mkdir -p bin bin/lv2
@@ -43,9 +43,8 @@ rebuild_all:
        $(MAKE) -C libzmpeg3 clean
        +$(MAKEJ) -C libzmpeg3
        $(MAKE) -C db clean
-       +$(MAKEJ) -C db
+       +$(MAKEJ) -C db all utils
        $(MAKE) rebuild
-       +$(MAKEJ) -C db/utils
 
 rebuild_install:
        $(MAKE) -C cinelerra install
diff --git a/cinelerra-5.1/arch.bld b/cinelerra-5.1/arch.bld
new file mode 100755 (executable)
index 0000000..9953521
--- /dev/null
@@ -0,0 +1,11 @@
+#!/bin/bash
+
+#pacman -S openexr libdv flac
+
+( ./autogen.sh
+  ./configure --with-single-user --disable-static-build --without-lv2 \
+ --without-firewire --without-dv --without-dvb --without-video4linux2 \
+ --without-libzmpeg --without-commercial --without-thirdparty
+  make && make install ) 2>&1 | tee log
+mv Makefile Makefile.cfg
+cp Makefile.devel Makefile
index 67e14e8a751f70e442de6959ba12b4dc1b9fac5b..de121c234fbb50c69f76d7507e683cb911a9d0fa 100644 (file)
@@ -1,7 +1,7 @@
 export TOPDIR ?= $(CURDIR)/..
 include $(TOPDIR)/global_config
 
-OBJS = \
+OBJS := \
        $(OBJDIR)/aattachmentpoint.o \
        $(OBJDIR)/aautomation.o \
        $(OBJDIR)/aboutprefs.o \
@@ -30,7 +30,6 @@ OBJS = \
        $(OBJDIR)/audiodvb.o \
        $(OBJDIR)/audioesound.o \
        $(OBJDIR)/audioidevice.o \
-       $(OBJDIR)/audiompeg.o \
        $(OBJDIR)/audioodevice.o \
        $(OBJDIR)/audiooss.o \
        $(OBJDIR)/audiov4l2mpeg.o \
@@ -63,7 +62,6 @@ OBJS = \
        $(OBJDIR)/clipedls.o \
        $(OBJDIR)/clippopup.o \
        $(OBJDIR)/colorpicker.o \
-       $(OBJDIR)/commercials.o \
        $(OBJDIR)/commonrender.o \
        $(OBJDIR)/confirmquit.o \
        $(OBJDIR)/confirmsave.o \
@@ -75,18 +73,15 @@ OBJS = \
        $(OBJDIR)/cwindowgui.o \
        $(OBJDIR)/cwindow.o \
        $(OBJDIR)/cwindowtool.o \
-       $(OBJDIR)/dbwindow.o \
        $(OBJDIR)/dcoffset.o \
        $(OBJDIR)/deleteallindexes.o \
        $(OBJDIR)/device1394input.o \
        $(OBJDIR)/device1394output.o \
        $(OBJDIR)/devicedvbinput.o \
-       $(OBJDIR)/devicempeginput.o \
        $(OBJDIR)/devicev4l2base.o \
        $(OBJDIR)/devicev4l2input.o \
        $(OBJDIR)/dragcheckbox.o \
        $(OBJDIR)/drivesync.o \
-       $(OBJDIR)/dvbtune.o \
        $(OBJDIR)/dvdcreate.o \
        $(OBJDIR)/edithandles.o \
        $(OBJDIR)/editlength.o \
@@ -100,12 +95,10 @@ OBJS = \
        $(OBJDIR)/exportedl.o \
        $(OBJDIR)/fadeengine.o \
        $(OBJDIR)/ffmpeg.o \
-       $(OBJDIR)/fileac3.o \
        $(OBJDIR)/filebaseaudio.o \
        $(OBJDIR)/filebase.o \
        $(OBJDIR)/filebaseulaw.o \
        $(OBJDIR)/filecr2.o \
-       $(OBJDIR)/filedb.o \
        $(OBJDIR)/filedv.o \
        $(OBJDIR)/fileexr.o \
        $(OBJDIR)/fileffmpeg.o \
@@ -114,7 +107,6 @@ OBJS = \
        $(OBJDIR)/filegif.o \
        $(OBJDIR)/filejpeg.o \
        $(OBJDIR)/filelist.o \
-       $(OBJDIR)/filempeg.o \
        $(OBJDIR)/file.o \
        $(OBJDIR)/fileogg.o \
        $(OBJDIR)/filepng.o \
@@ -180,7 +172,6 @@ OBJS = \
        $(OBJDIR)/maskautos.o \
        $(OBJDIR)/maskengine.o \
        $(OBJDIR)/mbuttons.o \
-       $(OBJDIR)/mediadb.o \
        $(OBJDIR)/menuaeffects.o \
        $(OBJDIR)/menuattacheffect.o \
        $(OBJDIR)/menuattachtransition.o \
@@ -310,7 +301,6 @@ OBJS = \
        $(OBJDIR)/vdevice1394.o \
        $(OBJDIR)/vdevicebase.o \
        $(OBJDIR)/vdevicedvb.o \
-       $(OBJDIR)/vdevicempeg.o \
        $(OBJDIR)/vdeviceprefs.o \
        $(OBJDIR)/vdevicev4l2jpeg.o \
        $(OBJDIR)/vdevicev4l2mpeg.o \
@@ -345,6 +335,29 @@ OBJS = \
        $(OBJDIR)/zwindow.o \
        $(OBJDIR)/zwindowgui.o \
 
+ifneq ($(WANT_LIBZMPEG),no)
+OBJS += \
+       $(OBJDIR)/audiompeg.o \
+       $(OBJDIR)/devicempeginput.o \
+       $(OBJDIR)/filempeg.o \
+       $(OBJDIR)/vdevicempeg.o \
+
+endif
+ifneq ($(WANT_COMMERCIAL),no)
+OBJS += \
+       $(OBJDIR)/commercials.o \
+       $(OBJDIR)/dbwindow.o \
+       $(OBJDIR)/filedb.o \
+       $(OBJDIR)/mediadb.o \
+
+endif
+ifneq ($(WANT_CIN_3RDPARTY),no)
+OBJS += \
+       $(OBJDIR)/fileac3.o \
+
+endif
+
+#      $(OBJDIR)/dvbtune.o \
 #      $(OBJDIR)/renderfarmfsclient.o \
 #      $(OBJDIR)/renderfarmfsserver.o \
 
@@ -357,13 +370,88 @@ OUTPUT_G = $(OBJDIR)/$(WANT_CIN).debuginfo
 
 LIBRARIES := \
        $(GUICAST)/$(OBJDIR)/libguicast.a \
-       $(LIBZMPEG3)/$(OBJDIR)/libzmpeg3.a \
+
+ifneq ($(WANT_LIBZMPEG),no)
+LIBRARIES += \
        $(MPEG2ENC)/$(OBJDIR)/hveg2enc.a \
+       $(LIBZMPEG3)/$(OBJDIR)/libzmpeg3.a \
+
+endif
+ifneq ($(WANT_COMMERCIAL),no)
+LIBRARIES += \
        $(TDB)/$(OBJDIR)/db.a \
 
+endif
+
 LIBS := $(LIBRARIES)
+
+ifneq ($(WANT_CIN_3RDPARTY),no)
 LIBS += $(libraries)
+else
+
+LIBS += -lpthread -lm -lbz2 -llzma -lz -lpng -luuid
+LIBS += -lX11 -lXau -lXdmcp -lXext -lXfixes -lXv -lXinerama
+LIBS += -lfontconfig -lfreetype
+LIBS += -lavcodec -lavdevice -lavfilter -lavformat -lavresample -lavutil
+LIBS += -lswresample -lswscale
+LIBS += -lvpx -lwebp -lwebpmux
+
+LIBS += $(if $(filter fftw,$(static_pkgs)), -lfftw3)
+LIBS += $(if $(filter flac,$(static_pkgs)), -lFLAC)
+LIBS += $(if $(filter giflib,$(static_pkgs)), -lgif)
+LIBS += $(if $(filter lame,$(static_pkgs)), -lmp3lame)
+LIBS += $(if $(filter libjpeg,$(static_pkgs)), -ljpeg)
+LIBS += $(if $(filter openjpeg,$(static_pkgs)), -lopenjp2)
+LIBS += $(if $(filter libogg,$(static_pkgs)), -logg)
+LIBS += $(if $(filter libsndfile,$(static_pkgs)), -lsndfile)
+LIBS += $(if $(filter libtheora,$(static_pkgs)), -ltheoradec -ltheoraenc)
+LIBS += $(if $(filter libuuid,$(static_pkgs)), -luuid)
+LIBS += $(if $(filter libvorbis,$(static_pkgs)), -lvorbis -lvorbisenc -lvorbisfile)
+LIBS += $(if $(filter tiff,$(static_pkgs)), -ltiff)
+LIBS += $(if $(filter twolame,$(static_pkgs)), -ltwolame)
+LIBS += $(if $(filter x264,$(static_pkgs)), -lx264)
+LIBS += $(if $(filter x265,$(static_pkgs)), -lx265)
+LIBS += $(if $(filter libvpx,$(static_pkgs)), -lvpx)
+
+ifneq ($(WANT_GL),no)
+LIBS += -lGL -lGLU -lGLX
+endif
+ifneq ($(WANT_XFT),no)
+LIBS += -lXft
+endif
+ifneq ($(WANT_ALSA),no)
+LIBS += -lasound
+endif
+ifneq ($(WANT_OPENEXR),no)
+LIBS += -lIex -lIexMath -lIlmImf -lIlmImfUtil
+endif
+ifneq ($(WANT_DV),no)
+LIBS += -ldv
+endif
+ifneq ($(WANT_FIREWIRE),no)
+LIBS += -lavc1394 -lraw1394 -liec61883 -lrom1394
+endif
+ifneq ($(WANT_DVB),no)
+LIBS += -ldv
+endif
+ifneq ($(WANT_DL),no)
+LIBS += -ldl
+endif
+ifneq ($(WANT_LIBZMPEG),no)
+LIBS += -lmjpegutils
+endif
+ifneq ($(WANT_OPUS),no)
+LIBS += -lopus
+endif
+ifneq ($(WANT_NUMA),no)
+LIBS += -lnuma
+endif
+ifneq ($(WANT_LV2),no)
+LIBS += -llilv-0 -lsratom-0 -lserd-0 -lsord-0 -lsuil-0
+endif
+endif
 
+ifneq ($(WANT_COMMERCIAL),no)
 CUTADS = $(OBJDIR)/cutads
 CUTOBJ = $(OBJDIR)/cutads.o
 CUTOBJS = $(CUTOBJ) \
@@ -372,6 +460,7 @@ CUTOBJS = $(CUTOBJ) \
 CUTLIBS = \
        $(LIBZMPEG3)/$(OBJDIR)/libzmpeg3.a -lX11 \
        $(TDB)/$(OBJDIR)/db.a
+endif
 
 BDWRITE = $(OBJDIR)/bdwrite
 BDWOBJS = $(OBJDIR)/bdwrite.o
@@ -437,6 +526,7 @@ $(OUTPUT): $(OBJS) $(THEME_DATA) $(DCRAW) $(LIBRARIES)
        $(if $(findstring -ggdb,$(CFLAGS)),,strip $(OUTPUT))
        ln -f -s ../bin/$(WANT_CIN) ci
 
+ifneq ($(WANT_COMMERCIAL),no)
 $(CUTADS):     $(CUTOBJS) $(CUTLIBS) $(LIBRARIES)
        @echo g++ -o $@ $(CUTOBJS)
        @g++ $(CFLAGS) -pthread -o $@ $(CUTOBJS) $(CUTLIBS) $(LIBS)
@@ -445,7 +535,9 @@ $(CUTADS):  $(CUTOBJS) $(CUTLIBS) $(LIBRARIES)
 
 install-cutads:
        cp -av $(OBJDIR)/cutads $(BINDIR)/.
+
 install:       install-cutads
+endif
 
 $(BDWRITE):    $(BDWOBJS) $(LIBRARIES)
        @echo g++ -o $@ $(BDWOBJS)
index 9997efa7cd59b2210218a378b4f014824a4fc2af..5f286aef8b7be528b0b2e2eb45be9728b10a5941 100644 (file)
@@ -23,7 +23,6 @@
 #include "bcsignals.h"
 #include "file.h"
 #include "language.h"
-#include "libzmpeg3.h"
 #include "mwindow.h"
 #include "theme.h"
 #include "vframe.h"
index 51fa34fa4140a1f9a77c90436d2d805de0beb91d..0a417e4bf7175775ec737b7a79e5e3c28445c700 100644 (file)
@@ -927,9 +927,11 @@ void DetailAssetWindow::create_objects()
        strncpy(info,_("no info available"),len);
        if( !mwindow->preferences->get_asset_file_path(asset, file_name) ) {
                switch( asset->format ) {
+#ifdef HAVE_LIBZMPEG
                case FILE_MPEG:
                        FileMPEG::get_info(asset->path, file_name, &info[0],len);
                        break;
+#endif
                case FILE_FFMPEG:
                        FileFFMPEG::get_info(asset->path, &info[0],len);
                        break;
index 60de3f21d1e7f651041b29444d6a4c6c2e02ad16..1b0d9a1eb4a550cd83f62f01e48369472e439f5f 100644 (file)
@@ -19,8 +19,8 @@
  *
  */
 
-#include "../../guicast/bcwindowbase.inc"
-#include "../../guicast/clip.h"
+#include "guicast/bcwindowbase.inc"
+#include "guicast/clip.h"
 #include "condition.h"
 #include "devicedvbinput.inc"
 #include "dvbtune.h"
index 2ac09f730a9612126925dcc7fd5df14bb4517946..541c5f0a4cd0bc4a4ec809408e930076ad2f1177 100644 (file)
 #include "mwindow.h"
 #include "vframe.h"
 
+#ifdef FFMPEG3
+#define url filename
+#else
+#define av_register_all(s)
+#define avfilter_register_all(s)
+#endif
 
 #define VIDEO_INBUF_SIZE 0x10000
 #define AUDIO_INBUF_SIZE 0x10000
@@ -1925,6 +1931,7 @@ int FFMPEG::info(char *text, int len)
 int FFMPEG::init_decoder(const char *filename)
 {
        ff_lock("FFMPEG::init_decoder");
+       av_register_all();
        char file_opts[BCTEXTLEN];
        char *bp = strrchr(strcpy(file_opts, filename), '/');
        char *sp = strrchr(!bp ? file_opts : bp, '.');
@@ -2070,6 +2077,7 @@ int FFMPEG::init_encoder(const char *filename)
                return 1;
        }
        ff_lock("FFMPEG::init_encoder");
+       av_register_all();
        char format[BCSTRLEN];
        if( get_format(format, "format", file_format) )
                strcpy(format, file_format);
@@ -2103,7 +2111,9 @@ int FFMPEG::open_encoder(const char *type, const char *spec)
                return 1;
        }
 
+#ifdef HAVE_DV
        if( !strcmp(codec_name, CODEC_TAG_DVSD) ) strcpy(codec_name, "dv");
+#endif
        else if( !strcmp(codec_name, CODEC_TAG_MJPEG) ) strcpy(codec_name, "mjpeg");
        else if( !strcmp(codec_name, CODEC_TAG_JPEG) ) strcpy(codec_name, "jpeg");
 
@@ -2856,6 +2866,7 @@ int FFMPEG::ff_cpus()
 
 int FFVideoStream::create_filter(const char *filter_spec, AVCodecParameters *avpar)
 {
+       avfilter_register_all();
        const char *sp = filter_spec;
        char filter_name[BCSTRLEN], *np = filter_name;
        int i = sizeof(filter_name);
@@ -2896,6 +2907,7 @@ int FFVideoStream::create_filter(const char *filter_spec, AVCodecParameters *avp
 
 int FFAudioStream::create_filter(const char *filter_spec, AVCodecParameters *avpar)
 {
+       avfilter_register_all();
        const char *sp = filter_spec;
        char filter_name[BCSTRLEN], *np = filter_name;
        int i = sizeof(filter_name);
index 264be2e8ff0c7d44efa338e4647f06c4c3c01d06..03348e0a6422f3316a26dc008757157f8ba546f8 100644 (file)
@@ -171,9 +171,11 @@ int File::get_options(FormatTools *format,
        getting_options = 1;
        format_completion->lock("File::get_options");
        switch( asset->format ) {
+#ifdef HAVE_CIN_3RDPARTY
        case FILE_AC3: FileAC3::get_parameters(parent_window, asset, format_window,
                        audio_options, video_options, edl);
                break;
+#endif
 #ifdef HAVE_DV
        case FILE_RAWDV:
                FileDV::get_parameters(parent_window, asset, format_window,
@@ -192,11 +194,13 @@ int File::get_options(FormatTools *format,
                FileFFMPEG::get_parameters(parent_window, asset, format_window,
                        audio_options, video_options, edl);
                break;
+#ifdef HAVE_LIBZMPEG
        case FILE_AMPEG:
        case FILE_VMPEG:
                FileMPEG::get_parameters(parent_window, asset, format_window,
                        audio_options, video_options, edl);
                break;
+#endif
        case FILE_JPEG:
        case FILE_JPEG_LIST:
                FileJPEG::get_parameters(parent_window, asset, format_window,
@@ -376,11 +380,13 @@ int File::probe()
                        file = new FileFFMPEG(this->asset, this);
                        return FILE_OK;
                }
+#ifdef HAVE_COMMERCIAL
                if( !strcmp(pref->name,"DB") ) { // MediaDB
                        if( !FileDB::check_sig(this->asset) ) continue;
                        file = new FileDB(this->asset, this);
                        return FILE_OK;
                }
+#endif
                if( !strcmp(pref->name,"Scene") ) { // scene file
                        if( !FileScene::check_sig(this->asset, data)) continue;
                        file = new FileScene(this->asset, this);
@@ -455,11 +461,13 @@ int File::probe()
                        file = new FileVorbis(this->asset, this);
                        return FILE_OK;
                }
+#ifdef HAVE_LIBZMPEG
                if( !strcmp(pref->name,"MPEG") ) { // MPEG file
                        if( !FileMPEG::check_sig(this->asset) ) continue;
                        file = new FileMPEG(this->asset, this);
                        return FILE_OK;
                }
+#endif
                if( !strcmp(pref->name,"EDL") ) { // XML file
                        if( data[0] != '<' ) continue;
                        if( !strncmp(&data[1],"EDL>",4) ||
@@ -495,10 +503,11 @@ int File::open_file(Preferences *preferences,
                if( ret != FILE_OK ) return ret;
                break; }
 // format already determined
+#ifdef HAVE_CIN_3RDPARTY
        case FILE_AC3:
                file = new FileAC3(this->asset, this);
                break;
-
+#endif
        case FILE_SCENE:
                file = new FileScene(this->asset, this);
                break;
@@ -559,17 +568,19 @@ int File::open_file(Preferences *preferences,
        case FILE_TIFF_LIST:
                file = new FileTIFF(this->asset, this);
                break;
-
+#ifdef HAVE_COMMERCIAL
        case FILE_DB:
                file = new FileDB(this->asset, this);
                break;
+#endif
 
+#ifdef HAVE_LIBZMPEG
        case FILE_MPEG:
        case FILE_AMPEG:
        case FILE_VMPEG:
                file = new FileMPEG(this->asset, this);
                break;
-
+#endif
        case FILE_OGG:
                file = new FileOGG(this->asset, this);
                break;
@@ -1264,7 +1275,9 @@ const char* File::formattostr(int format)
        case FILE_FLAC:         return _(FLAC_NAME);
        case FILE_EXR:          return _(EXR_NAME);
        case FILE_EXR_LIST:     return _(EXR_LIST_NAME);
+#ifdef HAVE_LIBZMPEG
        case FILE_MPEG:         return _(MPEG_NAME);
+#endif
        case FILE_AMPEG:        return _(AMPEG_NAME);
        case FILE_VMPEG:        return _(VMPEG_NAME);
        case FILE_TGA:          return _(TGA_NAME);
@@ -1346,7 +1359,9 @@ int File::get_best_colormodel(Asset *asset, int driver)
 #ifdef HAVE_DV
        case FILE_RAWDV:        return FileDV::get_best_colormodel(asset, driver);
 #endif
+#ifdef HAVE_LIBZMPEG
        case FILE_MPEG:         return FileMPEG::get_best_colormodel(asset, driver);
+#endif
        case FILE_JPEG:
        case FILE_JPEG_LIST:    return FileJPEG::get_best_colormodel(asset, driver);
 #ifdef HAVE_OPENEXR
@@ -1361,7 +1376,9 @@ int File::get_best_colormodel(Asset *asset, int driver)
        case FILE_TGA_LIST:     return FileTGA::get_best_colormodel(asset, driver);
        case FILE_CR2:
        case FILE_CR2_LIST:     return FileCR2::get_best_colormodel(asset, driver);
+#ifdef HAVE_COMMERCIAL
        case FILE_DB:           return FileDB::get_best_colormodel(asset, driver);
+#endif
        case FILE_FFMPEG:       return FileFFMPEG::get_best_colormodel(asset, driver);
        }
 
index 3b9810e99114b796ce1bf47e93b2aad1b5d14f80..25276864175dcb471397a418481df9fd626ddacd 100644 (file)
@@ -1,4 +1,4 @@
-
+#ifdef HAVE_CIN_3RDPARTY
 /*
  * CINELERRA
  * Copyright (C) 2008 Adam Williams <broadcast at earthling dot net>
@@ -438,5 +438,4 @@ int AC3ConfigAudioBitrate::handle_event()
        return 1;
 }
 
-
-
+#endif
index 6683816b9e10a711a6829d13a96f5defeef353e3..8ae62c76ebcbb23c242186653ad5adeaacf6318d 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * CINELERRA
  * Copyright (C) 2008 Adam Williams <broadcast at earthling dot net>
@@ -21,6 +20,7 @@
 
 #ifndef FILEAC3_H
 #define FILEAC3_H
+#ifdef HAVE_CIN_3RDPARTY
 
 #include <stdio.h>
 #include <stdint.h>
@@ -100,8 +100,5 @@ public:
        AC3ConfigAudio *gui;
 };
 
-
-
-
-
+#endif
 #endif
index 843b59b83ebf2657fcfbac2d3df9381652b9fa25..64e867e9fdf1b9a3401d2c82dc3d0a5bf2e0f0cb 100644 (file)
@@ -24,7 +24,6 @@
 
 #ifdef HAVE_DV
 
-#include "../config.h"
 #include "edl.inc"
 #include "filebase.h"
 #include "file.inc"
index 6f4db28f0bb231ac780376bdbcd79e19c1495cf7..7edc387d6b5350e5eb6870b491a07ac86ddd09f4 100644 (file)
 #include "preferences.h"
 #include "videodevice.inc"
 
+#ifdef FFMPEG3
+#define url filename
+#endif
+
 FileFFMPEG::FileFFMPEG(Asset *asset, File *file)
  : FileBase(asset, file)
 {
index 9988673fe1215cfe1d41a9f64f2a2d8990205509..da71349eda56ffce786fb46fde187324e15d54fd 100644 (file)
@@ -774,6 +774,7 @@ int FileMPEG::skim_video(int track, void *vp, skim_fn fn)
 
 
 
+#ifdef HAVE_COMMERCIAL
 int FileMPEG::toc_nail(void *vp, int track)
 {
        File *file = (File *)vp;
@@ -788,7 +789,7 @@ int FileMPEG::toc_nail(void *vp, int track)
        MWindow::commercials->get_frame(file, pid, position, tdat, mw, mh, width, height);
        return 0;
 }
-
+#endif
 
 int FileMPEG::create_toc(char *toc_path)
 {
@@ -816,11 +817,13 @@ int FileMPEG::create_toc(char *toc_path)
 // File needs a table of contents.
        struct timeval new_time, prev_time, start_time, current_time;
        gettimeofday(&prev_time, 0);  gettimeofday(&start_time, 0);
+#ifdef HAVE_COMMERCIAL
        if( file->preferences->scan_commercials ) {
                set_skimming(-1, 1, toc_nail, file);
                if( MWindow::commercials->resetDb() != 0 )
                        eprintf(_("cant access commercials database"));
        }
+#endif
 // This gets around the fact that MWindowGUI may be locked.
        char progress_title[BCTEXTLEN];
        sprintf(progress_title, _("Creating %s\n"), toc_file);
@@ -864,10 +867,12 @@ int FileMPEG::create_toc(char *toc_path)
                }
        }
 
+#ifdef HAVE_COMMERCIAL
        if( file->preferences->scan_commercials ) {
                if( !result ) MWindow::commercials->write_ads(asset->path);
                MWindow::commercials->closeDb();
        }
+#endif
 
        mpeg3_stop_toc(fd);
        fd = 0;
index a92f29b7f953b00b17bbd164fbed76d23175a389..34e779cec849235b9ba84f6059efd13fc93861ff 100644 (file)
@@ -21,6 +21,7 @@
 
 #ifndef FILEMPEG_H
 #define FILEMPEG_H
+#ifdef HAVE_LIBZMPEG
 
 #include "bitspopup.inc"
 #include "condition.inc"
@@ -361,5 +362,5 @@ public:
        ArrayList<BC_SubWindow*> tools;
 };
 
-
+#endif
 #endif
index 1538281bc2de4075d761830b75ec561ba1388f84..26a68022d74d82d0a5df6b7b45ced240e8e19253 100644 (file)
@@ -22,7 +22,6 @@
 #ifndef FILEOGG_H
 #define FILEOGG_H
 
-#include "../config.h"
 #include "edl.inc"
 #include "filebase.h"
 #include "file.inc"
index 699caa3319c36ba9aa06134abb14959218558831..0bd56ec3525664c91d1e05448b52dabcdd84ad1e 100644 (file)
@@ -116,8 +116,10 @@ void MainMenu::create_objects()
 #ifdef HAVE_DVB
        filemenu->add_item(new ChannelScan(mwindow));
 #endif
+#ifdef HAVE_COMMERCIAL
        if( mwindow->has_commercials() )
                filemenu->add_item(new DbWindowScan(mwindow));
+#endif
        filemenu->add_item(new SubttlSWin(mwindow));
 
        filemenu->add_item(render = new RenderItem(mwindow));
index 9de65dba075855f78b5c4aa1234f471cbb4350d1..c65f99f21167bf5c15932b3cd44c4196638d3c5e 100644 (file)
@@ -1628,37 +1628,49 @@ void MWindow::set_brender_active(int v, int update)
 
 int MWindow::has_commercials()
 {
+#ifdef HAVE_COMMERCIAL
        return theme->use_commercials;
+#else
+       return 0;
+#endif
 }
 
 void MWindow::init_commercials()
 {
+#ifdef HAVE_COMMERCIAL
        if( !commercials ) {
                commercials = new Commercials(this);
                commercial_active = 0;
        }
        else
                commercials->add_user();
+#endif
 }
 
 void MWindow::commit_commercial()
 {
+#ifdef HAVE_COMMERCIAL
        if( !commercial_active ) return;
        commercial_active = 0;
        if( !commercials ) return;
        commercials->commitDb();
+#endif
 }
 
 void MWindow::undo_commercial()
 {
+#ifdef HAVE_COMMERCIAL
        if( !commercial_active ) return;
        commercial_active = 0;
        if( !commercials ) return;
        commercials->undoDb();
+#endif
 }
 
 int MWindow::put_commercial()
 {
+       int result = 0;
+#ifdef HAVE_COMMERCIAL
        double start = edl->local_session->get_selectionstart();
        double end = edl->local_session->get_selectionend();
        if( start >= end ) return 0;
@@ -1666,7 +1678,6 @@ int MWindow::put_commercial()
        const char *errmsg = 0;
        int count = 0;
        Tracks *tracks = edl->tracks;
-       int result = 0;
        //check it
        for(Track *track=tracks->first; track && !errmsg; track=track->next) {
                if( track->data_type != TRACK_VIDEO ) continue;
@@ -1719,6 +1730,7 @@ int MWindow::put_commercial()
                undo_commercial();
                result = 1;
        }
+#endif
        return result;
 }
 
index cf818e47a48f0c27432b7d5c2d7a59165c3eb007..eb06639824c8e0620f4307ecc9738e9cc158953a 100644 (file)
@@ -2448,6 +2448,7 @@ void MWindow::add_proxy(int use_scaler,
 
 void MWindow::cut_commercials()
 {
+#ifdef HAVE_COMMERCIAL
        undo->update_undo_before();
        commercials->scan_media();
        edl->optimize();
@@ -2459,6 +2460,7 @@ void MWindow::cut_commercials()
        gui->update(1, 2, 1, 1, 1, 1, 0);
        cwindow->update(1, 0, 0, 0, 1);
        cwindow->refresh_frame(CHANGE_EDL);
+#endif
 }
 
 int MWindow::normalize_speed(EDL *old_edl, EDL *new_edl)
index 566afd6c27d12f21d96c12c8fee2540b0fe6b7fe..9259dde163549c657a431c26b7a20304cdaf7ab2 100644 (file)
@@ -356,7 +356,9 @@ void MWindowGUI::create_objects()
 #ifdef HAVE_DVB
        channel_info = new ChannelInfo(mwindow);
 #endif
+#ifdef HAVE_COMMERCIAL
        db_window = new DbWindow(mwindow);
+#endif
        swindow = new SWindow(mwindow);
 
        if(debug) printf("MWindowGUI::create_objects %d\n", __LINE__);
index 74c59f4fed39dcc0b168dcf9aa5ae7ca04338b4a..c5d02db8ae36b69a7c11eb5f9a19fd056a31d4d6 100644 (file)
@@ -16,6 +16,9 @@
 #include "vframe.h"
 #include "filexml.h"
 
+#ifdef FFMPEG3
+#define av_filter_iterate(p) ((*(const AVFilter**)(p))=avfilter_next(*(const AVFilter **)(p)))
+#endif
 
 static void ff_err(int ret, const char *fmt, ...)
 {
index 473e10c32c1a4b185ddb898242e5b761ea96fc11..96ec0f8236284bd5a88f6fa504dd728d3e6ec89d 100644 (file)
@@ -155,19 +155,23 @@ Record::Record(MWindow *mwindow, RecordMenuItem *menu_item)
        adevice_lock = new Mutex("Record::adevice_lock");
        vdevice_lock = new Mutex("Record::vdevice_lock");
        batch_lock = new Mutex("Record::batch_lock");
+#ifdef HAVE_COMMERCIAL
        skim_thread = new SkimDbThread();
        cutads_status = new RecordCutAdsStatus(this);
        blink_status = new RecordBlinkStatus(this);
+#endif
 }
 
 Record::~Record()
 {
        mwindow->gui->record = 0;
        stop();
+#ifdef HAVE_COMMERCIAL
        delete blink_status;
        delete cutads_status;
        stop_skimming();
        delete skim_thread;
+#endif
        delete deletions;
        delete picture;
        delete channeldb;
@@ -366,13 +370,17 @@ void Record::run()
 
 // Need to stop everything this time
 
-       stop_commercial_capture(0);
        int video_stream = -1;
+#ifdef HAVE_COMMERCIAL
+       stop_commercial_capture(0);
+#endif
+#ifdef HAVE_LIBZMPEG
        if( default_asset->format == FILE_MPEG ) {
                Channel *channel = get_current_channel();
                if( channel )
                        video_stream = channel->video_stream;
        }
+#endif
        stop(0);
        edl->Garbage::remove_user();
 
@@ -1462,7 +1470,7 @@ int Record::check_batch_complete()
        return result;
 }
 
-
+#ifdef HAVE_COMMERCIAL
 int Record::skimming(void *vp, int track)
 {
        return ((Record*)vp)->skimming(track);
@@ -1505,6 +1513,14 @@ void Record::update_skimming(int v)
                stop_skimming();
 }
 
+#else
+int Record::skimming(void *vp, int track) { return 1; }
+int Record::skimming(int track) { return 1; }
+void Record::start_skimming() {}
+void Record::stop_skimming() {}
+void Record::update_skimming(int v) {}
+#endif
+
 RecordRemoteHandler::RecordRemoteHandler(RemoteControl *remote_control)
  : RemoteHandler(remote_control->gui, GREEN)
 {
@@ -1766,6 +1782,7 @@ int Record::remote_process_key(RemoteControl *remote_control, int key)
                break;
        //case UP: case DOWN: case LEFT: case RIGHT:
        //case KPPLAY: case KPBACK: case KPFORW:
+#ifdef HAVE_COMMERCIAL
        case KPRECD:  case 'c': // start capture, mark endpoint
                if( !deletions ) {
                        start_commercial_capture();
@@ -1785,6 +1802,7 @@ int Record::remote_process_key(RemoteControl *remote_control, int key)
        case KPAUSE:  case 'x': // ignore current commercial
                mark_commercial_capture(DEL_SKIP);
                break;
+#endif
        case KPBACK:  case 'a': // toggle mute audio
                if( !monitor_audio ) { set_mute_gain(1);  set_play_gain(1); }
                set_audio_monitoring(monitor_audio ? 0 : 1);
@@ -1792,9 +1810,11 @@ int Record::remote_process_key(RemoteControl *remote_control, int key)
        case 'm': // toggle metering audio
                set_audio_metering(metering_audio ? 0 : 1);
                break;
+#ifdef HAVE_COMMERCIAL
        case KPPLAY:  case 's': // ignore previous endpoint
                mark_commercial_capture(DEL_OOPS);
                break;
+#endif
        case KPFWRD:  case KPSLASH:
                display_channel_info();
                break;
@@ -1822,7 +1842,7 @@ int Record::remote_process_key(RemoteControl *remote_control, int key)
        return 1;
 }
 
-
+#ifdef HAVE_COMMERCIAL
 int Record::start_commercial_capture()
 {
        if( deletions != 0 ) return 1;
@@ -1860,6 +1880,7 @@ int Record::mark_commercial_capture(int action)
        deletions->append(new Dele(time, action));
        return 0;
 }
+#endif
 
 void Record::remote_fill_color(int color)
 {
@@ -1884,6 +1905,7 @@ void Record::set_play_gain(double gain)
        if( adevice ) adevice->set_play_gain(gain);
 }
 
+#ifdef HAVE_COMMERCIAL
 int Record::stop_commercial_capture(int run_job)
 {
        if( deletions == 0 ) return 1;
@@ -2057,3 +2079,4 @@ run()
        remote_color(record->status_color);
 }
 
+#endif
index 97b11f4fb64059e8851ac15c6e0d2d3f0bedf66d..aab7fb4ed66ca806db90680d9c890d08176e28e6 100644 (file)
@@ -594,9 +594,9 @@ void RenderFarmClientThread::init_client_keepalive(int timeout_secs)
 void RenderFarmClientThread::do_tuner(int socket_fd)
 {
 // Currently only 1 tuner driver.  Maybe more someday.
-       DVBTune server(this);
-       server.main_loop();
-       ::close(socket_fd);
+//     DVBTune server(this);
+//     server.main_loop();
+//     ::close(socket_fd);
 }
 
 
index d3a03d4b0f0c4cd3925a7b494e2d8c3f8b9e3029..e9f67c16a4fca3f804eccfe7ecb993cf8ee91acf 100644 (file)
@@ -23,6 +23,8 @@ CFG_CFLAGS+=" -D__STDC_LIMIT_MACROS"
 CFG_CFLAGS+=" -DPNG_SKIP_SETJMP_CHECK=1"
 CFG_CFLAGS+=" -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64"
 CFG_CFLAGS+=" -I/usr/include/freetype2"
+CFG_CFLAGS+=" -I/usr/include/uuid"
+CFG_CFLAGS+=" -I/usr/include/mjpegtools"
 
 AC_DEFUN([CHECK_WITH], [
 AC_ARG_WITH([$1],
@@ -44,6 +46,9 @@ CHECK_WITH([config-dir],[.bcast config dir],[CONFIG_DIR],[$$HOME/.bcast5])
 CHECK_WITH([browser],[cin_browser path],[CIN_BROWSER],[firefox])
 CHECK_WITH([git-ffmpeg],[git ffmpeg using url],[GIT_FFMPEG],[no])
 CHECK_WITH([noelision],[use noelision/libpthread],[NOELISION],[auto])
+CHECK_WITH([libzmpeg],[build libzmpeg],[LIBZMPEG],[yes])
+CHECK_WITH([commercial],[enable commercial capture],[COMMERCIAL],[yes])
+CHECK_WITH([thirdparty],[use thirdparty build],[CIN_3RDPARTY],[yes])
 
 if test "x$WANT_LV2" != "xno"; then
   GTK2_LIBS=`pkg-config --libs gtk+-2.0`
@@ -55,6 +60,10 @@ if test "x$WANT_LV2" != "xno"; then
   fi
 fi
 
+if test "x$WANT_COMMERCIAL" = "xyes" -a "x$WANT_LIBZMPEG" != "xyes" ; then
+  AC_MSG_ERROR([commercial requires libzmpeg support.])
+fi
+
 if test "x$WANT_CINBIN_BUILD" = "xyes"; then
   WANT_LOCALE_DIR='$$CIN_LIB/locale'
   test "x$WANT_CINDAT_DIR" = "xauto" && WANT_CINDAT_DIR='$$CIN_PATH'
@@ -672,15 +681,20 @@ AC_DEFUN([PKG_SHARED],[
  SHARED_LIBS+="$SHARED_$1"
  echo "AC_HELP_STRING([shared],[$1])"
 ])
+
 AC_DEFUN([PKG_STATIC],[
- PKG_$1="yes"
- BUILD_$1=1
- AC_SUBST(BUILD_$1)
- STATIC_BLDS+=" [$1]"
- echo "AC_HELP_STRING([$2],[$1])"
+ if test "x$WANT_CIN_3RDPARTY" != "xno"; then
+  PKG_$1="yes"
+  BUILD_$1=1
+  AC_SUBST(BUILD_$1)
+  STATIC_BLDS+=" [$1]"
+  echo "AC_HELP_STRING([$2],[$1])"
+ fi
 ])
+
 AC_DEFUN([PKG_FORCED],[PKG_STATIC([$1],[forced])])
 
+if test "x$WANT_CIN_3RDPARTY" != "xno"; then
 # order matters
 for dep in \
         ffmpeg/twolame ffmpeg/lame ffmpeg/openjpeg \
@@ -694,6 +708,7 @@ for dep in \
     eval "PKG_$needs=yes"
   fi
 done
+fi
 
 AC_DEFUN([PKG_PROVIDE],[
 if test "x$BUILD_$1" = "x" ; then
@@ -765,8 +780,12 @@ done
 AC_SUBST(SYSTEM_LIBS)
 
 echo ""
+if test "x$WANT_CIN_3RDPARTY" != "xno"; then
+  CFG_CFLAGS+=" -DHAVE_CIN_3RDPARTY"
+fi
 for v in GL XFT XXF86VM OSS ALSA FIREWIRE DV DVB \
-        VIDEO4LINUX2 ESOUND PACTL OPENEXR LV2; do
+        VIDEO4LINUX2 ESOUND PACTL OPENEXR LV2 \
+        COMMERCIAL LIBZMPEG; do
   eval vv="\$WANT_$v"
   if test "x$vv" != "xno"; then
     CFG_CFLAGS+=" -DHAVE_$v"
@@ -789,7 +808,10 @@ echo "  using: with-ladspa-dir = $WANT_LADSPA_DIR"
 echo "  using: with-opencv = $WANT_OPENCV"
 echo "  using: with-git-ffmpeg = $WANT_GIT_FFMPEG"
 echo "  using: with-noelision = $WANT_NOELISION"
+echo "  using: with-libzmpeg = $WANT_LIBZMPEG"
+echo "  using: with-commerical = $WANT_COMMERCIAL"
 echo ""
+echo "  using: thirdparty build = $WANT_CIN_3RDPARTY"
 echo "  using: single-user  = $WANT_CINBIN_BUILD"
 echo "  using: static-build = $WANT_STATIC_BUILD"
 echo "  using: ladspa-build = $WANT_LADSPA_BUILD"
@@ -810,7 +832,7 @@ if test "x$HAVE_DL" = "xyes"; then
 fi
 if test "x$WANT_OPUS" = "xyes"; then
   FFMPEG_EXTRA_CFG+=' --enable-libopus'
-  if "x$HAVE_OPUS" = "xyes" -a "x$BUILD_opus" = "x0"; then
+  if test "x$HAVE_OPUS" = "xyes" -a "x$BUILD_opus" = "x0"; then
     EXTRA_LIBS+=' -lopus'
     CFG_CFLAGS+=' -I/usr/include/opus'
   fi
@@ -826,6 +848,7 @@ if test "x$WANT_NOELISION" != "xno"; then
   | tail -1`
 fi
 
+AC_SUBST(WANT_CIN_3RDPARTY)
 AC_SUBST(EXTRA_LIBS)
 AC_SUBST(FFMPEG_EXTRA_CFG)
 AC_SUBST(WANT_X264_HIDEPTH)
@@ -861,6 +884,7 @@ echo "export THIRDPARTY EXTRA_LIBS FFMPEG_EXTRA_CFG"
 echo ""
 
 echo "WANT_CIN := $WANT_CIN"
+CFG_WANTS+=" CIN_3RDPARTY LIBZMPEG COMMERCIAL"
 for w in $CFG_WANTS; do ww=WANT_$w; echo "WANT_$w := ${!ww}"; done
 echo ""
 
index 9e4ea0b8ecb5e3dcb68b6474d05348a577486269..3836465101792b57979286a8370ffa4f81318689 100644 (file)
@@ -1,6 +1,8 @@
 export TOPDIR ?= $(CURDIR)/..
 include $(TOPDIR)/global_config
 
+ifneq ($(WANT_COMMERCIAL),no)
+
 $(shell mkdir -p $(OBJDIR))
 LIBS := $(OBJDIR)/db.a ../libzmpeg3/$(OBJDIR)/libzmpeg3.a -lasound -lm -lX11
 OUTPUT := $(OBJDIR)/db.a s.C
@@ -50,3 +52,11 @@ $(OBJDIR)/tdb.o:     tdb.C tdb.h
 $(OBJDIR)/xsch.o:      xsch.C tdb.h
 $(OBJDIR)/xsch:                $(OBJDIR)/xsch.o
 
+else
+#not WANT_COMMERCIAL
+all:
+rebuild:
+utils:
+install:
+clean:
+endif
index 0e5a8f1abef4ec73b180813ff30eb08bda73353e..cd1a4973cfd416a809af81987e5e0347697e388d 100644 (file)
@@ -1,6 +1,8 @@
 export TOPDIR ?= $(CURDIR)/../..
 include $(TOPDIR)/global_config
 
+ifneq ($(WANT_COMMERCIAL),no)
+
 $(shell mkdir -p $(OBJDIR))
 $(shell echo $(CFLAGS) > $(OBJDIR)/c_flags)
 CXXFLAGS:=-ggdb -I.. -Wall `cat $(OBJDIR)/c_flags`
@@ -61,3 +63,9 @@ install:
 clean:
        rm -f $(TARGETS) *.o a.out
 
+else
+#not WANT_COMMERCIAL
+all:
+install:
+clean:
+endif
diff --git a/cinelerra-5.1/deb.bld b/cinelerra-5.1/deb.bld
new file mode 100755 (executable)
index 0000000..b510333
--- /dev/null
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+#apt install libavcodec-dev libavdevice-dev libavfilter-dev libavformat-dev \
+# libavresample-dev libavutil-dev uuid-dev libdv4-dev libmjpegtools-dev \
+# liblilv-dev libsuil-dev libavc1394-dev libraw1394-dev libmp3lame-dev \
+# libopenjp2-7-dev libtwolame-dev libvpx-dev libwebp-dev libwebpmux3 \
+# libx264-dev libx265-dev libopus-dev
+
+( ./autogen.sh
+  CFLAGS=-DFFMPEG3 ./configure --with-single-user \
+    --disable-static-build --without-thirdparty \
+    --without-video4linux2 --without-dvb --with-lv2=auto \
+    --without-libzmpeg --without-commercial
+  make && make install ) 2>&1 | tee log
+mv Makefile Makefile.cfg
+cp Makefile.devel Makefile
+
index 022f1f42e40b6a15c73ef256c46373f2a2fa98d8..b256c73686cad8864236fcab6c5cdab6739a20f3 100644 (file)
@@ -1,6 +1,8 @@
 export TOPDIR ?= $(CURDIR)/..
 include $(TOPDIR)/global_config
 
+ifneq ($(WANT_LIBZMPEG),no)
+
 CC = gcc
 NASM = nasm
 USE_MMX ?= 0
@@ -127,3 +129,11 @@ $(OBJDIR)/%.o:             %.C
 $(OBJDIR)/audio/%.o:   audio/%.C
 $(OBJDIR)/video/%.o:   video/%.C
 
+else
+#not WANT_LIBZMPEG
+all:
+rebuild:
+utils:
+clean:
+install:
+endif
index 712d1ca00dffd62644651ff5d3b75c3d4ecbb05f..430ebb4d79ed4b40cc80d415b72e7ecc797d0d8e 100644 (file)
@@ -1,5 +1,6 @@
 #ifndef LIBMPEG3_H
 #define LIBMPEG3_H
+#ifdef HAVE_LIBZMPEG
 
 /* for quicktime build */
 #define MAXFRAMESAMPLES 65536
@@ -3092,3 +3093,4 @@ int mpeg3_dvb_get_system_time(mpeg3_t *zsrc, int64_t *tm);
 }
 #endif
 #endif
+#endif
index 37ac9a23ecedf68b93d18aab93b6ccd29fe3c543..80e0f8f939f3d38453287f81947fb8dfbcd4123a 100644 (file)
@@ -1,6 +1,8 @@
 export TOPDIR ?= $(CURDIR)/..
 include $(TOPDIR)/global_config
 
+ifneq ($(WANT_LIBZMPEG),no)
+
 CC = gcc
 CFLAGS += -I$(TOPDIR)/libzmpeg3
 
@@ -131,3 +133,11 @@ $(OBJDIR)/quantize_x86.o:              quantize_x86.c
 val-%:
        @echo $($(subst val-,,$@))
 
+else
+#not WANT_LIBZMPEG
+all:
+rebuild:
+utils:
+clean:
+install:
+endif
index 6fb9ca7222adfeb2e0b75db973b432b45532b001..c1a8aae8a4c1022f840241c440b2eb3e1759fb40 100644 (file)
@@ -1,6 +1,8 @@
 export TOPDIR ?= $(CURDIR)/..
 include $(TOPDIR)/global_config
 
+ifneq ($(WANT_LIBZMPEG),no)
+
 $(shell mkdir -p $(OBJDIR))
 OBJS = $(OBJDIR)/mplex.o
 CC = gcc
@@ -27,3 +29,12 @@ install:
        cp $(OUTPUT) $(BINDIR)/.
 
 $(OBJDIR)/mplex.o: mplex.c
+
+else
+#not WANT_LIBZMPEG
+all:
+rebuild:
+utils:
+clean:
+install:
+endif
diff --git a/cinelerra-5.1/rpm.bld b/cinelerra-5.1/rpm.bld
new file mode 100755 (executable)
index 0000000..59e1476
--- /dev/null
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+#zypper install ffmpeg \
+# libavc1394-devel libavcodec-devel libavdevice-devel libavfilter-devel \
+# libavformat-devel libavresample-devel libavutil-devel libmp3lame-devel \
+# libopus-devel libossp-uuid++16 libossp-uuid16 libossp-uuid_dce16 \
+# libtwolame-devel libvpx-devel libwebp-devel libwebpdecoder2 libwebpextras0 \
+# uuid-devel liblilv-0-devel suil-devel libmjpegutils-devel \
+# libogg-devel libvorbis-devel libtheora-devel libXdmcp-devel
+
+( ./autogen.sh
+  CFLAGS="-DFFMPEG3 -I/usr/include/ffmpeg" ./configure \
+    --with-single-user --disable-static-build --without-thirdparty \
+    --without-video4linux2 --without-dvb --with-lv2=auto \
+    --without-libzmpeg --without-commercial \
+    --disable-x264 --disable-x265 --disable-openjpeg
+  make && make install ) 2>&1 | tee log
+mv Makefile Makefile.cfg
+cp Makefile.devel Makefile
+
index b5bb2e7e7fbf711f92b09cdc98b471e32f984a16..5865b7523aa752145d5146d739a7101f51136c69 100644 (file)
@@ -28,6 +28,8 @@ include $(TOPDIR)/global_config
 -include $(TOPDIR)/cin_config
 BLD := $(THIRDPARTY)/build
 
+ifneq ($(WANT_CIN_3RDPARTY),no)
+
 # package build flags, if needed
 # need frame pointer for debugs and helps with profiling
 # NOTE: the trailing blank is MANDITORY or the builds fail
@@ -343,7 +345,13 @@ clean:
 install:
        cp -a $(ver_mjpegtools)/mpeg2enc/mpeg2enc $(BINDIR)/.
        cp -a $(ver_mjpegtools)/mplex/mplex $(BINDIR)/.
+else
+# not WANT_CIN_3RDPARTY
+all:
+clean:
+install:
 
+endif
 val-%:
        @echo $($(subst val-,,$@))