This is my first time attempting to build a custom package on my gl-inet MT300N-V2, and the software in question is not part of openwrt / packages.
I just want to build an
.ipk for it.
From what I understood, I need gl-inet / sdk
$ git clone https://github.com/gl-inet/sdk glinet-sdk
$ cd glinet-sdk
$ ./download.sh ramips-1806
After that I try to understand what is meant in the gl-inet sdk README with
Place your package in sdk/<version>/<target>/package/
The software I want to build has a github project and a configure script, so I git clone it into
$ git clone -b r606 --depth 1 https://github.com/vthoang/cgminer.git sdk/1806/ramips/package/cgminer
Then I run the make command, which fails.
make: *** No rule to make target 'package/cgminer/compile
Can anyone with more experience tell me how to make it work?
Or point me to useful resources? I’m lost, and have never done cross-compilation before. I was hoping the gl-inet/sdk would ease the process, but there’s evidently something missing in my understanding of how to use it.
First of all, why would you want to use CGMiner on your router? It will basically be a 100% waste of electricity and also a waste of your time.
Also unfortunately if what you want to build doesn’t have an “OpenWRT Package”, then it’s not as simple as in the SDK guide.
As an example, take a look at the OpenWRT Package structure here:
OpenWRT Packages have a special kind of Makefile, that will either download a remote package and build from the downloaded sources, or build locally. It will create the IPK package you can install on the router, and contains install locations, files and so on.
I found a package source for CGMiner here:
It will need to be modified since the person is using it for Avalon, i guess some specific miner hardware.
Thank you for the pointers to external resources.
I’m well aware that this is a lost cause, but the whole point of the exercise was for me to run a low-power device around the clock with internet connectivity and a USB port for my NEWPAC miner. This is just a miner for luck, with intergalactically small odds of mining any block ever.
I knew all that when I was getting into this.
But I was getting nowhere with OpenWRT and so I wrote this question in the forum before giving up and throwing everything away. You took the time to respond and I’m thankful for that.
So I shall try. And it will be wasted time. And that is OK.
I managed to get a bit further, but I’m not quite sure how to fix this missing dependency
root@MT300N-V2:~# opkg install cgminer_git-9e51f0b-1_mipsel_24kc.ipk
Installing cgminer (git-9e51f0b-1) to root...
* satisfy_dependencies_for: Cannot satisfy the following dependencies for cgminer:
* udev *
* opkg_install_cmd: Cannot install package cgminer.
I tried (when building the ipk)
$ scripts/feeds install libudev-fbsd
And I tried changing
+libudev-fbsd in the cgminer openwrt Makefile’s
to no avail.
I don’t quite understand how the dependency on
udev is detected, and whether it is a dependency on a library or a daemon, and whether there is an openwrt package for either. My guess of libudev-fbsd was just a crap shoot based on the package description.
Thanks for any help
Just a quick look at other packages containing the string udev:
You can see a lot have the flag disabling udev. Maybe you need that also?