dh_install falha com arquivos ausentes

2

Eu estou tentando construir um deb de uma biblioteca baseada em autotools existente. Estou seguindo o tutorial aqui . Quando eu faço um spkg-buildpackage -us -uc o comando falha com um erro informando que os arquivos estão faltando. Eu estou perplexo, porque o arquivo de criação original é DESTDIR e se eu fizer um cd para o DESTDIR e fizer um ls com a expressão que alega estar falhando, os arquivos que eu espero estão lá.

DESTDIR é /home/me/mypackage-0.2/debian/mypackage e o arquivo perdido é usr/lib/x86_64-linux-gnu/gstreamer-1.0/lib* . Note que este é um plugin gstreamer e é por isso que o patch é um pouco estranho.

mypackage.install

usr/lib/x86_64-linux-gnu/gstreamer-1.0/lib*

Estou ciente de que preciso voltar e obter isso para que isso funcione para outras arquiteturas, mas por enquanto só nos preocupamos com 64 bits.

regras

#!/usr/bin/make -f
# -*- makefile -*-

export DH_VERBOSE=1

%:
        dh $@  --with autotools-dev

saída

dpkg-buildpackage: source package myproject
dpkg-buildpackage: source version 0.2-1
dpkg-buildpackage: source distribution unstable
dpkg-buildpackage: source changed by me <[email protected]>
 dpkg-source --before-build myproject-0.2
dpkg-buildpackage: host architecture amd64
 fakeroot debian/rules clean
dh clean  --with autotools-dev
   dh_testdir
   dh_auto_clean
    make -j1 distclean
