Tomasz Gebarowski

AutoTools, tar and paths longer than 99 characters

I tried to build a Debian package for the project I am currently working on. Unfortunately all the paths I used in the structure of my application were very long. While executing make dist command I got lots of errors similar to the one below:

wzt-poc2/media-server/src/[....]wzt-children-manager/tests/: file name is too long (max > 99); not dumped

I found out that the error is due to the tar archiver. It does not support file names (in fact “paths”) longer than 99 characters. This problem can be easily solved by forcing AutoTools to use POSIX version of tar which does not have this limitation.

It is enough to modify a file in the following way:

AC_INIT([your-application-name], [0.1.0])
AM_INIT_AUTOMAKE([1.9 tar-ustar])

The crucial part is inside the AM_INIT_AUTOMAKE declaration which changes the default tar archiver.