Skip to content

Instantly share code, notes, and snippets.

@The-Running-Dev
Created November 22, 2024 14:56
Show Gist options
  • Save The-Running-Dev/58b8593ffaa5779b8c6c1d323c845a69 to your computer and use it in GitHub Desktop.
Save The-Running-Dev/58b8593ffaa5779b8c6c1d323c845a69 to your computer and use it in GitHub Desktop.
How to Remove a Dependency in QNAP Package
# Resources
# Sample package: https://www.myqnap.org/product/radarr-qbase24/
# Create a simple package: https://cheng-yuan-hong.gitbook.io/qdk-qpkg-development-kit/creating-a-qpkg-package-using-qdk/creating-a-simple-qpkg-package
# QNAP SDK docs: https://edhongcy.gitbooks.io/qdk-qpkg-development-kit/content/
# You will need the QNAP SDK, https://github.com/qnap-dev/QDK
# Download the package and put it on your NAS
# SSH into the nas and go to the directory where the package is located
# Create the QNAP build evnironment
```
qbuild --create-env Radarr
```
# Extract the package
```
qbuild --extract ./RadarrDotNetQ_5.10.3.917_x86_64.qpkg ./Radarr
```
# Go to the package directory
```
cd Radarr
```
# Edit the qpkg.cfg file (nano, vi, vim, etc)
```
nano qpkg.cfg
```
# Find ```QPKG_REQUIRE```
```
# Specifies any packages required for the current package to operate.
QPKG_REQUIRE="QBase24"
```
# Remove the requirement and save the file
```
QPKG_REQUIRE=""
```
# Build the QPKG
```
qbuild --build-dir ./build
```
# Your package is inside the ./build directory
@m1r0m4n
Copy link

m1r0m4n commented Feb 13, 2025

Hi, I tried your how to, but qbuild --build-dir ./build built much smaller file than original .qpkg and it was missing all data. Are you sure that this is working OK ?
(I was testing it on different app - https://www.myqnap.org/product/pyload-apache83/)

@F1Gogetta
Copy link

Hi, I tried your how to, but qbuild --build-dir ./build built much smaller file than original .qpkg and it was missing all data. Are you sure that this is working OK ? (I was testing it on different app - https://www.myqnap.org/product/pyload-apache83/)

Copy the "data.tar.7z" to the "x86_64" (or whichever architecture you use). It should then produce a full .qpkg file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment