pkgsrc-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: misc/libreoffice on i386
Hi,
I am sorry for my late reply.
Ryo ONODERA <ryo%tetera.org@localhost> writes:
> Hi,
>
> Ryo ONODERA <ryo%tetera.org@localhost> writes:
>
>> Hi,
>>
>> Emmanuel Dreyfus <manu%netbsd.org@localhost> writes:
>>
>>> Hello
>>>
>>> Building latest misc/libreoffice on NetBSD-9.3/i386 fail (well, to be
>>> precise, I cross-build it on amd64 using pkg_comp1) because of
>>> undefined reference to '__stack_chk_fail' in configure tests.
>>>
>>> configure stops on atomic tests because the test fails on that missing
>>> symbol, but previous tests failed on that as wekk
>>> on atomic operations tests.
>>>
>>> I worked it around in pkgsrc/misc/libreoffice/Makfile with
>>> CFLAGS.NetBSD+= -fno-stack-protector
>>>
>>> Additionaly, it fails again during the build for the same reason:
>>>
>>> checking thread safety of required library functions... no
>>> configure: error: thread test program failed
>>> This platform is not thread-safe. Check the file 'config.log' or compile
>>> and run src/test/thread/thread_test for the exact reason.
>>> Use --disable-thread-safety to disable thread safety.
>>> gmake[1]: *** [/pkg_comp/obj/pkgsrc/misc/libreoffice/default/libreoffice-24.2.2.2/external/postgresql/ExternalProject_postgresql.mk:65: /pkg_comp/obj/pkgsrc/misc/libreoffice/default/libreoffice-24.2.2.2/workdir/ExternalProject/postgresql/build] Error 1
>>>
>>> I had to patch:
>>>
>>> --- external/postgresql/ExternalProject_postgresql.mk.orig 2024-05-11 06:42:51.776284220 +0200
>>> +++ external/postgresql/ExternalProject_postgresql.mk 2024-05-11 06:43:17.080083653 +0200
>>> @@ -70,9 +70,9 @@
>>> $(gb_CONFIGURE_PLATFORMS) \
>>> $(if $(ENABLE_OPENSSL),--with-openssl \
>>> $(if $(WITH_GSSAPI),--with-gssapi)) \
>>> $(if $(ENABLE_LDAP),,--with-ldap=no) \
>>> - CFLAGS="-fPIC" \
>>> + CFLAGS="-fPIC -fno-stack-protector" \
>>> CPPFLAGS="$(postgresql_CPPFLAGS)" \
>>> LDFLAGS="$(postgresql_LDFLAGS)" \
>>> $(if $(ENABLE_LDAP),EXTRA_LDAP_LIBS="-llber") \
>>> && cd src/interfaces/libpq \
>>>
>>> Of course this is just a useful hack that needs improvement.
>>>
>>> I understand we cannot link code with and witout stack protector. I
>>> suspect it would be a better fix to add -fstack-protector where it
>>> has been missing but I am not sure how to track the missing bit.
>>> Hints welcome.
>>>
>>> There is also a long standing build caveat for libreoffice: if
>>> libnet is installed, at some point in the build we get a link
>>> failure against libnio because there are two different libnio,
>>> one from openjdk and one from libnet. I am not sure how we could
>>> make sure the right one is
>>
>> You should define PKGSRC_USE_SSP=no. I should work like defining
>> -fno-stack-protector in Makefile fragments.
>> However I believe that it is workaround for this problem.
>> I will investigate deeper.
>
> It seems that pkgsrc/lang/gcc12 has a problem.
> pkgsrc/lang/gcc12 does not have enough support
> for -fPIC/-fPIE and -fstack-protector-strong combination.
>
> As far as I remember correctly, I fixed an older gcc package's
> similar problem.
> I will recall the past.
I believe that the current lang/gcc12 will build misc/libreoffice
without problem.
Could you try to build misc/libreoffice from fresh pkgsrc tree again?
Thank you.
>> Thank you.
>>
>>> --
>>> Emmanuel Dreyfus
>>> manu%netbsd.org@localhost
>>
>> --
>> Ryo ONODERA // ryo%tetera.org@localhost
>> PGP fingerprint = 82A2 DC91 76E0 A10A 8ABB FD1B F404 27FA C7D1 15F3
>
> --
> Ryo ONODERA // ryo%tetera.org@localhost
> PGP fingerprint = 82A2 DC91 76E0 A10A 8ABB FD1B F404 27FA C7D1 15F3
--
Ryo ONODERA // ryo%tetera.org@localhost
PGP fingerprint = 82A2 DC91 76E0 A10A 8ABB FD1B F404 27FA C7D1 15F3
Home |
Main Index |
Thread Index |
Old Index