Results 1 to 7 of 7

Thread: Can build package with native cmake but failed when using OBS.

  1. #1
    Join Date
    Oct 2018
    Location
    Atlantis
    Posts
    97

    Default Can build package with native cmake but failed when using OBS.

    Hello,

    I have been trying to build tinyspline.
    https://github.com/msteinbeck/tinyspline

    I could not build tinyspline with OBS.
    The fatal error is

    Code:
    [   55s] /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:2069: undefined reference to `sqrt'
    [   55s] /usr/lib64/gcc/x86_64-suse-linux/9/../../../../x86_64-suse-linux/bin/ld: /tmp/libtinyspline.so.zq5CGP.ltrans0.ltrans.o: in function `ts_bspline_interpolate_catmull_rom':
    [   55s] /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:987: undefined reference to `pow'
    [   55s] /usr/lib64/gcc/x86_64-suse-linux/9/../../../../x86_64-suse-linux/bin/ld: /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:988: undefined reference to `pow'
    [   55s] /usr/lib64/gcc/x86_64-suse-linux/9/../../../../x86_64-suse-linux/bin/ld: /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:989: undefined reference to `pow'
    I ask about this error to the author of tinyspline which the author fix it but would not work with OBS.
    https://github.com/msteinbeck/tinyspline/issues/152

    I tried building with normal cmake like wise and it pass.
    Code:
    wget https://github.com/msteinbeck/tinyspline/archive/snapshot.tar.gz
    tar xf snapshot.tar.gz
    cd tinyspline-snapshot
    mkdir build
    cd build
    cmake ..
    cmake --build .
    I don't understand why building with OBS did not work but building with normal cmake work.

    Here is my spec file: https://build.opensuse.org/package/v....spec?expand=1
    Here is the error log: https://build.opensuse.org/package/l...bleweed/x86_64

    Thanks.

  2. #2
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    28,090
    Blog Entries
    15

    Default Re: Can build package with native cmake but failed when using OBS.

    Hi
    When you build without the macro check the cmake, ldflags etc, or just build without the macro. Or work with upstream to review the OBS method and implement changes....
    Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
    SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!

  3. #3
    Join Date
    Oct 2018
    Location
    Atlantis
    Posts
    97

    Default Re: Can build package with native cmake but failed when using OBS.

    Hello,

    Did you mean that the OBS change some flags that make it different from normal cmake and make it failed?

  4. #4
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    28,090
    Blog Entries
    15

    Default Re: Can build package with native cmake but failed when using OBS.

    Quote Originally Posted by andythe_great View Post
    Hello,

    Did you mean that the OBS change some flags that make it different from normal cmake and make it failed?
    Hi
    Yes, but they are checking the code in a more robust way, hence some things fail, which is likely an upstream issue with the pow error.

    There were a few fixes to get libheif building with cmake (working with another user on this)....
    https://github.com/strukturag/libheif/pull/195
    Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
    SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!

  5. #5
    Join Date
    Oct 2018
    Location
    Atlantis
    Posts
    97

    Default Re: Can build package with native cmake but failed when using OBS.

    Quote Originally Posted by malcolmlewis View Post
    Hi
    Yes, but they are checking the code in a more robust way, hence some things fail, which is likely an upstream issue with the pow error.

    There were a few fixes to get libheif building with cmake (working with another user on this)....
    https://github.com/strukturag/libheif/pull/195
    Hello,

    Any suggestion on where to report this issue?

  6. #6
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    28,090
    Blog Entries
    15

    Default Re: Can build package with native cmake but failed when using OBS.

    Hi
    Well it's still missing the -lm link... upstream with the tinyspline dev...

    Code:
    **Working with the c++ link ** Looks like the static link **
    
    [   55s] /usr/bin/c++  -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -g -DNDEBUG -O2 -g -DNDEBUG  -flto=auto -Wl,--as-needed -Wl,--no-undefined -Wl,-z,now CMakeFiles/time_series.dir/time_series.cpp.o  -o time_series  ../../lib/libtinysplinecpp.a -lm
    
    
    **Not working with the cc link ** Looks like the shared link **
    
    [   55s] cd /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/build/src && /usr/bin/cmake -E cmake_link_script CMakeFiles/tinyspline_shared.dir/link.txt --verbose=1
    [   55s] /usr/bin/cc -fPIC -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -g -DNDEBUG -std=c89 -O2 -g -DNDEBUG -flto=auto -Wl,--as-needed -Wl,--no-undefined -Wl,-z,now -lm -shared -Wl,-soname,libtinyspline.so -o ../lib/libtinyspline.so CMakeFiles/tinyspline_shared.dir/tinyspline.c.o CMakeFiles/tinyspline_shared.dir/parson.c.o 
    
    [   55s] /usr/lib64/gcc/x86_64-suse-linux/9/../../../../x86_64-suse-linux/bin/ld: /tmp/libtinyspline.so.zq5CGP.ltrans0.ltrans.o: in function `ts_distance':
    [   55s] /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:2069: undefined reference to `sqrt'
    [   55s] /usr/lib64/gcc/x86_64-suse-linux/9/../../../../x86_64-suse-linux/bin/ld: /tmp/libtinyspline.so.zq5CGP.ltrans0.ltrans.o: in function `ts_bspline_interpolate_catmull_rom':
    [   55s] /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:987: undefined reference to `pow'
    [   55s] /usr/lib64/gcc/x86_64-suse-linux/9/../../../../x86_64-suse-linux/bin/ld: /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:988: undefined reference to `pow'
    [   55s] /usr/lib64/gcc/x86_64-suse-linux/9/../../../../x86_64-suse-linux/bin/ld: /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:989: undefined reference to `pow'
    Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
    SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!

  7. #7
    Join Date
    Oct 2018
    Location
    Atlantis
    Posts
    97

    Default Re: Can build package with native cmake but failed when using OBS.

    Quote Originally Posted by malcolmlewis View Post
    Hi
    Well it's still missing the -lm link... upstream with the tinyspline dev...

    Code:
    **Working with the c++ link ** Looks like the static link **
    
    [   55s] /usr/bin/c++  -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -g -DNDEBUG -O2 -g -DNDEBUG  -flto=auto -Wl,--as-needed -Wl,--no-undefined -Wl,-z,now CMakeFiles/time_series.dir/time_series.cpp.o  -o time_series  ../../lib/libtinysplinecpp.a -lm
    
    
    **Not working with the cc link ** Looks like the shared link **
    
    [   55s] cd /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/build/src && /usr/bin/cmake -E cmake_link_script CMakeFiles/tinyspline_shared.dir/link.txt --verbose=1
    [   55s] /usr/bin/cc -fPIC -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector-strong -funwind-tables -fasynchronous-unwind-tables -fstack-clash-protection -Werror=return-type -flto=auto -g -DNDEBUG -std=c89 -O2 -g -DNDEBUG -flto=auto -Wl,--as-needed -Wl,--no-undefined -Wl,-z,now -lm -shared -Wl,-soname,libtinyspline.so -o ../lib/libtinyspline.so CMakeFiles/tinyspline_shared.dir/tinyspline.c.o CMakeFiles/tinyspline_shared.dir/parson.c.o 
    
    [   55s] /usr/lib64/gcc/x86_64-suse-linux/9/../../../../x86_64-suse-linux/bin/ld: /tmp/libtinyspline.so.zq5CGP.ltrans0.ltrans.o: in function `ts_distance':
    [   55s] /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:2069: undefined reference to `sqrt'
    [   55s] /usr/lib64/gcc/x86_64-suse-linux/9/../../../../x86_64-suse-linux/bin/ld: /tmp/libtinyspline.so.zq5CGP.ltrans0.ltrans.o: in function `ts_bspline_interpolate_catmull_rom':
    [   55s] /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:987: undefined reference to `pow'
    [   55s] /usr/lib64/gcc/x86_64-suse-linux/9/../../../../x86_64-suse-linux/bin/ld: /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:988: undefined reference to `pow'
    [   55s] /usr/lib64/gcc/x86_64-suse-linux/9/../../../../x86_64-suse-linux/bin/ld: /home/abuild/rpmbuild/BUILD/tinyspline-0.2.0+git.1584996308.33462b8/src/tinyspline.c:989: undefined reference to `pow'
    Tinyspline dev told me that they already fix that issue.
    https://github.com/msteinbeck/tinyspline/issues/152

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •