On 04/01/2014 03:31 PM, Jincheng Miao wrote:
On 04/01/2014 02:46 PM, Jincheng Miao wrote:
> On 04/01/2014 06:04 AM, Nehal J Wani wrote:
>> On Sun, Mar 16, 2014 at 1:28 PM, Nehal J Wani
>> <nehaljw.kkd1(a)gmail.com> wrote:
>>> I followed the following steps to build a clean development version of
>>> libvirt from source. Can't seem to understand what is wrong. (Entire
>>> buildLog has been attached):
>>>
>>> ➜ /tmp cat /etc/issue
>>> CentOS release 6.5 (Final)
>
> I can reproduce it on RHEL6.5.
The failure from config.log:
configure:100656: checking for selinux_lxc_contexts_path
configure:100712: gcc -std=gnu99 -o conftest -g -O2 conftest.c -g
-O2 -lselinux >&5
/tmp/ccqcoZgu.o: In function `main':
/root/libvirt/conftest.c:594: undefined reference to
`selinux_lxc_contexts_path'
collect2: ld returned 1 exit status
the libselinux.so belongs to libselinux-2.0.94-5.3.el6_4.1.x86_64, and
this function is not in that library.
Sorry, this is not root cause of this problem: no
libsecurityselinuxhelper.so generated.
The macro HAVE_SELINUX_LXC_CONTEXTS_PATH can handle this no
selinux_lxc_contexts_path problem.
Then I checked the tests/Makefile.am:
936 if WITH_SECDRIVER_SELINUX
937 if WITH_ATTR
938 if WITH_TESTS
939 noinst_LTLIBRARIES += libsecurityselinuxhelper.la
940 else ! WITH_TESTS
941 check_LTLIBRARIES += libsecurityselinuxhelper.la
942 endif ! WITH_TESTS
The libsecurityselinuxhelper.la is surrounded by the macro WITH_ATTR,
so if there is no WITH_ATTR defined, libsecurityselinuxhelper.so will
not be created.
The ad-hoc solution is install libattr-devel, and re-configure.
Best wishes,
Jincheng Miao
>
>>> Kernel \r on an \m
>>> ➜ /tmp sestatus
>>> SELinux status: enabled
>>> SELinuxfs mount: /selinux
>>> Current mode: enforcing
>>> Mode from config file: enforcing
>>> Policy version: 24
>>> Policy from config file: targeted
>>> ➜ /tmp git clone
git://libvirt.org/libvirt.git
>>> Initialized empty Git repository in /tmp/libvirt/.git/
>>> remote: Counting objects: 138935, done.
>>> remote: Compressing objects: 100% (21143/21143), done.
>>> remote: Total 138935 (delta 117282), reused 138935 (delta 117282)
>>> Receiving objects: 100% (138935/138935), 137.72 MiB | 559 KiB/s, done.
>>> Resolving deltas: 100% (117282/117282), done.
>>> ➜ /tmp cd libvirt
>>> ➜ libvirt git:(master) ./autogen.sh --system
>>> Running ./configure with --prefix=/usr --sysconfdir=/etc
>>> --localstatedir=/var --libdir=/usr/lib64
>>> ..
>>> ..
>>> Now type 'make' to compile libvirt.
>>> ➜ libvirt git:(master) make
>>> ..
>>> ..
>>> make[1]: Leaving directory `/tmp/libvirt'
>>> ➜ libvirt git:(master) ✗ cd tests
>>> ➜ tests git:(master) ✗ ./viridentitytest
>>> /tmp/libvirt/tests/.libs/libsecurityselinuxhelper.so: No such file
>>> or directory
>>> ➜ tests git:(master) ✗
>>>
>>>
>>> --
>>> Nehal J Wani
>> Ping!
>>
>
> --
> libvir-list mailing list
> libvir-list(a)redhat.com
>
https://www.redhat.com/mailman/listinfo/libvir-list
--
libvir-list mailing list
libvir-list(a)redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list