#33897 closed submission (fixed)
yorick-mpeg (new port) -- Write MPEG-1 movies from Yorick
Reported by: | paumard | Owned by: | neverpanic (Clemens Lang) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.0.4 |
Keywords: | Cc: | ||
Port: |
Description
Hi,
long_description This is a standalone mpeg movie encoder for Yorick. \ In contrast to yorick-av, yorick-mpeg has no external \ dependency: it is therefore easy to install and won't \ break with every change of the FFmpeg API. On the other \ hand, it can only produce MPEG-1 movies. homepage https://github.com/dhmunro/yorick-mpeg
Can be tested with:
$ yorick > #include "mpgtest.i" > mpgtest, "test.mpg" > quit $ open test.mpg
The "CVS-final" github tag corresponds to the version which has been distributed as 0.1 for various Linux distributions.
Regards, Thibaut.
Attachments (1)
Change History (5)
Changed 13 years ago by paumard
comment:1 Changed 13 years ago by neverpanic (Clemens Lang)
Owner: | changed from macports-tickets@… to cal@… |
---|---|
Status: | new → assigned |
Does yorick-mpeg have a license?
The build fails for me with the setup described at the bottom of UsingTheRightCompiler:
/usr/bin/llvm-gcc-4.2 -O2 -pipe -arch x86_64 -Ilibavcodec -DPLUG_IN -I. -I/opt/local/lib/yorick/include -c -o ywrap.o ywrap.c gcc -O3 -g -ansi -pedantic -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -fPIC -DHAVE_AV_CONFIG_H -I.. -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE -c -o common.o common.c gcc -O3 -g -ansi -pedantic -Wall -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -fPIC -DHAVE_AV_CONFIG_H -I.. -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE -c -o common.o common.c gcc: Error: You should be using ${configure.cc} See http://trac.macports.org/wiki/UsingTheRightCompiler make[1]: *** [common.o] Error 1 make: *** [libavcodec/libavcodec.a] Error 2 make: *** Waiting for unfinished jobs....
Applying the usual fix:
build.args yompeg.so \ CC=${configure.cc} \ CXX=${configure.cxx} \ CFLAGS=\"${configure.cflags}\" \ CXXFLAGS=\"${configure.cxxflags}\"
doesn't work either and gives:
/usr/bin/clang -O2 -c -o ywrap.o ywrap.c /usr/bin/clang -O2 -c -o common.o common.c ywrap.c:2:10: fatal error: 'play.h' file not found #include "play.h" ^ 1 error generated. make: *** [ywrap.o] Error 1 make: *** Waiting for unfinished jobs.... /usr/bin/clang -O2 -c -o utils.o utils.c common.c:50:21: error: unknown type name 'PutBitContext' void align_put_bits(PutBitContext *s) ^ common.c:55:5: warning: implicit declaration of function 'put_bits' is invalid in C99 [-Wimplicit-function-declaration] put_bits(s,s->bit_left & 7,0); ^ common.c:65:15: error: unknown type name 'PutBitContext' void put_bits(PutBitContext *s, int n, unsigned int value) ^ common.c:70:3: warning: implicit declaration of function 'assert' is invalid in C99 [-Wimplicit-function-declaration] assert(n == 32 || value < (1U << n)); ^ common.c:82:31: warning: implicit declaration of function 'be2me_32' is invalid in C99 [-Wimplicit-function-declaration] *(uint32_t *)s->buf_ptr = be2me_32(bit_buf); ^ 3 warnings and 2 errors generated. make[1]: *** [common.o] Error 1 make[1]: *** Waiting for unfinished jobs.... In file included from utils.c:29: ./mpegvideo.h:88:5: error: unknown type name 'FILE' FILE *stats_file; ^ ./mpegvideo.h:216:5: error: unknown type name 'PutBitContext' PutBitContext pb; ^ ./mpegvideo.h:436:5: error: unknown type name 'PutBitContext' PutBitContext tex_pb; /*/< used for data partitioned VOPs */ ^ ./mpegvideo.h:437:5: error: unknown type name 'PutBitContext' PutBitContext pb2; /*/< used for data partitioned VOPs */ ^ ./mpegvideo.h:479:19: error: unknown type name 'PutBitContext' void ff_copy_bits(PutBitContext *pb, uint8_t *src, int length); ^ ./mpegvideo.h:489:28: error: unknown type name 'PutBitContext' void ff_write_quant_matrix(PutBitContext *pb, uint16_t *matrix); ^ utils.c:42:16: error: use of undeclared identifier 'NULL' return NULL; ^ utils.c:43:5: warning: implicitly declaring C library function 'memset' with type 'void *(void *, int, unsigned long)' memset(ptr, 0, size); ^ utils.c:43:5: note: please include the header <string.h> or explicitly provide a declaration for 'memset' utils.c:68:12: error: use of undeclared identifier 'NULL' *ptr = NULL; ^ utils.c:78:18: error: use of undeclared identifier 'NULL' while (*p != NULL) p = &(*p)->next; ^ utils.c:80:20: error: use of undeclared identifier 'NULL' format->next = NULL; ^ utils.c:120:5: warning: implicit declaration of function 'assert' is invalid in C99 [-Wimplicit-function-declaration] assert(pic->data[0]==NULL); ^ utils.c:120:26: error: use of undeclared identifier 'NULL' assert(pic->data[0]==NULL); ^ utils.c:123:28: error: use of undeclared identifier 'NULL' if(s->internal_buffer==NULL){ ^ utils.c:172:30: error: use of undeclared identifier 'NULL' if(buf->base[i]==NULL) return -1; ^ utils.c:198:11: error: use of undeclared identifier 'NULL' buf = NULL; /* avoids warning */ ^ utils.c:213:22: error: use of undeclared identifier 'NULL' pic->data[i]=NULL; ^ utils.c:269:13: error: use of undeclared identifier 'NULL' if(avctx==NULL) return NULL; ^ utils.c:269:26: error: use of undeclared identifier 'NULL' if(avctx==NULL) return NULL; ^ utils.c:287:11: error: use of undeclared identifier 'NULL' if(pic==NULL) return NULL; ^ utils.c:287:24: error: use of undeclared identifier 'NULL' if(pic==NULL) return NULL; ^ fatal error: too many errors emitted, stopping now [-ferror-limit=] 2 warnings and 20 errors generated. make[1]: *** [utils.o] Error 1 make: *** [libavcodec/libavcodec.a] Error 2
comment:2 Changed 13 years ago by neverpanic (Clemens Lang)
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
The problem is setting CFLAGS overwrites the flags the package needs to build. I've only set CC in r92481 and commited the port. It would be desirable for MacPorts to be able to pass in compiler and linker flags to this port's build process, but that would probably require patching the Makefile(s).
comment:3 Changed 13 years ago by paumard
Hi,
Thanks Clemens, I will think of the best way to set compiler flags for yorick plug-ins. I believe the right make variables are Y_LDFLGAS and Y_CFLAGS (those two appear in Yorick's Make.cfg). In the end, we get:
CFLAGS=$(COPT) $(Y_CFLAGS) $(PKG_CFLAGS) $(PLUG) -I. $(Y_IDIR)
in ${prefix}/lib/yorick/Makepkg. PKG_CFLAGS is for package-specific dependencies, COPTS is for optimization flags, Y_FLAGS is for what Yorick believes should be the default flags.
I need to do some slightly time-consuming testing to check that this is the right thing to do and I happen to be getting married on Saturday, so it may take me up to two weeks getting back to you.
At that point, I will certainly open tickets for yorick itself as well as all plug-ins, should I assigned that all to you?
Kind regards, Thibaut.
comment:4 Changed 13 years ago by neverpanic (Clemens Lang)
Yes, feel free to assign those tickets to me.
Congratulations on getting married, take your time and enjoy. :)
yorick-mpeg Portfile