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

Builds on modern Ubuntu #56

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

RobertLarsen
Copy link

This makes sasquatch build on Ubuntu 22.04

@ladbsoft
Copy link

Tested and working in Ubuntu 22.10 with gcc 11.4.0.

Hopefully the owner notices and this gets merged. Thanks, mate!

@0xdead8ead
Copy link

Came here because of this error during compilation on Ubuntu 22.04:

cc -g -O2  -I. -I./LZMA/lzma465/C -I./LZMA/lzmalt -I./LZMA/lzmadaptive/C/7zip/Compress/LZMA_Lib -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_GNU_SOURCE -DCOMP_DEFAULT=\"gzip\" -Wall -Werror  -DGZIP_SUPPORT -DLZMA_SUPPORT -DXZ_SUPPORT -DLZO_SUPPORT -DXATTR_SUPPORT -DXATTR_DEFAULT   -c -o unsquashfs.o unsquashfs.c
unsquashfs.c: In function 'read_super':
unsquashfs.c:1835:5: error: this 'if' clause does not guard... [-Werror=misleading-indentation]
 1835 |     if(swap)
           |     ^~
unsquashfs.c:1841:9: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if'
      |         read_fs_bytes(fd, SQUASHFS_START, sizeof(struct squashfs_super_block),
      |         ^~~~~~~~~~~~~
cc1: all warnings being treated as errors
make: *** [<builtin>: unsquashfs.o] Error 1

The above PR works for ubuntu:22.04. Thanks @RobertLarsen !!

For those waiting for this to be merged, for now you can do:

git clone https://github.com/devttys0/sasquatch
(cd sasquatch && git pull origin pull/56/head && ./build.sh)

@leoss
Copy link

leoss commented Dec 30, 2023

This also works on Ubuntu 23.04.

aliask added a commit to aliask/sasquatch that referenced this pull request Oct 16, 2024
Create a Dockerfile to enable a portable build environment. The Dockerfile is based on Ubuntu 24.04, and uses multiple stages to produce a minimal final product, with the final image size sitting at about 75mb.
This branch also incorporates the updates prepared by @cole-h to update to squashfs-tools 4.4 in devttys0#56.
Finally, building on newer GCC highlights a dangling pointer error in LzmaEnc.c. I have separated the fix for this problem into a dedicated patch file for ease of review.
@matteius
Copy link

To build on Ubuntu 24.10:

Clone @RobertLarsen 's branch
Run ./build.sh to apply patches
cd squashfs4.3/squashfs-tools/
vim Makefile
Add -Wno-error to the CLFAGS line (pick one)
run make in that directory
sudo cp sasquatch /usr/local/bin

should be available after that

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

Successfully merging this pull request may close these issues.

5 participants