summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorMoses Narrow2019-06-02 21:03:04 -0500
committerMoses Narrow2019-06-02 21:03:04 -0500
commitbe10900a91824a15696b892602ebe9fdca0e50bd (patch)
tree0b318c97cf56ca9a82cc1c67f21cc6dba716092c /PKGBUILD
parent53a6fb7bb4bb2f99783b575d7e2047b072e3eb4b (diff)
downloadaur-be10900a91824a15696b892602ebe9fdca0e50bd.tar.gz
fix newcoin & cxchains script
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD22
1 files changed, 13 insertions, 9 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 836117f7937..f55f617e015 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -6,7 +6,7 @@ projectname=skycoin
pkgdesc="CX Skycoin Blockchain Programming Language"
pkgver='autogenerated'
pkggopath="github.com/$projectname/$pkgname1"
-pkgrel=2
+pkgrel=3
arch=('any')
url="https://${pkggopath}"
license=()
@@ -73,10 +73,10 @@ build() {
# msg2 'creating cx chains setup script'
-# mkdir -p $srcdir/$pkgname1-scripts
-# cd $srcdir/$pkgname1-scripts
-# echo -e '#!/bin/bash \n #setup symlink for fiber.toml along GOPATH \n export GOBIN=/usr/lib/skycoin/go/bin \n echo "export GOBIN=/usr/lib/skycoin/go/bin" \n export GOPATH=GOBIN=/usr/lib/skycoin/go \n echo "export GOPATH=GOBIN=/usr/lib/skycoin/go" \n sudo ln -s /usr/lib/skycoin/cx/fiber.toml /usr/lib/skycoin/go/src/github.com/skycoin/cx/fiber.toml \n echo "Running: skycoin-cli addressGen" \n skycoin-cli addressGen \n echo "edit /usr/lib/skycoin/cx/fiber.toml" \n echo "export SECRET_KEY=" \n echo "export PUBLIC_KEY=" \n echo "cx --blockchain --heap-initial 100 --stack-size 100 --secret-key $SECRET_KEY --public-key $PUBLIC_KEY counter-bc.cx" \n echo "cx --blockchain --heap-initial 100 --stack-size 100 --secret-key $SECRET_KEY --public-key $PUBLIC_KEY counter-bc.cx"' > $pkgname1-chaintest
-# chmod +x $pkgname1-chaintest
+mkdir -p $srcdir/$pkgname1-scripts
+cd $srcdir/$pkgname1-scripts
+echo -e '#!/bin/bash \n #setup symlink for fiber.toml along GOPATH \n export GOBIN=/usr/lib/skycoin/go/bin \n echo "export GOBIN=/usr/lib/skycoin/go/bin" \n export GOPATH=/usr/lib/skycoin/go \n echo "export GOPATH=/usr/lib/skycoin/go" \n echo "cx --generate-address > address.txt" \n "cat address.txt" \n echo "edit /usr/lib/skycoin/cx/fiber.toml" \n echo "export SECRET_KEY=" \n echo "export PUBLIC_KEY=" \n echo "cx --blockchain --heap-initial 100 --stack-size 100 --secret-key $SECRET_KEY --public-key $PUBLIC_KEY /usr/lib/skycoin/go/src/github.com/skycoin/cx/examples/blockchain/counter-bc.cx" \n echo "export GENESIS_ADDRESS=" \n echo "export GENESIS_SIGNATURE=" \n echo "cx --publisher --genesis-address $GENESIS_ADDRESS --genesis-signature $GENESIS_SIGNATURE --secret-key $SECRET_KEY --public-key $PUBLIC_KEY" \n echo "cx --peer --genesis-address $GENESIS_ADDRESS --port 6001 --genesis-signature $GENESIS_SIGNATURE --public-key $PUBLIC_KEY" \n echo "cx --create-wallet --wallet-seed "museum nothing practice weird wheel dignity economy attend mask recipe minor dress""' > $pkgname1-chaintest
+chmod +x $pkgname1-chaintest
}
package() {
@@ -94,13 +94,17 @@ msg2 'installing binaries'
#cxbins="$srcdir"/go/bin
#cxbin=$( ls $cxbins )
#for i in $cxbin; do
+#^MAKE DEPENDANCIES ARE IN GOBIN; GET ONLY CX & NEWCOIN
+install -Dm755 $srcdir/go/bin/newcoin $pkgdir/usr/lib/$projectname/go/bin/newcoin
+ln -rTsf $pkgdir/usr/lib/$projectname/go/bin/newcoin $pkgdir/usr/bin/newcoin
+chmod 755 $pkgdir/usr/bin/newcoin
install -Dm755 $srcdir/go/bin/$pkgname1 $pkgdir/usr/lib/$projectname/go/bin/$pkgname1
ln -rTsf $pkgdir/usr/lib/$projectname/go/bin/$pkgname1 $pkgdir/usr/bin/$pkgname1
chmod 755 $pkgdir/usr/bin/$pkgname1
#done
#install the scripts
-#cxscripts=$( ls $srcdir/$pkgname1-scripts )
-#for i in $cxscripts; do
-#cp $srcdir/$pkgname1-scripts/$i $pkgdir/usr/bin/$i
-#done
+cxscripts=$( ls $srcdir/$pkgname1-scripts )
+for i in $cxscripts; do
+cp $srcdir/$pkgname1-scripts/$i $pkgdir/usr/bin/$i
+done
}