Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Absolute build path to robtk source files ends up in generated binaries #57

Closed
jmaibaum opened this issue Aug 4, 2018 · 1 comment
Closed

Comments

@jmaibaum
Copy link

jmaibaum commented Aug 4, 2018

Hi @x42 ,

while updating the AUR build definitions for setBfree v0.8.7 I have noticed the following output during the package build process (re-testing the previous version v0.8.5 showed that this is not a new issue, it has been there before):

==> Checking for packaging issues...
==> WARNING: Package contains reference to $srcdir
usr/bin/setBfreeUI
usr/bin/x42-whirl
usr/lib/lv2/b_whirl/b_whirlUI_gl.so

greping the installed files from the package with the absolute src path used during build indeed shows these matches:

$ cd /usr
$ grep -R "/home/jm/build/aur-packaging/setbfree/src" * 2>/dev/null | grep matches
Binary file bin/setBfreeUI matches
Binary file bin/x42-whirl matches
Binary file lib/lv2/b_whirl/b_whirlUI_gl.so matches

These matches don't seem to be vital, as running grep on the hexdump only reveals what seem to be mere references to the source files, i.e. it's most probably only debugging info (the other two files have similar matches):

$ xxd lib/lv2/b_whirl/b_whirlUI_gl.so | grep -A5 home
0002baf0: 0000 0000 0000 0000 2f68 6f6d 652f 6a6d  ......../home/jm
0002bb00: 2f62 7569 6c64 2f61 7572 2d70 6163 6b61  /build/aur-packa
0002bb10: 6769 6e67 2f73 6574 6266 7265 652f 7372  ging/setbfree/sr
0002bb20: 632f 7365 7442 6672 6565 2d30 2e38 2e37  c/setBfree-0.8.7
0002bb30: 2f72 6f62 746b 2f67 6c2f 6c61 796f 7574  /robtk/gl/layout
0002bb40: 2e68 0000 0000 0000 726f 6277 6964 6765  .h......robwidge
--
0002bc00: 2f68 6f6d 652f 6a6d 2f62 7569 6c64 2f61  /home/jm/build/a
0002bc10: 7572 2d70 6163 6b61 6769 6e67 2f73 6574  ur-packaging/set
0002bc20: 6266 7265 652f 7372 632f 7365 7442 6672  bfree/src/setBfr
0002bc30: 6565 2d30 2e38 2e37 2f72 6f62 746b 2f75  ee-0.8.7/robtk/u
0002bc40: 695f 676c 2e63 0000 726f 6274 6b3a 206f  i_gl.c..robtk: o
0002bc50: 7065 6e67 6c20 7375 7266 6163 6520 6f75  pengl surface ou
--
0002bcc0: 2f68 6f6d 652f 6a6d 2f62 7569 6c64 2f61  /home/jm/build/a
0002bcd0: 7572 2d70 6163 6b61 6769 6e67 2f73 6574  ur-packaging/set
0002bce0: 6266 7265 652f 7372 632f 7365 7442 6672  bfree/src/setBfr
0002bcf0: 6565 2d30 2e38 2e37 2f72 6f62 746b 2f67  ee-0.8.7/robtk/g
0002bd00: 6c2f 726f 6277 6964 6765 745f 676c 2e68  l/robwidget_gl.h
0002bd10: 0000 0000 0000 0000 2f68 6f6d 652f 6a6d  ......../home/jm
0002bd20: 2f62 7569 6c64 2f61 7572 2d70 6163 6b61  /build/aur-packa
0002bd30: 6769 6e67 2f73 6574 6266 7265 652f 7372  ging/setbfree/sr
0002bd40: 632f 7365 7442 6672 6565 2d30 2e38 2e37  c/setBfree-0.8.7
0002bd50: 2f72 6f62 746b 2f77 6964 6765 7473 2f72  /robtk/widgets/r
0002bd60: 6f62 746b 5f64 6961 6c2e 6800 0000 0000  obtk_dial.h.....
--
0002bd90: 2f68 6f6d 652f 6a6d 2f62 7569 6c64 2f61  /home/jm/build/a
0002bda0: 7572 2d70 6163 6b61 6769 6e67 2f73 6574  ur-packaging/set
0002bdb0: 6266 7265 652f 7372 632f 7365 7442 6672  bfree/src/setBfr
0002bdc0: 6565 2d30 2e38 2e37 2f72 6f62 746b 2f77  ee-0.8.7/robtk/w
0002bdd0: 6964 6765 7473 2f72 6f62 746b 5f73 656c  idgets/robtk_sel
0002bde0: 6563 746f 722e 6800 7077 203e 3d20 7277  ector.h.pw >= rw
--
0002bf70: 3a25 2e31 660a 0000 2f68 6f6d 652f 6a6d  :%.1f.../home/jm
0002bf80: 2f62 7569 6c64 2f61 7572 2d70 6163 6b61  /build/aur-packa
0002bf90: 6769 6e67 2f73 6574 6266 7265 652f 7372  ging/setbfree/sr
0002bfa0: 632f 7365 7442 6672 6565 2d30 2e38 2e37  c/setBfree-0.8.7
0002bfb0: 2f72 6f62 746b 2f67 6c2f 636f 6d6d 6f6e  /robtk/gl/common
0002bfc0: 5f63 676c 2e68 0000 2021 2121 204f 5554  _cgl.h.. !!! OUT
--
0002c020: 2f68 6f6d 652f 6a6d 2f62 7569 6c64 2f61  /home/jm/build/a
0002c030: 7572 2d70 6163 6b61 6769 6e67 2f73 6574  ur-packaging/set
0002c040: 6266 7265 652f 7372 632f 7365 7442 6672  bfree/src/setBfr
0002c050: 6565 2d30 2e38 2e37 2f72 6f62 746b 2f77  ee-0.8.7/robtk/w
0002c060: 6964 6765 7473 2f72 6f62 746b 5f63 6865  idgets/robtk_che
0002c070: 636b 6275 7474 6f6e 2e68 0000 0000 0000  ckbutton.h......

From a quick glance I found an abspath command in:

RW=$(abspath $(ROBTK))/

While deleting the build directory does no harm (i.e. you can still run the apps and the plugin GUI without crashes), as it is to be expected if they are only debugging info, I still wanted to know if/how it would be possible to suppress the adding of the absolute build path to the linked executables and libraries. Users who build this package from the AUR will see those messages and might be thinking that this is a packaging bug.

FYI, the files were already stripped during build (at least stripping them manually after the build has finished doesn't change anything).

@x42
Copy link
Collaborator

x42 commented Aug 4, 2018

Those are from assert (3), define -DNDEBUG and they'll go away.

make OPTIMIZATIONS="-O3 -ffast-math -fomit-frame-pointer -fno-finite-math-only -DNDEBUG"

or if your distro is OK with shipping x86 binaries that support SSE2 or later

make OPTIMIZATIONS="-msse -msse2 -mfpmath=sse -O3 -ffast-math -fomit-frame-pointer -fno-finite-math-only -DNDEBUG"

@x42 x42 closed this as completed Aug 4, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants