Package: qpxtool
Severity: important
Version: 0.5.3-1
Tags: patch
Hi,
the current version fails to build on GNU/kFreeBSD.
It needs small tweaks to sources.
and slight change to debian packaging.
Please find attached patch with both.
It would also be nice if you can ask upstream
to include source changes.
Thanks in advance
Petr
diff -u qpxtool-0.5.3/debian/control qpxtool-0.5.3/debian/control
--- qpxtool-0.5.3/debian/control
+++ qpxtool-0.5.3/debian/control
@@ -2,7 +2,7 @@
Section: otherosfs
Priority: optional
Maintainer: Daniel Baumann <[EMAIL PROTECTED]>
-Build-Depends: debhelper (>= 4), libqt3-mt-dev
+Build-Depends: debhelper (>= 4), libqt3-mt-dev, libcam-dev [kfreebsd-i386
kfreebsd-amd64]
Standards-Version: 3.7.2
Package: qpxtool
diff -u qpxtool-0.5.3/debian/rules qpxtool-0.5.3/debian/rules
--- qpxtool-0.5.3/debian/rules
+++ qpxtool-0.5.3/debian/rules
@@ -3,6 +3,8 @@
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
+DEB_HOST_ARCH_OS = $(shell dpkg-architecture -qDEB_HOST_ARCH_OS)
+
CFLAGS = -Wall -g
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
@@ -11,13 +13,20 @@
CFLAGS += -O2
endif
+ifeq (kfreebsd,$(DEB_HOST_ARCH_OS))
+ SUBLIBS="-lcam"
+else
+ SUBLIBS=""
+endif
+
+
build: build-stamp
build-stamp:
dh_testdir
# Building package
qmake
- make CFLAGS="$(CFLAGS)"
+ make CFLAGS="$(CFLAGS)" SUBLIBS="$(SUBLIBS)"
touch build-stamp
only in patch2:
unchanged:
--- qpxtool-0.5.3.orig/transport.cpp
+++ qpxtool-0.5.3/transport.cpp
@@ -362,7 +362,7 @@
int Scsi_Command::is_reload_needed ()
{ return 1; }
-#elif defined(__FreeBSD__)
+#elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
#include <sys/ioctl.h>
#include <camlib.h>
only in patch2:
unchanged:
--- qpxtool-0.5.3.orig/transport.h
+++ qpxtool-0.5.3/transport.h
@@ -200,7 +200,7 @@
int is_reload_needed ();
};
-#elif defined(__FreeBSD__)
+#elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
#include <sys/ioctl.h>
#include <stdio.h>
only in patch2:
unchanged:
--- qpxtool-0.5.3.orig/ASDB.h
+++ qpxtool-0.5.3/ASDB.h
@@ -13,6 +13,7 @@
#define __asdb_edit_dialog
#include <stdlib.h>
+#include <stdio.h>
//#include <transport.h>
#include <qpx_mmc.h>
#include <plextor_features.h>