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

Packaging libroadrunner



Hi Kyle,

On Tue, Jan 31, 2017 at 02:03:04PM -0800, Kyle Medley wrote:
> Happy to help 😃 
> I subscribed to the Debian Med mailing list, and I will try to help with any questions you might have.

Thanks for your offer to help which I could need right now.  I was able
to solve some unusual hurdle which was caused by the fact that the
download tarball contains a file .gitattributes that has the annoying
effect to change the line endings of text files when importing the files
in the packaging git.  It would help if you would consider to remove
this file from the download file (since it is not needed there anyway).
Unfortunately I have no idea how this could be done on Github.

While the above is solved I have some further problems.  You just
pointed me to some packaging code inside the libroadrunner archive
(packaging/deb/libroadrunner).  I need to admit that this is only of
little use since it becomes obvious that you do not build the packages
inside an offline chroot which is required per Debian policy.  I've
drawn this conclusion from the fact that several Build-Depends are
missing.  So I'd like you to checkout my first approach to the
packaging.  You can do this by using:

   gbp clone https://anonscm.debian.org/git/debian-med/libroadrunner.git

This is the annonymous checkout.  I'd be actually even more happy if you
would become a member of the Debian Med packaging team and thus gain
commit permissions directly.  The Debian Med policy[2] describes how to
do this and I'm runnining an effort to teach packaging inside the Debian
Med team which is called Mentoring of the Month[3].  I'd consider
libroadrunner a perfect target for you to finalise the package.  Whatever
we do, here are my first problems I have with the package.

When trying to build the above archive by using `gbp buildpackage`
the build log was showing:

CMake Error at cmake/FindLLVM.cmake:159 (STRING):
  string sub-command REGEX, mode REPLACE needs at least 6 arguments total to
  command.
 Call Stack (most recent call first):
  CMakeLists.txt:78 (find_package)

So I added some debug code[4] to the according cmake input file.  The
build log now contains:

cmake .. -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_VERBOSE_MAKEFILE=ON -DCMAKE_BUILD_TYPE=None -DCMAKE_INSTALL_SYSCONFDIR=/etc -DCMAKE_INSTALL_LOCALSTATEDIR=/var -DLLVM_CONFIG_EXECUTABLE=/usr/bin/llvm-config
-DBUILD_PYTHON=TRUE
...
FIXME: Variable LLVM_CONFIG_EXECUTABLE is empty!
llvm-config: unknown component name: jit
FIXME: Variable LLVM_LIBRARIES is empty!

That's somehow suspicious.  I admit I'm not a cmake expert but
LLVM_CONFIG_EXECUTABLE should not be empty.


The second problem is that you are relying on third_party
code which is not available as Debian package.  The said build
ends up in

...
cd /build/libroadrunner-1.4.8/obj-x86_64-linux-gnu/source && /usr/bin/c++   -DBUILD_LLVM -DLIBLAX_STATIC -DLIBSBML_STATIC -DLIBSBML_USE_CPP_NAMESPACE -DPOCO_NO_AUTOMATIC_LIBS -DPOCO_STATIC -DSTATIC_LIBSTRUCT - DSTATIC_NLEQ -DSTATIC_PUGI -DSTATIC_RR -I/build/libroadrunner-1.4.8 -I/build/libroadrunner-1.4.8/third_party -I/usr/include/libxml2 -I/usr/lib/llvm-3.8/include -I/build/libroadrunner-1.4.8/obj-x86_64-linux-gnu/source -I/build/libroadrunner-1.4.8/source/. -I/usr/include/rr-libstruct -I/usr/include/sbml -I/usr/include/cvode  -g -O2 -fdebug-prefix-map=/build/libroadrunner-1.4.8=. -fstack-protector-strong -Wformat -     Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC   -o CMakeFiles/roadrunner-static.dir/rrRoadRunner.cpp.o -c /build/libroadrunner-1.4.8/source/rrRoadRunner.cpp
In file included from /build/libroadrunner-1.4.8/source/rrRoadRunner.cpp:11:0:
/build/libroadrunner-1.4.8/source/rrRoadRunner.h:5:35: fatal error: rr-libstruct/lsMatrix.h: No such file or directory
 #include "rr-libstruct/lsMatrix.h"
                                   ^
compilation terminated.
source/CMakeFiles/roadrunner-static.dir/build.make:233: recipe for target 'source/CMakeFiles/roadrunner-static.dir/rrRoadRunner.cpp.o' failed
make[3]: *** [source/CMakeFiles/roadrunner-static.dir/rrRoadRunner.cpp.o] Error 1


I did some research where to find the file rr-libstruct/lsMatrix.h and
when inspecting your Git repository that contains more code than inside
the release tarball I found a file[5] which says:

/**
 * \author Frank T. Bergmann (fbergman@u.washington.edu)
 * \author     Herbert M. Sauro
 * \author     Ravishankar Rao Vallabhajosyula (developed a previous version of the sructural analysis code)
 *
 * Fixes and improvments: Totte Karsson
 */

In Debian we intend to package third party software separately (if
sensible / possible) and thus I did some web search for the source code
of libstructural.  I came across some kind of homepage of this
project[6] but it is not clear to me how to obtain its source code.

Do you see any chance to obtain this source separately package it
and than simply link libroadrunner against this library?  At least
this would be the Debian way to go.

Kind regards and thanks for your intend to support the packaging

    Andreas.

[1] https://lists.debian.org/debian-mentors/2017/02/msg00002.html
[2] https://debian-med.alioth.debian.org/docs/policy.html
[3] https://wiki.debian.org/DebianMed/MoM
[4] https://anonscm.debian.org/git/debian-med/libroadrunner.git/tree/debian/patches/debug_cmake.patch
[5] https://github.com/AndySomogyi/roadrunner/blob/master/third_party/rr-libstruct/lsLibStructural.h
[6] http://sbw.kgi.edu/fbergman/libstructural-cpp/main.html

-- 
http://fam-tille.de


Reply to: