ffmpeg mingw woe

CC libavcodec/x86/diracdsp_mmx.o
make: *** No rule to make target `libavcodec/x86/dnxhdenc.c’, needed by `libavcodec/x86/dnxhdenc.o’. Stop.
make: *** Waiting for unfinished jobs….
YASM libavcodec/x86/diracdsp_yasm.o
STRIP libavcodec/x86/diracdsp_yasm.o
bash-3.1$ make
AR libavdevice/libavdevice.a
AR libavfilter/libavfilter.a
AR libavformat/libavformat.a
make: *** No rule to make target `libavcodec/x86/dnxhdenc.c’, needed by `libavcodec/x86/dnxhdenc.o’. Stop.
bash-3.1$

 

overcame by “make clean” then “make -j 1″ (instead of make -j 2 which is multi process).

Hunch is the former fixed it possibly [?]

hibernate using too much cpu for large queries/taking too long

“main” prio=10 tid=0x00007f139800b800 nid=0x6197 runnable [0x00007f139ce13000]
java.lang.Thread.State: RUNNABLE
at java.util.Arrays.fill(Arrays.java:2169)
at java.util.HashMap.clear(HashMap.java:739)
at org.hibernate.engine.internal.StatefulPersistenceContext.clear(StatefulPersistenceContext.java:242)
at org.hibernate.internal.SessionImpl.cleanup(SessionImpl.java:657)
at org.hibernate.internal.SessionImpl.close(SessionImpl.java:368)

 

or
“main” prio=10 tid=0x00007f139800b800 nid=0x6197 runnable [0x00007f139ce13000]
java.lang.Thread.State: RUNNABLE
at org.familysearch.digitalarchive.presdb.Tape_$$_jvst9e4_4.getHibernateLazyInitializer(Tape_$$_jvst9e4_4.java)
at org.hibernate.engine.internal.StatefulPersistenceContext.clear(StatefulPersistenceContext.java:236)
at org.hibernate.internal.SessionImpl.cleanup(SessionImpl.java:657)
at org.hibernate.internal.SessionImpl.close(SessionImpl.java:368)
at org.familysearch.digitalarchive.presdb.TapeDB.commitAndClose(TapeDB.java:365)
at org.familysearch.digitalarchive.presdb.TapeDB.getAllStreamRefsInRange(TapeDB.java:489)
at org.familysearch.digitalarchive.dpspresmonitor.audit.AuditSdbToStorageDb.getRangeInDps(AuditSdbToStorageDb.java:78)
at org.familysearch.digitalarchive.dpspresmonitor.audit.AuditSdbToStorageDb.processRangeSdbNotOnTapeDb(AuditSdbToStorageDb.java:68)
at org.familysearch.digitalarchive.dpspresmonitor.audit.AuditSdbToStorageDb.findAllSdbFileRefsNotInTapeDb(AuditSdbToStorageDb.java:53)
at org.familysearch.digitalarchive.dpspresmonitor.audit.AuditSdbToStorageDb.doStreamsAbsentFromTapeDb(AuditSdbToStorageDb.java:129)
at org.familysearch.digitalarchive.dpspresmonitor.audit.AuditSdbToStorageDb.runAllAudits(AuditSdbToStorageDb.java:210)
at org.familysearch.digitalarchive.dpspresmonitor.audit.AuditSdbToStorageDb.main(AuditSdbToStorageDb.java:199)

 

or

 

at org.hibernate.engine.internal.EntityEntryContext.addEntityEntry(EntityEntryContext.java:92)
at org.hibernate.engine.internal.StatefulPersistenceContext.addEntry(StatefulPersistenceContext.java:555)
at org.hibernate.engine.internal.StatefulPersistenceContext.addEntity(StatefulPersistenceContext.java:505)
at org.hibernate.engine.internal.TwoPhaseLoad.addUninitializedEntity(TwoPhaseLoad.java:350)
at org.hibernate.loader.Loader.loadFromResultSet(Loader.java:1659)
at org.hibernate.loader.Loader.instanceNotYetLoaded(Loader.java:1605)
at org.hibernate.loader.Loader.getRow(Loader.java:1505)
at org.hibernate.loader.Loader.getRowFromResultSet(Loader.java:713)
at org.hibernate.loader.Loader.processResultSet(Loader.java:943)
at org.hibernate.loader.Loader.doQuery(Loader.java:911)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:342)
at org.hibernate.loader.Loader.doList(Loader.java:2526)
at org.hibernate.loader.Loader.doList(Loader.java:2512)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2342)
at org.hibernate.loader.Loader.list(Loader.java:2337)
at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:495)
at org.hibernate.hql.internal.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:357)
at org.hibernate.engine.query.spi.HQLQueryPlan.performList(HQLQueryPlan.java:195)
at org.hibernate.internal.SessionImpl.list(SessionImpl.java:1275)
at org.hibernate.internal.QueryImpl.list(QueryImpl.java:101)

or
“main” prio=10 tid=0x00007f139800b800 nid=0x6197 runnable [0x00007f139ce12000]
java.lang.Thread.State: RUNNABLE
at java.lang.System.identityHashCode(Native Method)
at java.util.IdentityHashMap.hash(IdentityHashMap.java:301)
at java.util.IdentityHashMap.get(IdentityHashMap.java:334)
at org.hibernate.engine.internal.EntityEntryContext.addEntityEntry(EntityEntryContext.java:92)
at org.hibernate.engine.internal.StatefulPersistenceContext.addEntry(StatefulPersistenceContext.java:555)
at org.hibernate.engine.internal.StatefulPersistenceContext.addEntity(StatefulPersistenceContext.java:505)
2015-04-16 16:53:43

taking too long?

Maybe you can use a stateless session instead? or possibly scrollable?

or possibly set your jdbc connection ResultSet to just “scrollable only” or some odd?

hibernate java out of RAM

turns out that hibernate has its own big “cache” for a session, which can add “lots” of in memory objects if you save a large collection [triple your RAM usage?]

fix/work around:

 

iterate over the collection like this instead of saving the full object, save the pieces separately :|

for (StreamRef s : t.getStreams()) {
  session.save(s);
  if ((processingCount++ % 51) == 0) {
    // keeps memory/RAM usage low (the clear), *and* supports batched inserts (the flush) http://stackoverflow.com/questions/14329396/how-is-hibernate-able-to-throw-a-nonuniqueobjectexception-with-setcachemodecach
    session.flush();
    session.clear(); // clear internal state tracking
  }
}

postgres weirdness

If anybody has a fix, chime in here…
BUILD FAILED
org.postgresql.util.PSQLException: ERROR: Unsupported startup parameter: search_path
at org.postgresql.core.v3.ConnectionFactoryImpl.doAuthentication(ConnectionFactoryImpl.java:420)
at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:195)
at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:66)
at org.postgresql.jdbc2.AbstractJdbc2Connection.<init>(AbstractJdbc2Connection.java:127)
at org.postgresql.jdbc3.AbstractJdbc3Connection.<init>(AbstractJdbc3Connection.java:29)
at org.postgresql.jdbc3g.AbstractJdbc3gConnection.<init>(AbstractJdbc3gConnection.java:21)
at org.postgresql.jdbc4.AbstractJdbc4Connection.<init>(AbstractJdbc4Connection.java:41)
at org.postgresql.jdbc4.Jdbc4Connection.<init>(Jdbc4Connection.java:24)
at org.postgresql.Driver.makeConnection(Driver.java:414)
at org.postgresql.Driver.connect(Driver.java:282)

https://jdbc.postgresql.org/documentation/changelog.html

maybe this meant “it is not using a v3 parameter” or some odd? huh wuh? schemaLocation in url

Setting the search_path from currentSchema property is done in startup packet (v3 protocol only)

 

ant anttask

BUILD FAILED
/home/packrd/Database.5.1/postgres/build.xml:120: The following error occurred while executing this line:
/home/packrd/Database.5.1/postgres/build.xml:92: The following error occurred while executing this line:
/home/packrd/Database.5.1/postgres/build.xml:42: exec returned: 2

meant “that command failed” (look at the bottom one — build.xml 42 in this case — for details).

mingw cross compile woe

