Change Details
cgminer/Makefile |
12 | 12 | PKG_VERSION:=20120516 |
13 | 13 | PKG_REV:=b69d735cfe468c489a24677ffef1d6d998818cac |
14 | 14 | # this is upstream version 2.4.1 |
15 | | PKG_RELEASE:=1 |
| 15 | PKG_RELEASE:=2 |
16 | 16 | PKG_INSTALL:=1 |
17 | 17 | |
18 | 18 | PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_REV).tar.gz |
... | ... | |
39 | 39 | monitoring, (over)clocking and fanspeed support for bitcoin and derivative |
40 | 40 | coins. Do not use on multiple block chains at the same time! |
41 | 41 | endef |
42 | | # This package only enable the Icarus support. just connect your Icarus |
43 | | # FPGA miner board to OpenWrt router(with USB HOST support) |
44 | | # Run like: |
45 | | # cgminer -S /dev/ttyUSB0 -o http://MINING.POOL.URL -O USER:PASS |
46 | 42 | |
47 | | CONFIGURE_ARGS += --disable-opencl --disable-adl --enable-icarus |
| 43 | CONFIGURE_ARGS += --disable-opencl --disable-adl --enable-icarus --enable-bitforce |
48 | 44 | TARGET_LDFLAGS += -Wl,-rpath-link=$(STAGING_DIR)/usr/lib |
49 | 45 | |
50 | 46 | define Build/Compile |
... | ... | |
59 | 55 | $(INSTALL_BIN) $(PKG_BUILD_DIR)/cgminer-api $(1)/usr/bin |
60 | 56 | |
61 | 57 | $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/cgminer $(1)/usr/bin |
62 | | $(INSTALL_BIN) $(FILES_DIR)/cgminer $(1)/etc/init.d |
| 58 | $(INSTALL_BIN) $(FILES_DIR)/cgminer.init $(1)/etc/init.d/cgminer |
63 | 59 | |
64 | | $(CP) $(FILES_DIR)/20-icarus.hotplug $(1)/etc/hotplug.d/usb/20-icarus |
| 60 | $(CP) $(FILES_DIR)/20-cgminer-fpga.hotplug $(1)/etc/hotplug.d/usb/ |
65 | 61 | endef |
66 | 62 | |
67 | 63 | $(eval $(call BuildPackage,cgminer)) |
cgminer/files/20-cgminer-fpga.hotplug |
| 1 | #!/bin/sh |
| 2 | |
| 3 | # Copyright (C) 2009 OpenWrt.org |
| 4 | |
| 5 | if [ "${PRODUCT}" = "67b/2303/400" ] && [ "$TYPE" = "0/0/0" ] && [ "$INTERFACE" = "255/0/0" ]; then |
| 6 | case "$ACTION" in |
| 7 | add) |
| 8 | killall -s 9 sleep |
| 9 | killall -s 9 cgminer |
| 10 | sleep 1 && /etc/init.d/cgminer start & |
| 11 | ;; |
| 12 | remove) |
| 13 | ;; |
| 14 | esac |
| 15 | fi |
cgminer/files/20-icarus.hotplug |
1 | | #!/bin/sh |
2 | | |
3 | | # Copyright (C) 2009 OpenWrt.org |
4 | | |
5 | | if [ "${PRODUCT}" = "67b/2303/400" ] && [ "$TYPE" = "0/0/0" ] && [ "$INTERFACE" = "255/0/0" ]; then |
6 | | case "$ACTION" in |
7 | | add) |
8 | | killall -s 9 sleep |
9 | | killall -s 9 cgminer |
10 | | sleep 1 && /etc/init.d/cgminer start & |
11 | | ;; |
12 | | remove) |
13 | | ;; |
14 | | esac |
15 | | fi |
cgminer/files/cgminer |
1 | | #!/bin/sh /etc/rc.common |
2 | | START=99 |
3 | | |
4 | | POOL1="-o http://us.ozco.in:8331 -O xiangfu.0:x" |
5 | | POOL2="-o http://pool.ABCPool.co:8332 -O xiangfu.0:x" |
6 | | POOL3="-o http://pit.deepbit.net:8332 -O xiangfu.z@gmail.com_0:x" |
7 | | |
8 | | POOLS="$POOL1 $POOL2 $POOL3" |
9 | | |
10 | | start() { |
11 | | DEVS=`find /dev/ -type c -name "ttyUSB*" | sed 's/^/-S/' | sed ':a;N;$!ba;s/\n/ /g'` |
12 | | cgminer -q -T --api-network --api-listen $POOLS $DEVS & |
13 | | } |
14 | | |
15 | | stop() { |
16 | | killall -s 9 cgminer |
17 | | } |
cgminer/files/cgminer.init |
| 1 | #!/bin/sh /etc/rc.common |
| 2 | START=99 |
| 3 | |
| 4 | POOL1="-o http://us.ozco.in:8331 -O xiangfu.0:x" |
| 5 | POOL2="-o http://pool.ABCPool.co:8332 -O xiangfu.0:x" |
| 6 | POOL3="-o http://pit.deepbit.net:8332 -O xiangfu.z@gmail.com_0:x" |
| 7 | |
| 8 | POOLS="$POOL1 $POOL2 $POOL3" |
| 9 | |
| 10 | start() { |
| 11 | DEVS=`find /dev/ -type c -name "ttyUSB*" | sed 's/^/-S/' | sed ':a;N;$!ba;s/\n/ /g'` |
| 12 | sleep 10 && cgminer -q -T --api-network --api-listen $POOLS $DEVS & |
| 13 | } |
| 14 | |
| 15 | stop() { |
| 16 | killall -s 9 cgminer |
| 17 | } |
Download the corresponding diff file