3

I have some files that I would like to install using .deb files created using equivs-build. What I cannot understand is the syntax required in the .equivs file.

This is my file layout:

myapp.equivs
myapp/
  files/
    script.sh

What I want to tell equivs-build is to install the script.sh file at /usr/share/myapp/script.sh. I did some tests, but none of the following syntaxes for Files seems to work as intended.

Test 1

Files: ./myapp/files/script.sh /usr/share/myapp/script.sh

Result: file installed in /usr/share/myapp/script.sh/myapp/files/script.sh.

Test 2

Files: ./demo/files/script.sh /usr/share/myapp/

Result: file installed in /usr/share/myapp/myapp/files/script.sh.

Test 3

Files: ./demo/files/script.sh /usr/share/myapp

Result: file installed in /usr/share/myapp/myapp/files/script.sh.

How can I instruct equivs-build to install a file at an arbitrary location?

2

I have the same problem. I think that equivs was build to create very simple packages only. Not packages with a deeper source directory structure.

As a workaround I "fixed" the equivs-build perl script as follows:

/usr/bin/equivs-build (around line 70):

die "Cannot parse Files line: '$_'\n" unless m:^\s*(\S+)\s+(\S+)/?\s*$:;
#$install_files{"$2/$1"} = $1;
$install_files{"$2"} = $1;    # do not append source path to target path

Now you specify full source and target paths with filename in the control file. I.e.

Files: opt/sounds/test.wav /opt/sounds/test.wav
 opt/sounds/test4.wav /opt/sounds/default.wav

Via that method you can use an arbitrary deep source dir structure. As a benefit you can also specify a different target filename if needed.

Hope that helps.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.