File: rules

package info (click to toggle)
ophcrack 3.8.0-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 1,752 kB
  • sloc: ansic: 12,036; sh: 3,076; cpp: 2,774; makefile: 183
file content (44 lines) | stat: -rwxr-xr-x 1,362 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#!/usr/bin/make -f
#export DH_VERBOSE=1
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
include /usr/share/dpkg/architecture.mk

BASE_CONFIGURE_FLAGS := --host=$(DEB_HOST_GNU_TYPE) \
                        --build=$(DEB_BUILD_GNU_TYPE) \
                        --prefix=/usr

BUILDDIR_QT5 := $(CURDIR)/debian/tmpdir/qt5
BUILDDIR_CLI := $(CURDIR)/debian/tmpdir/cli
DESTDIR_QT5  := $(CURDIR)/debian/ophcrack
DESTDIR_CLI  := $(CURDIR)/debian/ophcrack-cli

%:
	dh $@

override_dh_auto_configure:
	mkdir -p $(BUILDDIR_QT5)
	mkdir -p $(BUILDDIR_CLI)
	cp -a `ls -d $(CURDIR)/* | grep -v '/debian$$'` $(BUILDDIR_QT5)
	cp -a `ls -d $(CURDIR)/* | grep -v '/debian$$'` $(BUILDDIR_CLI)
	cd $(BUILDDIR_QT5); \
	./configure $(BASE_CONFIGURE_FLAGS) --enable-gui
	cd $(BUILDDIR_CLI); \
	./configure $(BASE_CONFIGURE_FLAGS) --disable-gui

override_dh_auto_build:
	$(MAKE) -C $(BUILDDIR_QT5)
	$(MAKE) -C $(BUILDDIR_CLI)

override_dh_auto_install:
	mkdir -p $(DESTDIR_QT5)/usr/share/pixmaps
	install -D -m 755 $(BUILDDIR_CLI)/src/ophcrack $(DESTDIR_CLI)/usr/bin/ophcrack-cli
	install -D -m 755 $(BUILDDIR_QT5)/src/ophcrack $(DESTDIR_QT5)/usr/bin/ophcrack
	cp $(CURDIR)/src/gui/pixmaps/os.xpm \
		$(DESTDIR_QT5)/usr/share/pixmaps/ophcrack.xpm || exit 1;

override_dh_installchangelogs:
	dh_installchangelogs ChangeLog

override_dh_clean:
	dh_clean
	rm -rf $(CURDIR)/debian/tmpdir