make[1]: Entering directory '/home/me/client/debs/myproject-0.2'
Making distclean in src
make[2]: Entering directory '/home/me/client/debs/myproject-0.2/src'
rm -rf .libs _libs
test -z "libgstclient.la" || rm -f libgstclient.la
rm -f ./so_locations
rm -f *.o
rm -f *.lo
rm -f *.tab.c
test -z "" || rm -f
test . = "." || test -z "" || rm -f
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -rf ./.deps
rm -f Makefile
make[2]: Leaving directory '/home/me/client/debs/myproject-0.2/src'
make[2]: Entering directory '/home/me/client/debs/myproject-0.2'
rm -rf .libs _libs
rm -f *.lo
test -z "" || rm -f
test . = "." || test -z "" || rm -f
rm -f config.h stamp-h1
rm -f libtool config.lt
rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
rm -f cscope.out cscope.in.out cscope.po.out cscope.files
make[2]: Leaving directory '/home/me/client/debs/myproject-0.2'
rm -f config.status config.cache config.log configure.lineno config.status.lineno
rm -f Makefile
make[1]: Leaving directory '/home/me/client/debs/myproject-0.2'
   dh_autotools-dev_restoreconfig
    for c_g in 'find . -type f -name config.guess' ; do if test -e "$c_g.dh-orig" ; then mv -f "$c_g.dh-orig" "$c_g" ; fi ; done
    for c_s in 'find . -type f -name config.sub'   ; do if test -e "$c_s.dh-orig" ; then mv -f "$c_s.dh-orig" "$c_s" ; fi ; done
    find . -type f \( -name config.guess.dh-orig -o -name config.sub.dh-orig \) -delete
   dh_clean
    rm -f debian/myproject.substvars
    rm -f debian/myproject.*.debhelper
    rm -rf debian/myproject/
    rm -f debian/*.debhelper.log
    rm -f debian/files
    find .  \( \( -type f -a \
            \( -name '#*#' -o -name '.*~' -o -name '*~' -o -name DEADJOE \
             -o -name '*.orig' -o -name '*.rej' -o -name '*.bak' \
             -o -name '.*.orig' -o -name .*.rej -o -name '.SUMS' \
             -o -name TAGS -o \( -path '*/.deps/*' -a -name '*.P' \) \
            \) -exec rm -f {} + \) -o \
            \( -type d -a -name autom4te.cache -prune -exec rm -rf {} + \) \)
    rm -f *-stamp
 dpkg-source -b myproject-0.2
dpkg-source: info: using source format '3.0 (quilt)'
dpkg-source: info: building myproject using existing ./myproject_0.2.orig.tar.xz
dpkg-source: warning: ignoring deletion of directory autom4te.cache
dpkg-source: warning: ignoring deletion of file autom4te.cache/traces.1
dpkg-source: warning: ignoring deletion of file autom4te.cache/output.1
dpkg-source: warning: ignoring deletion of file autom4te.cache/traces.0
dpkg-source: warning: ignoring deletion of file autom4te.cache/requests
dpkg-source: warning: ignoring deletion of file autom4te.cache/output.0
dpkg-source: info: building myproject in myproject_0.2-1.debian.tar.gz
dpkg-source: info: building myproject in myproject_0.2-1.dsc
 debian/rules build
dh build  --with autotools-dev
   dh_testdir
   dh_autotools-dev_updateconfig
    for c_g in 'find -type f -name config.guess' ; do if ! test -e "$c_g.dh-orig" ; then mv -f "$c_g" "$c_g.dh-orig" ; cp -f /usr/share/misc/config.guess "$c_g" ; fi ; done
    for c_s in 'find -type f -name config.sub'   ; do if ! test -e "$c_s.dh-orig" ; then mv -f "$c_s" "$c_s.dh-orig" ; cp -f /usr/share/misc/config.sub   "$c_s" ; fi ; done
   dh_auto_configure
    ./configure --build=x86_64-linux-gnu --prefix=/usr --includedir=\${prefix}/include --mandir=\${prefix}/share/man --infodir=\${prefix}/share/info --sysconfdir=/etc --localstatedir=/var --libdir=\${prefix}/lib/x86_64-linux-gnu --libexecdir=\${prefix}/lib/x86_64-linux-gnu --disable-maintainer-mode --disable-dependency-tracking
checking for a BSD-compatible install... /usr/bin/install -c
 *** sniping configure output for brevity ***
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing libtool commands
   dh_auto_build
    make -j1
make[1]: Entering directory '/home/me/client/debs/myproject-0.2'
make  all-recursive
make[2]: Entering directory '/home/me/client/debs/myproject-0.2'
Making all in src
make[3]: Entering directory '/home/me/client/debs/myproject-0.2/src'
/bin/bash ../libtool  --tag=CXX --tag=disable-static  --mode=compile g++ -DHAVE_CONFIG_H -I. -I..   -D_FORTIFY_SOURCE=2 -pthread -I/usr/include/gstreamer-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include   -Wall -std=c++11 -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -c -o libgstclient_la-client.lo 'test -f 'client.cpp' || echo './''client.cpp
libtool: compile:  g++ -DHAVE_CONFIG_H -I. -I.. -D_FORTIFY_SOURCE=2 -pthread -I/usr/include/gstreamer-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -Wall -std=c++11 -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -c client.cpp  -fPIC -DPIC -o .libs/libgstclient_la-client.o
/bin/bash ../libtool  --tag=CC --tag=disable-static  --mode=compile gcc -DHAVE_CONFIG_H -I. -I..   -D_FORTIFY_SOURCE=2 -pthread -I/usr/include/gstreamer-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include   -Wall -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -c -o libgstclient_la-gstclient.lo 'test -f 'gstclient.c' || echo './''gstclient.c
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I.. -D_FORTIFY_SOURCE=2 -pthread -I/usr/include/gstreamer-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -Wall -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -Wall -c gstclient.c  -fPIC -DPIC -o .libs/libgstclient_la-gstclient.o
/bin/bash ../libtool  --tag=CXX --tag=disable-static  --mode=compile g++ -DHAVE_CONFIG_H -I. -I..   -D_FORTIFY_SOURCE=2 -pthread -I/usr/include/gstreamer-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include   -Wall -std=c++11 -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -c -o libgstclient_la-Protocol2Muxer.lo 'test -f 'Protocol2Muxer.cpp' || echo './''Protocol2Muxer.cpp
libtool: compile:  g++ -DHAVE_CONFIG_H -I. -I.. -D_FORTIFY_SOURCE=2 -pthread -I/usr/include/gstreamer-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -Wall -std=c++11 -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -c Protocol2Muxer.cpp  -fPIC -DPIC -o .libs/libgstclient_la-Protocol2Muxer.o
/bin/bash ../libtool  --tag=CXX --tag=disable-static  --mode=link g++ -pthread -I/usr/include/gstreamer-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include   -Wall -std=c++11 -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -module -avoid-version -export-symbols-regex _*\(gst_\|Gst\|GST_\).* -Wl,-Bsymbolic-functions -Wl,-z,relro -o libgstclient.la -rpath /usr/lib/x86_64-linux-gnu/gstreamer-1.0 libgstclient_la-client.lo libgstclient_la-gstclient.lo libgstclient_la-Protocol2Muxer.lo -lgstbase-1.0 -lgstcontroller-1.0 -lgstreamer-1.0 -lgobject-2.0 -lglib-2.0    -lprotocol2-session -lprotocol2 -lclientnet -lclient -lssl -lpthread -lstdc++ -levent
libtool: link: /usr/bin/nm -B  .libs/libgstclient_la-client.o .libs/libgstclient_la-gstclient.o .libs/libgstclient_la-Protocol2Muxer.o   | sed -n -e 's/^.*[         ]\([ABCDGIRSTW][ABCDGIRSTW]*\)[         ][      ]*\([_A-Za-z][_A-Za-z0-9]*\)$/  /p' | sed '/ __gnu_lto/d' | /bin/sed 's/.* //' | sort | uniq > .libs/libgstclient.exp
libtool: link: /bin/grep -E -e "_*(gst_|Gst|GST_).*" ".libs/libgstclient.exp" > ".libs/libgstclient.expT"
libtool: link: mv -f ".libs/libgstclient.expT" ".libs/libgstclient.exp"
libtool: link: g++  -fPIC -DPIC -shared -nostdlib /usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu/crti.o /usr/lib/gcc/x86_64-linux-gnu/4.8/crtbeginS.o  .libs/libgstclient_la-client.o .libs/libgstclient_la-gstclient.o .libs/libgstclient_la-Protocol2Muxer.o   -lgstbase-1.0 -lgstcontroller-1.0 -lgstreamer-1.0 -lgobject-2.0 -lglib-2.0 /usr/local/lib/libprotocol2-session.so /usr/local/lib/libprotocol2.so /usr/local/lib/libclientnet.so /usr/local/lib/libclient.so -lssl -lpthread /usr/local/lib/libevent.so -L/usr/lib/gcc/x86_64-linux-gnu/4.8 -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../../../lib -L/lib/x86_64-linux-gnu -L/lib/../lib -L/usr/lib/x86_64-linux-gnu -L/usr/lib/../lib -L/usr/lib/gcc/x86_64-linux-gnu/4.8/../../.. -lstdc++ -lm -lc -lgcc_s /usr/lib/gcc/x86_64-linux-gnu/4.8/crtendS.o /usr/lib/gcc/x86_64-linux-gnu/4.8/../../../x86_64-linux-gnu/crtn.o  -pthread -O2 -Wl,-Bsymbolic-functions -Wl,-z -Wl,relro   -pthread -Wl,-soname -Wl,libgstclient.so -Wl,-retain-symbols-file -Wl,.libs/libgstclient.exp -o .libs/libgstclient.so
libtool: link: ( cd ".libs" && rm -f "libgstclient.la" && ln -s "../libgstclient.la" "libgstclient.la" )
make[3]: Leaving directory '/home/me/client/debs/myproject-0.2/src'
make[3]: Entering directory '/home/me/client/debs/myproject-0.2'
make[3]: Nothing to be done for 'all-am'.
make[3]: Leaving directory '/home/me/client/debs/myproject-0.2'
make[2]: Leaving directory '/home/me/client/debs/myproject-0.2'
make[1]: Leaving directory '/home/me/client/debs/myproject-0.2'
   dh_auto_test
    make -j1 check
make[1]: Entering directory '/home/me/client/debs/myproject-0.2'
Making check in src
make[2]: Entering directory '/home/me/client/debs/myproject-0.2/src'
make[2]: Nothing to be done for 'check'.
make[2]: Leaving directory '/home/me/client/debs/myproject-0.2/src'
make[2]: Entering directory '/home/me/client/debs/myproject-0.2'
make[2]: Nothing to be done for 'check-am'.
make[2]: Leaving directory '/home/me/client/debs/myproject-0.2'
make[1]: Leaving directory '/home/me/client/debs/myproject-0.2'
 fakeroot debian/rules binary
dh binary  --with autotools-dev
   dh_testroot
   dh_prep
    rm -f debian/myproject.substvars
    rm -f debian/myproject.*.debhelper
    rm -rf debian/myproject/
   dh_installdirs
    install -d debian/myproject
    install -d debian/myproject/usr/lib/x86_64-linux-gnu/gstreamer-1.0
   dh_auto_install
    make -j1 install DESTDIR=/home/me/client/debs/myproject-0.2/debian/myproject AM_UPDATE_INFO_DIR=no
make[1]: Entering directory '/home/me/client/debs/myproject-0.2'
Making install in src
make[2]: Entering directory '/home/me/client/debs/myproject-0.2/src'
make[3]: Entering directory '/home/me/client/debs/myproject-0.2/src'
make[3]: Nothing to be done for 'install-exec-am'.
 /bin/mkdir -p '/home/me/client/debs/myproject-0.2/debian/myproject/usr/lib/x86_64-linux-gnu/gstreamer-1.0'
 /bin/bash ../libtool   --mode=install /usr/bin/install -c   libgstclient.la '/home/me/client/debs/myproject-0.2/debian/myproject/usr/lib/x86_64-linux-gnu/gstreamer-1.0'
libtool: install: /usr/bin/install -c .libs/libgstclient.so /home/me/client/debs/myproject-0.2/debian/myproject/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstclient.so
libtool: install: /usr/bin/install -c .libs/libgstclient.lai /home/me/client/debs/myproject-0.2/debian/myproject/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstclient.la
libtool: install: warning: remember to run 'libtool --finish /usr/lib/x86_64-linux-gnu/gstreamer-1.0'
make[3]: Leaving directory '/home/me/client/debs/myproject-0.2/src'
make[2]: Leaving directory '/home/me/client/debs/myproject-0.2/src'
make[2]: Entering directory '/home/me/client/debs/myproject-0.2'
make[3]: Entering directory '/home/me/client/debs/myproject-0.2'
make[3]: Nothing to be done for 'install-exec-am'.
make[3]: Nothing to be done for 'install-data-am'.
make[3]: Leaving directory '/home/me/client/debs/myproject-0.2'
make[2]: Leaving directory '/home/me/client/debs/myproject-0.2'
make[1]: Leaving directory '/home/me/client/debs/myproject-0.2'
   dh_install
dh_install: myproject missing files (usr/lib/x86_64-linux-gnu/gstreamer-1.0/lib*), aborting
make: *** [binary] Error 2
dpkg-buildpackage: error: fakeroot debian/rules binary gave error exit status 2

saída de find . no diretório debian

./myproject.dirs
./myproject
./myproject/usr
./myproject/usr/lib
./myproject/usr/lib/x86_64-linux-gnu
./myproject/usr/lib/x86_64-linux-gnu/gstreamer-1.0
./myproject/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstclient.so
./myproject/usr/lib/x86_64-linux-gnu/gstreamer-1.0/libgstclient.la
./myproject.install
./rules
./compat
./source
./source/format
./myproject.debhelper.log
./changelog
./copyright
./control
    
por Yaur 12.08.2015 / 02:22

1 resposta

3

Os caminhos do arquivo install devem ser relativos ao diretório do pacote (que contém debian/ ) e não ao debian/myproject , a menos que você tenha usado a opção -B . De man dh_install :

FILES
   debian/package.install
       List the files to install into each package and the directory they
       should be installed to. The format is a set of lines, where each
       line lists a file or files to install, and at the end of the line
       tells the directory it should be installed in. The name of the
       files (or directories) to install should be given relative to the
       current directory, while the installation directory is given
       relative to the package build directory. You may use wildcards in
       the names of the files to install (in v3 mode and above).

Em vez disso, tente:

debian/myproject/usr/lib/x86_64-linux-gnu/gstreamer-1.0/lib*
    
por muru 13.08.2015 / 05:47

Tags