Error in making OsmoNITB on Linux

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/OpenBSC@lists.osmocom.org/.

Neels Hofmeyr nhofmeyr at sysmocom.de
Wed Aug 17 10:56:31 UTC 2016


On Tue, Aug 16, 2016 at 03:07:08PM +0100, Abdulghafar Shabaneh wrote:
> Hi
> 
> How do you include /usr/local by default. Which command is used to do it.

It was right there in my mail:

> # make sure all the libraries will be found -- raspberry pi seems to not
> # include /usr/local by default. Without this I get an error for openbsc's
> make
> # check that the libosmo-abis.so.5 it not found, in the testsuite.log:
> # (note that you have to do this in every shell you open, or include in
> your
> # ~/.profile or something similar.)
> export LD_LIBRARY_PATH=/usr/local/lib

By setting the LD_LIBRARY_PATH environment you tell the linker to look for
installed libraries in /usr/local/lib.  You need to do this in the same
terminal that you use to build openbsc. This is very general build knowledge
and I am starting to repeat myself -- please consult your favorite search
engine on LD_LIBRARY_PATH...

Anyway, you are getting an error that I don't see:

> Making all in libbsc
> make[3]: Entering directory '/home/pi/openbsc/openbsc/src/libbsc'
>   CC       bts_ipaccess_nanobts.o
> bts_ipaccess_nanobts.c: In function ‘ipaccess_sign_link_up’:
> bts_ipaccess_nanobts.c:577:42: error: dereferencing pointer to incomplete
> type
>   bts = find_bts_by_unitid(bsc_gsmnet, dev->site_id, dev->bts_id);
>                                           ^
> bts_ipaccess_nanobts.c:577:56: error: dereferencing pointer to incomplete
> type
>   bts = find_bts_by_unitid(bsc_gsmnet, dev->site_id, dev->bts_id);
>                                                         ^

As I said before, the 'dev' is a struct ipaccess_unit*, and it should
definitely not be an icomplete type. If the file were missing, the compiler
would complain.

You could verify that your osmocom/gsm/ipa.h file includes the definition of
struct ipaccess_unit like this:

struct ipaccess_unit {
        uint16_t site_id;
        uint16_t bts_id;
        uint16_t trx_id;
        char *unit_name;
        char *equipvers;
        char *swversion;
        uint8_t mac_addr[6];
        char *location1;
        char *location2;
        char *serno;
};

Check both in your git clone and what it looks like in
/usr/local/include/osmocom/gsm/ipa.h.

I can't think of any reason why it shouldn't be there if you have indeed
checked out the newest osmocom without local modifications, except maybe that
your disk is full and the header files cannot be written to disk?

Another way to fix this issue might be to 'make uninstall' and rebuild from
scratch, this time with each ./configure adding a prefix arg,
and use root privileges for the install step:

  ./configure --prefix=/usr [...]
  make
  make check
  sudo make install

This way things get installed in /usr and no special measures for /usr/local
should be needed.

In any case, this is all I can do for you from over here. It seems to be a
general problem not related to osmocom specifically.

I hope to have provided enough leads for you to fix it ... it definitely works,
don't give up and let us know of your progress :)

~Neels


-- 
- Neels Hofmeyr <nhofmeyr at sysmocom.de>          http://www.sysmocom.de/
=======================================================================
* sysmocom - systems for mobile communications GmbH
* Alt-Moabit 93
* 10559 Berlin, Germany
* Sitz / Registered office: Berlin, HRB 134158 B
* Geschäftsführer / Managing Directors: Harald Welte
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.osmocom.org/pipermail/openbsc/attachments/20160817/b2af64fd/attachment.bin>


More information about the OpenBSC mailing list