help-tar
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

transformation file list to create tarball


From: Ed Peschko
Subject: transformation file list to create tarball
Date: Sat, 20 Mar 2021 22:07:16 -0500

All,

I need to be able to take an arbitrary file list and turn it into a
different directory structure in a tar file. Something like this:

my_lib/. --- /opt/local/lib64/l --- dir --- 644
my_lib/lib1.a --- /opt/local/lib64/lib1.a --- file --- 644
my_lib/lib2.so --- /opt/local/lib/lib64/lib2.so --- link ---
/usr/local/lib64/lib2.so.0.0

As it stands, what I've been doing is copying over files from the
source format to a temporary directory with the desired structure and
doing a tar after the copy is done but that is way too slow.

Is there a way to do this in tar? I saw the --transform parameter but
that is not powerful enough because I have thousands of these files.

And if this is not currently possible, how big an effort would it be
to add? I don't have tons of time to spend on this but I'd be willing
to put in some to get it added if there was willingness to accept a
patch.

Any help would be appreciated,

Thanks much,

Ed



reply via email to

[Prev in Thread] Current Thread [Next in Thread]