Optware / Optware-ng

279 stars 52 forks source link

How make ipkg as command #1

Closed Sporrdig closed 9 years ago

Sporrdig commented 9 years ago

How i do ipkg as command for the System.

to now i use allways: /opt/bin/ipkg

But i Need as ipkg command for task Scheduler,

Thanks for your answer

alllexx88 commented 9 years ago

@Sporrdig - I take it, you want to be able to run ipkg without specifying the full path? If so, you need to add /opt/bin to PATH. Try these commands:

echo 'export PATH=$PATH:/opt/bin:/opt/sbin' >> /root/.profile
echo 'export PATH=$PATH:/opt/bin:/opt/sbin' >> /etc/profile

and re-login.

On second thought, I'm not familiar with QNAP task Scheduler and don't know which environment it uses, so not sure it'll work. Maybe a reboot is needed. Also, any reason you can't use /opt/bin/ipkg in Scheduler?

Sporrdig commented 9 years ago

Please help me more:

[~] # echo 'export PATH=$PATH:/share/CACHEDEV1_DATA/.qpkg/Optware-ng:/opt/sbin' >> /etc/profile [~] # echo 'export PATH=$PATH:/share/CACHEDEV1_DATA/.qpkg/Optware-ng:/opt/sbin' >> /root/.profile [~] # ipkg -sh: ipkg: command not found

in the share/CACHEDEV1_DATA/.qpkg/Optware-ng is the ipkg file.

Sporrdig commented 9 years ago

Is done:

http://eu1.qnap.com/Storage/QPKG/Optware_0.99.163.zip

It works.

Sporrdig commented 9 years ago

When enyone want the file by when this link will down:

https://www.dropbox.com/s/25g747vxmzosjqu/Optware_0.99.163.qpkg?dl=0

YEAR!!

Sporrdig commented 9 years ago

after installed:

ipkg update ipkg list | grep coreutils ipkg install coreutils

alllexx88 commented 9 years ago

@Sporrdig - Optware_0.99.163.zip installs original deprecated Optware. Here is a nice article about it.

You followed my instructions in an odd way. It must have been

/opt/bin

Not

/share/CACHEDEV1_DATA/.qpkg/Optware-ng

Since Optware-ng must be installed to /opt, otherwise it will not work. It may be installed elsewhere, but has to be symlinked (or hardlinked) to /opt, otherwise executables won't find needed libraries. Also, you didn't re-login, hence PATH was not populated automatically, so no surprise it didn't work.

What you should do now, if you do want to use Optware-ng instead of deprecated original Optware, is this:

rm -rf /opt/*
wget -O - http://optware-ng.zyxmon.org/buildroot-i686/buildroot-i686-bootstrap.sh | sh

This should work, since that .qpkg you installed automatically took care of editing profile files(s) to fix PATH, I believe. Though you still may want to install a nice text editor (like nano) and edit /etc/profile and /root/.profile to remove the lines you added with echo to make it cleaner.

Sporrdig commented 9 years ago

Yes that Instruction can use by a Linux Distribute. But by QNAP will always after restart the folder /opt/bin empty.

And the Problem is Optware is not more Support from QNAP. It can`t more find in der QPKG APP Store. So its luck that was this download online, because it will all Optware_xxx.qpkg offline from QNAP.

It work well with Optware_0.99.163.qpkg. For me its dosent metter, what Optware from who. Optware or Qnapware if i can install for example gcc then is well.

alllexx88 commented 9 years ago

Actually, it does matter, e.g., let's take gcc. I'm not sure which deprecated Optware feed that .qpkg uses, but probably it's something like syno-i686. This means that it has gcc-4.2.1, which is really old and can't be used to compile some newer software, like recent mkvtoolnix or mpd. The same goes for other pre-compiled packages: they're outdated and often have security bugs that have long been fixed in newer versions. And no hope to update them since Optware is stalled.

Yes that Instruction can use by a Linux Distribute. But by QNAP will always after restart the folder /opt/bin empty.

After you installed that .qpkg it will not be emptied. According to this article, Optware is installed to /share/MD0_DATA/optware/opt and symlinked to /opt. So now you can run these commands and install Optware-ng inslead of Optware:

rm -rf /opt/*
wget -O - http://optware-ng.zyxmon.org/buildroot-i686/buildroot-i686-bootstrap.sh | sh

But if you're happy with deprecated Optware, don't. Just don't expect any kind of support or fixes from virtually anyone, since last Optware commit is dated to 2014-10-03, and even then it was deprecated already.

ryzhovau commented 9 years ago

Check out new Optware-NG installation How-To, made by @TeHashX.

alllexx88 commented 9 years ago

@TeHashX great job writing the article and modifying the script! I'll reference the article in the Readme when I get home if you don't mind :-)

LeeWiu commented 9 years ago

Sure, thanks