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

Binary #1

Open
thany opened this issue Jun 11, 2018 · 2 comments
Open

Binary #1

thany opened this issue Jun 11, 2018 · 2 comments

Comments

@thany
Copy link

thany commented Jun 11, 2018

Please release binaries 🙏

I'm sure you (author) tests whether the source code can build or not, so why not make the result of that available to everyone? I personally don't have build tools on my pc, just like many other people who just need this lib as a plugin for something.

@kobellem
Copy link

kobellem commented Oct 8, 2019

Binaries would be great.
Or at least a release tag (can be alpha/beta), that way users can ensure compablility with other applications. As a workaround I'll be using a commit sha to ensure we're always using the same code-base, but a tag would be preferred.

milianw added a commit to KDABLabs/jxrlib that referenced this issue Jun 7, 2021
Use memcpy instead to ensure that we don't get warnings about
unaligned loads from UBSAN:

```
../3rdParty/jxrlib/image/decode/segdec.c:66:12: runtime error: load of misaligned address 0x7fc3a0544006 for type 'U32', which requires 4 byte alignment
0x7fc3a0544006: note: pointer points here
 01 01 a5 c0 b0 7c  0a 06 05 00 0c 14 10 c2  c0 30 80 38 72 41 ae 1a  8f 54 26 c2 9e f6 c1 25  a9 65
             ^
    #0 0x7fc3e137429a in _load4 ../3rdParty/jxrlib/image/decode/segdec.c:66
    4creators#1 0x7fc3e13748b8 in _flushBit16 ../3rdParty/jxrlib/image/decode/segdec.c:80
    4creators#2 0x7fc3e13749a6 in _getBit16 ../3rdParty/jxrlib/image/decode/segdec.c:86
    4creators#3 0x7fc3e1385d75 in DecodeMacroblockDC ../3rdParty/jxrlib/image/decode/segdec.c:1224
    4creators#4 0x7fc3e131924a in processMacroblockDec ../3rdParty/jxrlib/image/decode/strdec.c:412
    4creators#5 0x7fc3e137207a in ImageStrDecDecode ../3rdParty/jxrlib/image/decode/strdec.c:4003
    4creators#6 0x7fc3e126c0b2 in PKImageDecode_Copy_WMP ../3rdParty/jxrlib/jxrgluelib/JXRGlueJxr.c:1874
```
milianw added a commit to KDABLabs/jxrlib that referenced this issue Jun 7, 2021
Instead, make the value positive, do the left-shift then, and make the
result negative again afterwards:

```
    ../3rdParty/jxrlib/image/decode/segdec.c:1081:36: runtime error: left shift of negative value -1
    #0 0x7f0cc5c997c8 in DecodeMacroblockLowpass ../3rdParty/jxrlib/image/decode/segdec.c:1081
    4creators#1 0x7f0cc5c2f4f4 in processMacroblockDec ../3rdParty/jxrlib/image/decode/strdec.c:417
    4creators#2 0x7f0cc5c881f8 in ImageStrDecDecode ../3rdParty/jxrlib/image/decode/strdec.c:4010
    4creators#3 0x7f0cc5b82102 in PKImageDecode_Copy_WMP ../3rdParty/jxrlib/jxrgluelib/JXRGlueJxr.c:1874
```

Considering that the tests still pass, I think this is a safe solution
to this warning.
bgilbert referenced this issue in bgilbert/jxrlib Dec 8, 2022
Instead, shift as an unsigned value, then convert back to signed:

```
    ../3rdParty/jxrlib/image/decode/segdec.c:1081:36: runtime error: left shift of negative value -1
    #0 0x7f0cc5c997c8 in DecodeMacroblockLowpass ../3rdParty/jxrlib/image/decode/segdec.c:1081
    #1 0x7f0cc5c2f4f4 in processMacroblockDec ../3rdParty/jxrlib/image/decode/strdec.c:417
    #2 0x7f0cc5c881f8 in ImageStrDecDecode ../3rdParty/jxrlib/image/decode/strdec.c:4010
    #3 0x7f0cc5b82102 in PKImageDecode_Copy_WMP ../3rdParty/jxrlib/jxrgluelib/JXRGlueJxr.c:1874
```

Co-authored-by: Milian Wolff <[email protected]>
@Knewest
Copy link

Knewest commented Sep 29, 2023

I know I am late, but you can find the pre-compiled binaries here: https://github.com/Knewest/precompiled-jxrlib-binaries/releases

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

3 participants