[theora-dev] library migration plan

Ralph Giles giles at xiph.org
Tue Oct 9 16:15:37 PDT 2007

Derf (Timothy Terriberry) and I talked about the api transition plan on 
friday. The plan is:

* libtheora will export only the "old" api, as it did in beta1.

* libtheoradec will export both the "new" theora-exp decoder api, and 
the decoder portions of the old api. So libtheoradec will be a drop-in 
replacement for decoder-only usage of libtheora, and the linking change
will be required to use any new api features.

* libtheoraenc will export both the "new" theora-exp encoder api, and 
the encoder portions of the old api. There will be an explicit 
dependency on libtheoradec.

We hope this strikes the right combination between not breaking existing 
code and encouraging people to upgrade.

Since implicit dependencies aren't portable, libtheora will duplicate 
the object code in libtheoradec and libtheoraenc. We don't really mind.

Applications won't be able to link to both the old and new-scheme 
libraries at the same time without confusion. In practice it will
probably be fine because both copies of the "old" api will call 
into their respective copies of the same implementation code.

The "old" api emulation layer is only 9kB, but it would be nice if there 
were a configure-time switch to disable it for embedded builds of 
libtheoradec, like --disable-encode with libtheora.

Anyone wants to make the build system do this, please go ahead. :)


More information about the theora-dev mailing list