Project

General

Profile

Feature #2272

clarify: why does common_cs.h get installed by debian packaging?

Added by neels about 1 month ago. Updated 24 days ago.

Status:
New
Priority:
High
Assignee:
Category:
-
Target version:
-
Start date:
05/18/2017
Due date:
% Done:

0%

Resolution:
Spec Reference:

Description

openbsc/include/openbsc/common_cs.h is listed as noinst_HEADER.
However, it also appears in debian/openbsc-dev.install and is apparently installed.
This seems to magically work, although it shouldn't.

Related: gsm_data_shared.h includes <openbsc/common_cs.h>.
Related: until recently, the installed files were actually put in '$prefix/openbsc /*', i.e. with a trailing space in 'openbsc '. How did that not break our builds?
Related: when we added rest_octets.h to gsm_data_shared.h, the osmo-bts nightly packages build broke. https://gerrit.osmocom.org/2677

There appears to be some magic going on there that should not happen. Clarify what's going on there and why stuff works despite being broken. When this is done, all installed headers should be listed as such in the Makefile.am, debian should be able to package only installed headers, and a space in the 'openbsc ' installed dir should lead to build failures.

History

#1 Updated by msuraev about 1 month ago

  • Priority changed from Normal to Low

This seems to magically work, although it shouldn't.

Why shouldn't? The obvious answer is that entries in debian/*.install have higher priority than noinst_HEADER. I don't have any reference from debian.org to back this up though - links are appreciated.

until recently, the installed files were actually put in '$prefix/openbsc /*'

Could you be more specific? In which files(s) was extra space? Which commits added/removed it?

all installed headers should be listed as such in the Makefile.am

What for? Aesthetic reasons or there'll be some improvement/fix for some scenario?

debian should be able to package only installed headers

Not sure I'm following this. Isn't it already package installed headers?

Setting priority to low as it might be made obsolete by BSC/MSC split in few months anyway.

#2 Updated by neels about 1 month ago

  • Priority changed from Low to Normal

I think you could find out these things from looking at it more closely, but if you need it spelled out:

  • In my understanding, debian packaging does a 'make install' to a temp dir and can only possibly include files in the package that were installed there during 'make install'. How then can we install a header file that is not listed in Makefile.am as installable. I might be wrong but we should be able to explain what is going on.
  • A 'make install' should essentially be similar to a debian package installation. If we install files in the deb package that we don't from 'make install', that is confusing and wrong IMO. It should match. It should be obvious and not "magic", avoid as much obscurity as you can. I hope you agree there.
  • The gerrit patch that fixes the trailing space: https://gerrit.osmocom.org/2649; correction, missing 'include' path element: $prefix/include/openbsc<space>.
    But the actual question is: why does it not cause the build to fail when the installed headers are basically missing (aka at the wrong path). In other words, it seems that these headers don't even need to be installed in the first place??
  • Finally, common_cs.h wasn't intended to be installed. Why does it need to be installed?

Putting priority back to normal because it should not take long to answer these questions. It is not clear yet when exactly we will move to the split git repositories. I would appreciate if you would clarify this instead of discarding the questions.

#3 Updated by neels 24 days ago

  • Priority changed from Normal to High

Any news here please? To be able to split up the openbsc.git repository, I need to know which dependencies are needed where. Please sort out this uncertainty and let me know the intention, instead of me trying to guess why things are the way they are and possibly breaking things without being aware.

Also available in: Atom PDF