cd soxr-0.1.0-Source
depbase=`echo bs2bstream.o | sed ‘s|[^/]*$|.deps/&|;s|\.o$||’`;\
i686-w64-mingw32-gcc -DPACKAGE_NAME=\”libbs2b\” -DPACKAGE_TARNAME=\”libbs2b\” -DPACKAGE_VERSION=\”3.1.0\” -DPACKAGE_STRING=\”libbs2b\ 3.1.0\” -DPACKAGE_BUGREPORT=\”boris_mikhaylov@users.sourceforge.net\” -DPACKAGE=\”libbs2b\” -DVERSION=\”3.1.0\” -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DHAVE_FCNTL_H=1 -DHAVE_MALLOC_H=1 -DHAVE_STRING_H=1 -DHAVE__BOOL=1 -DHAVE_STDBOOL_H=1 -DHAVE_STDLIB_H=1 -DHAVE_MALLOC=0 -Dmalloc=rpl_malloc -DHAVE_STRRCHR=1 -I. -g -O2 -MT bs2bstream.o -MD -MP -MF $depbase.Tpo -c -o bs2bstream.o bs2bstream.c &&\
mv -f $depbase.Tpo $depbase.Po
i686-w64-mingw32-gcc -DPACKAGE_NAME=\”libbs2b\” -DPACKAGE_TARNAME=\”libbs2b\” -DPACKAGE_VERSION=\”3.1.0\” “-DPACKAGE_STRING=\”libbs2b 3.1.0\”” -DPACKAGE_BUGREPORT=\”boris_mikhaylov@users.sourceforge.net\” -DPACKAGE=\”libbs2b\” -DVERSION=\”3.1.0\” -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DHAVE_FCNTL_H=1 -DHAVE_MALLOC_H=1 -DHAVE_STRING_H=1 -DHAVE__BOOL=1 -DHAVE_STDBOOL_H=1 -DHAVE_STDLIB_H=1 -DHAVE_MALLOC=0 -Dmalloc=rpl_malloc -DHAVE_STRRCHR=1 -I. -g -O2 -MT bs2b.lo -MD -MP -MF .deps/bs2b.Tpo -c bs2b.c -o bs2b.o
i686-w64-mingw32-g++ -DPACKAGE_NAME=\”libbs2b\” -DPACKAGE_TARNAME=\”libbs2b\” -DPACKAGE_VERSION=\”3.1.0\” “-DPACKAGE_STRING=\”libbs2b 3.1.0\”” -DPACKAGE_BUGREPORT=\”boris_mikhaylov@users.sourceforge.net\” -DPACKAGE=\”libbs2b\” -DVERSION=\”3.1.0\” -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DHAVE_FCNTL_H=1 -DHAVE_MALLOC_H=1 -DHAVE_STRING_H=1 -DHAVE__BOOL=1 -DHAVE_STDBOOL_H=1 -DHAVE_STDLIB_H=1 -DHAVE_MALLOC=0 -Dmalloc=rpl_malloc -DHAVE_STRRCHR=1 -I. -g -O2 -MT bs2bclass.lo -MD -MP -MF .deps/bs2bclass.Tpo -c bs2bclass.cpp -o bs2bclass.o
/bin/sh ../libtool –tag=CXX –mode=link i686-w64-mingw32-g++ -g -O2 -lm -version-info 0:0:0 -o libbs2b.la -rpath /Users/packrd/dev/ruby/ffmpeg-windows-build-helpers/sandbox/mingw-w64-i686/i686-w64-mingw32/lib bs2b.lo bs2bclass.lo
mkdir .libs
libtool: link: warning: undefined symbols not allowed in i686-w64-mingw32 shared libraries
i686-w64-mingw32-ar cru .libs/libbs2b.a bs2b.o bs2bclass.o
i686-w64-mingw32-ranlib .libs/libbs2b.a
creating libbs2b.la
(cd .libs && rm -f libbs2b.la && ln -s ../libbs2b.la libbs2b.la)
/bin/sh ../libtool –tag=CC –mode=link i686-w64-mingw32-gcc -g -O2 -lsndfile -o bs2bconvert.exe bs2bconvert.o libbs2b.la
/bin/sh ../libtool –tag=CC –mode=link i686-w64-mingw32-gcc -g -O2 -o bs2bstream.exe bs2bstream.o libbs2b.la
i686-w64-mingw32-gcc -g -O2 -o bs2bstream.exe bs2bstream.o ./.libs/libbs2b.a
./.libs/libbs2b.a(bs2b.o): In function `bs2b_open':
/Users/packrd/dev/ruby/ffmpeg-windows-build-helpers/sandbox/win32/libbs2b-3.1.0/src/bs2b.c:225: undefined reference to `rpl_malloc’
collect2: error: ld returned 1 exit status
make[1]: *** [bs2bstream.exe] Error 1
make[1]: *** Waiting for unfinished jobs….
i686-w64-mingw32-gcc -g -O2 -o bs2bconvert.exe bs2bconvert.o /Users/packrd/dev/ruby/ffmpeg-windows-build-helpers/sandbox/mingw-w64-i686/i686-w64-mingw32/lib/libsndfile.a ./.libs/libbs2b.a
./.libs/libbs2b.a(bs2b.o): In function `bs2b_open':
/Users/packrd/dev/ruby/ffmpeg-windows-build-helpers/sandbox/win32/libbs2b-3.1.0/src/bs2b.c:225: undefined reference to `rpl_malloc’
collect2: error: ld returned 1 exit status
make[1]: *** [bs2bconvert.exe] Error 1
make: *** [all-recursive] Error 1

 

meant:

 

yikes

http://e2e.ti.com/support/dsp/omap_applications_processors/f/447/t/28450