[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#827082: RFS: libredjackipset/1.1.1+20150311-1 [ITP] -- C library to store sets/maps of IP address



Hi Roger

>> cat debian/libcorkipset-doc.docs

>> build-*/docs/html
>
>Debian builds obj-<multi-arch> by default.
>So it seems to specify "--builddirectory=build" safe for both debian and ubuntu.


yes, but useless...
maybe you didn't get completely the hint, but my guess was:

remove the --builddirectory stuff
and change 

build/docs/html

to
build-*/docs/html

probably this sounds stupid/nitpick to you, but allows
people to easily cross-compile stuff, or to compile the library for
both amd64 and i386 without having to choose one or the other.
that triplet is trivial, and makes less confusion to porters
or even developer, who might want to build it on their own laptop
and use on different architectures.


(note: this isn't a blocker)

>Yes, upstream just don't like calling it libredjackipset.
>They seems fine with libcorkipset, but proposed another option: libipaddrset


I'll wait for them make a decision then

>I don't like the latter one because the header will be installed to
>/usr/include/libipaddrset/ipset.h
>and user need to "#include <libipaddrset/ipset.h>"
>
>I think "#include <libcorkipset/ipset.h>" makes more sense.


just explain that upstream :)

I honestly don't care too much, but I want to use the name that upstream choose
to avoid overcomplicate things in the long run


>"LIB_SUFFIX" is added to patch.


bad me, it didn't work :(
the patch wasn't correct, because the variable gets overridden anyway on the following line.

I tweaked the patch, to do something like
+if(NOT CMAKE_INSTALL_LIBDIR)
+    set(CMAKE_INSTALL_LIBDIR lib CACHE STRING
+         "The base name of the installation directory for libraries")
+endif(NOT CMAKE_INSTALL_LIBDIR)


otherwise no matter who sets it, it gets defaulted to what upstream thinks it is better for everybody.


BTW I can't run dpkg-buildpackage twice, because a "RELEASE-VERSION" file is added to the source
tree

echo RELEASE-VERSION > debian/clean might just fix that

so, please consider applying my above fixes, and ask me to sponsor&upload&review
when upstream releases a new fixed renamed tarball
(this should even avoid your dh_install override if I'm correctly understanding it)

Gianfranco
From: Roger Shimizu <rogershimizu@gmail.com>
Date: Sat, 11 Jun 2016 23:37:44 +0900
Subject: add library multi-arch support

Followed the instruction:
  https://wiki.debian.org/Multiarch/Implementation#CMake
---
 CMakeLists.txt         | 4 +++-
 include/CMakeLists.txt | 2 +-
 src/ipset.pc.in        | 4 ++--
 3 files changed, 6 insertions(+), 4 deletions(-)

--- libcorkipset-1.1.1+20150311.orig/CMakeLists.txt
+++ libcorkipset-1.1.1+20150311/CMakeLists.txt
@@ -78,8 +78,12 @@ if(NOT CMAKE_BUILD_TYPE)
         FORCE)
 endif(NOT CMAKE_BUILD_TYPE)
 
-set(CMAKE_INSTALL_LIBDIR lib CACHE STRING
-    "The base name of the installation directory for libraries")
+include(GNUInstallDirs)
+
+if(NOT CMAKE_INSTALL_LIBDIR)
+    set(CMAKE_INSTALL_LIBDIR lib CACHE STRING
+         "The base name of the installation directory for libraries")
+endif(NOT CMAKE_INSTALL_LIBDIR)
 
 if(CMAKE_C_COMPILER_ID STREQUAL "GNU")
     add_definitions(-Wall -Werror)
diff --git a/include/CMakeLists.txt b/include/CMakeLists.txt
index d1e4a7d..097b775 100644
--- a/include/CMakeLists.txt
+++ b/include/CMakeLists.txt
@@ -8,5 +8,5 @@
 # ----------------------------------------------------------------------
 
 install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/
-    DESTINATION include
+    DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}"
     FILES_MATCHING PATTERN "*.h")
diff --git a/src/ipset.pc.in b/src/ipset.pc.in
index 47a6637..0f8fd84 100644
--- a/src/ipset.pc.in
+++ b/src/ipset.pc.in
@@ -1,7 +1,7 @@
 prefix=@prefix@
 exec_prefix=${prefix}
-libdir=${exec_prefix}/lib
-includedir=${prefix}/include
+libdir=${exec_prefix}/@CMAKE_INSTALL_LIBDIR@
+includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@
 sharedir=${prefix}/share
 sphinxdir=${sharedir}/doc/libcorkipset-doc/html
 

Reply to: