On Thu, 2 Mar 2023, Konstantin Kletschke wrote:

In debian/rules is:

#!/usr/bin/make -f

DH_VERBOSE=1

%:
        dh $@
clean:
        @# Do nothing

build:
        @# Do nothing

binary:
        mkdir -p debian/loqitmon
        mkdir -p debian/loqitmon/usr/
        mkdir -p debian/loqitmon/usr/bin
        cp loqitmon.py debian/loqitmon/usr/bin/loqitmon
        mkdir -p debian/loqitmon/etc
        cp loqitmon.ini debian/loqitmon/etc
        cp loqitmonaction1 debian/loqitmon/usr/bin
        cp loqitmonaction2 debian/loqitmon/usr/bin
        cp loqitmonaction3 debian/loqitmon/usr/bin
        cp loqitmonstep1 debian/loqitmon/usr/bin
        cp loqitmonstep2 debian/loqitmon/usr/bin
        cp loqitmonstep3 debian/loqitmon/usr/bin
        dh_installinit
        dh_installsystemd
        dh_gencontrol
        dh_install
        dh_auto_install
        dh_builddeb


I'm no expert. Have you tried manually setting up the directory
structure then using the default dh $@ instead of overriding the binary
step?

I wonder if you're missing something - the error about conffiles is
suspicious, I think that should be automatic.


This is a layout of one of my simple deb-src packages:

apt-mirror@aptmirror17:/mnt/mirror/ftp/mirror/local/pool/main/b/backup
(none)$ tar tvJf backup_1.11+tjw99r1.tar.xz
drwxr-xr-x 0/0               0 2022-05-06 17:52 package/
-rw-r--r-- 0/0             213 2022-04-29 18:02 package/Makefile
drwxr-xr-x 0/0               0 2022-10-12 06:43 package/debian/
-rw-r--r-- 0/0              57 2022-05-07 08:20 package/debian/backup.install
-rw-r--r-- 0/0            1499 2022-10-12 06:43 package/debian/changelog
-rw-r--r-- 0/0               3 2022-04-28 22:32 package/debian/compat
-rw-r--r-- 0/0             337 2022-04-28 22:32 package/debian/control
-rw-r--r-- 0/0            1307 2022-04-28 22:03 package/debian/copyright
-rwxr-xr-x 0/0             298 2021-03-13 20:40 package/debian/postinst
-rwxr-xr-x 0/0             438 2021-03-02 17:40 package/debian/postrm
-rwxr-xr-x 0/0             548 2022-04-29 17:45 package/debian/rules
drwxr-xr-x 0/0               0 2022-05-06 17:52 package/debian/source/
-rw-r--r-- 0/0              13 2021-03-02 17:40 package/debian/source/format
drwxr-xr-x 0/0               0 2021-03-02 17:40 package/src/
drwxr-xr-x 0/0               0 2021-03-02 17:40 package/src/etc/
drwxr-xr-x 0/0               0 2022-05-06 17:51 package/src/etc/backup/
-rw-r--r-- 0/0            2752 2021-11-07 10:46 
package/src/etc/backup/backup.conf
drwxr-xr-x 0/0               0 2022-08-20 07:09 package/src/etc/cron.d/
-rw-r--r-- 0/0             145 2021-06-22 07:00 package/src/etc/cron.d/backup
drwxr-xr-x 0/0               0 2021-03-02 17:40 package/src/usr/
drwxr-xr-x 0/0               0 2022-09-27 03:26 package/src/usr/sbin/
-rwxr-xr-x 0/0            4081 2022-09-27 03:21 package/src/usr/sbin/backup

This is all that that Makefile does:
apt-mirror@aptmirror17:/mnt/mirror/local-debs/main/b/backup/package (master)$ 
cat Makefile
.PHONY: all install

FILES ::= $(shell [ -d src ] && find src -mindepth 1 -maxdepth 1 )

all:

install:
ifdef FILES
        mkdir -p $(DESTDIR)
        for i in $(FILES); do \
          cp -dR $$i $(DESTDIR)/$${i#src/}; \
        done
endif

And this is the content of debian/rules:
apt-mirror@aptmirror17:/mnt/mirror/local-debs/main/b/backup/package (master)$ 
cat debian/rules
#!/usr/bin/make -f
# See debhelper(7) (uncomment to enable)
# output every command that modifies files on the build system.
#export DH_VERBOSE = 1


# see FEATURE AREAS in dpkg-buildflags(1)
#export DEB_BUILD_MAINT_OPTIONS = hardening=+all

# see ENVIRONMENT in dpkg-buildflags(1)
# package maintainers to append CFLAGS
#export DEB_CFLAGS_MAINT_APPEND  = -Wall -pedantic
# package maintainers to append LDFLAGS
#export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed


%:
        dh $@

override_dh_auto_install:
        $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp



And here is the .install file:
apt-mirror@aptmirror17:/mnt/mirror/local-debs/main/b/backup/package (master)$ 
cat debian/backup.install
etc/backup/backup.conf
etc/cron.d/backup
usr/sbin/backup




Reply via email to