python – Snake implementation? – Game Development Stack Exchange

I’m new at this, so I thought I’d start simple. Snake. I started with pygame, just looking some things up, and I’ve now got movement, random fruit generation, and a score counter.

pygame.init()

size = width, height = (800, 440)
screen = pygame.display.set_mode(size)
pygame.display.set_caption('snake from scratch')

clock = pygame.time.Clock()

notBlack = (40,50,50)
white = (255,255,255)
red = (255,0,0)
blue = (0,0,255)
green = (0,255,0)

w = 20, 760

x1 = 400
y1 = 220
x1Velocity = 0
y1Velocity = 0
x2 = 0
y2 = 0

player = pygame.Rect(x1, y1, 20, 20)
fruit = pygame.Rect(x2, y2, 20, 20)
fruitOnScreen = False
score = 0

def roundTo(x, base):
    return base * round(x/base) #rounds to whatever you put as base

def offScreen(x, y):
    while x >= 760 or y >= 400:
        if x > 760:
            x -= 5
        if y > 400:
            y -= 5
        if x < 770 and y < 405:
            break
    return x, y #forces x and y pos back on screen

running = True
while running:
    for event in pygame.event.get():
        if event.type == pygame.QUIT:
            running = False
        if event.type == pygame.KEYDOWN:
            if event.key == pygame.K_ESCAPE:
                running = False
            if event.key == pygame.K_LEFT:
                x1Velocity = -20
                y1Velocity = 0
            if event.key == pygame.K_RIGHT:
                x1Velocity = 20
                y1Velocity = 0
            if event.key == pygame.K_UP:
                x1Velocity = 0
                y1Velocity = -20
            if event.key == pygame.K_DOWN:
                x1Velocity = 0
                y1Velocity = 20

    x1 += x1Velocity
    y1 += y1Velocity
    
    player = pygame.Rect(x1, y1, 20, 20)
    fruit = pygame.Rect(x2, y2, 20, 20)
    collide = player.colliderect(fruit)

    if not fruitOnScreen:
        x2 = random.randrange(20, 760)
        y2 = random.randrange(20, 400)
        x2 = roundTo(x2, 20)
        y2 = roundTo(y2, 20)
        x2, y2 = offScreen(x2, y2)
        fruitOnScreen = True #Generates random coords for fruit
    elif collide:
        score += 1
        fruitOnScreen = False
        print(score)

    screen.fill(white)
    
    pygame.draw.rect(screen, red, (x2, y2, 20, 20))
    pygame.draw.rect(screen, blue, (x1, y1, 20, 20))
    pygame.draw.rect(screen, notBlack, (0, 0, 800, 440), 40) #Draws a 20pixel thick border
    pygame.display.update()
    clock.tick(8)

pygame.quit()
quit()

I think this is pretty good for not having much of any experience, but now I’m stuck. I want to have the body get longer, but I don’t know where to even start. Just looking at it, is it even possible to implement it using what I’ve already got?

plugin development – How to create dynamic content with get_post_meta?

If i create php dynamic website i use the code something like this

<input type="text" name="fname">
$name = $_POST('fname');
echo $name;

In WordPress i have created a plugin. Inside is a metabox with one input text field “name”.

I try to create dynamic content with variables so i can “echo” them anywhere in front pages. More specific in each “directory” post pages it must display dynamically at the page 1 the name “John” and the second page the name “Jane”.

Here is my code:

$args = array(
                'post_type' => array( 'directory' ),
                'order'     => 'ASC',
            );

            // The Query
            $query = new WP_Query( $args );

            // The Loop
          if ( $query->have_posts() ) {
                while ( $query->have_posts() ) {
                    $query->the_post();
                }
            } else {
                 no posts found
            }

    $name = get_post_meta( get_the_ID(), 'name', true );
        
    if( !empty( $name )  ) {
        echo $name;
    }
    else {
        echo "Empty meta";
    }

Can anyone show me an example on wordpress code about how to create dynamic content with get_post_meta or show me what i am doing wrong ?

bitcoin core development – so many “undefined reference to” after I add some codes, how to solve it?

I am just want to modify the hash algorithm of bitcoin-0.20 and I want to replace the previous hash algorithm to the x13hash algorithm. So I modify the source below,

1, I add the x13hash files to the bitcoin-0.20/src/crypto/x13hash, there are files below:

aes_helper.c  bmw.c       echo.c   groestl.c  hamsi_helper.c  keccak.c  shavite.c  skein.c  sph_blake.h  sph_cubehash.h  sph_fugue.h    sph_hamsi.h  sph_keccak.h  sph_shavite.h  sph_skein.h  sph_types.h
blake.c       cubehash.c  fugue.c  hamsi.c    jh.c            luffa.c   simd.c     sm3.c    sph_bmw.h    sph_echo.h      sph_groestl.h  sph_jh.h     sph_luffa.h   sph_simd.h     sph_sm3.h

2, I add a new function in block.h below

class CBlockHeader
{
public:
    // header
    int32_t nVersion;
    uint256 hashPrevBlock;
    uint256 hashMerkleRoot;
    uint32_t nTime;
    uint32_t nBits;
    uint32_t nNonce;

    CBlockHeader()
    {
        SetNull();
    }

    ADD_SERIALIZE_METHODS;

    template <typename Stream, typename Operation>
    inline void SerializationOp(Stream& s, Operation ser_action) {
        READWRITE(this->nVersion);
        READWRITE(hashPrevBlock);
        READWRITE(hashMerkleRoot);
        READWRITE(nTime);
        READWRITE(nBits);
        READWRITE(nNonce);
    }

    void SetNull()
    {
        nVersion = 0;
        hashPrevBlock.SetNull();
        hashMerkleRoot.SetNull();
        nTime = 0;
        nBits = 0;
        nNonce = 0;
    }

    bool IsNull() const
    {
        return (nBits == 0);
    }

    uint256 GetHash() const;
    uint256 GetNewPoWHash() const; //new hash function

    int64_t GetBlockTime() const
    {
        return (int64_t)nTime;
    }
};

3, add the function in block.cpp

#include <hash.h>
#include <tinyformat.h>

#define BEGIN(a)            ((char*)&(a))
#define END(a)              ((char*)&((&(a))(1)))
#define UBEGIN(a)           ((unsigned char*)&(a))
#define UEND(a)             ((unsigned char*)&((&(a))(1)))
#define ARRAYLEN(array)     (sizeof(array)/sizeof((array)(0)))

uint256 CBlockHeader::GetHash() const
{
    return SerializeHash(*this);
}
uint256 CBlockHeader::GetNewPoWHash() const //new !! 
{   
    return HashX13sm3(BEGIN(nVersion), END(nNonce));
}
  1. modify the hash.h below:

     #include <vector>
     // added new
     #include "crypto/x13hash/sph_blake.h"
     #include "crypto/x13hash/sph_bmw.h"
     #include "crypto/x13hash/sph_groestl.h"
     #include "crypto/x13hash/sph_jh.h"
     #include "crypto/x13hash/sph_keccak.h"
     #include "crypto/x13hash/sph_skein.h"
     #include "crypto/x13hash/sph_luffa.h"
     #include "crypto/x13hash/sph_cubehash.h"
     #include "crypto/x13hash/sph_shavite.h"
     #include "crypto/x13hash/sph_simd.h"
     #include "crypto/x13hash/sph_echo.h"
     #include "crypto/x13hash/sph_hamsi.h"
     #include "crypto/x13hash/sph_fugue.h"
     #include "crypto/x13hash/sph_sm3.h"
    
     #ifdef GLOBALDEFINED
     #define GLOBAL
     #else
     #define GLOBAL extern
     #endif
    
     GLOBAL sph_blake512_context     z_blake;
     GLOBAL sph_bmw512_context       z_bmw;
     GLOBAL sph_groestl512_context   z_groestl;
     GLOBAL sph_jh512_context        z_jh;
     GLOBAL sph_keccak512_context    z_keccak;
     GLOBAL sph_skein512_context     z_skein;
     GLOBAL sph_luffa512_context     z_luffa;
     GLOBAL sph_cubehash512_context  z_cubehash;
     GLOBAL sph_shavite512_context   z_shavite;
     GLOBAL sph_simd512_context      z_simd;
     GLOBAL sph_echo512_context      z_echo;
     GLOBAL sph_hamsi512_context     z_hamsi;
     GLOBAL sph_fugue512_context     z_fugue;
     #define fillz() do { 
         sph_blake512_init(&z_blake); 
         sph_bmw512_init(&z_bmw); 
         sph_groestl512_init(&z_groestl); 
         sph_jh512_init(&z_jh); 
         sph_keccak512_init(&z_keccak); 
         sph_skein512_init(&z_skein); 
         sph_luffa512_init(&z_luffa); 
         sph_cubehash512_init(&z_cubehash); 
         sph_shavite512_init(&z_shavite); 
         sph_simd512_init(&z_simd); 
         sph_echo512_init(&z_echo); 
         sph_hamsi512_init(&z_hamsi); 
         sph_fugue512_init(&z_fugue); 
     } while (0) 
     typedef uint256 ChainCode;
     template<typename T1>
    

    inline uint256 HashX13(const T1 pbegin, const T1 pend)

    {
    sph_blake512_context ctx_blake;
    sph_bmw512_context ctx_bmw;
    sph_groestl512_context ctx_groestl;
    sph_jh512_context ctx_jh;
    sph_keccak512_context ctx_keccak;
    sph_skein512_context ctx_skein;
    sph_luffa512_context ctx_luffa;
    sph_cubehash512_context ctx_cubehash;
    sph_shavite512_context ctx_shavite;
    sph_simd512_context ctx_simd;
    sph_echo512_context ctx_echo;
    sph_hamsi512_context ctx_hamsi;
    sph_fugue512_context ctx_fugue;
    static unsigned char pblank(1);

    #ifndef QT_NO_DEBUG
    //std::string strhash;
    //strhash = “”;
    #endif

     uint256 hash(34);
    
     sph_blake512_init(&ctx_blake);
     sph_blake512 (&ctx_blake, (pbegin == pend ? pblank : static_cast<const void*>(&pbegin(0))), (pend - pbegin) * sizeof(pbegin(0)));
     sph_blake512_close(&ctx_blake, static_cast<void*>(&hash(0)));
    
     sph_bmw512_init(&ctx_bmw);
     sph_bmw512 (&ctx_bmw, static_cast<const void*>(&hash(0)), 64);
     sph_bmw512_close(&ctx_bmw, static_cast<void*>(&hash(2)));
    
     sph_groestl512_init(&ctx_groestl);
     sph_groestl512 (&ctx_groestl, static_cast<const void*>(&hash(2)), 64);
     sph_groestl512_close(&ctx_groestl, static_cast<void*>(&hash(4)));
    
     sph_skein512_init(&ctx_skein);
     sph_skein512 (&ctx_skein, static_cast<const void*>(&hash(4)), 64);
     sph_skein512_close(&ctx_skein, static_cast<void*>(&hash(6)));
    
     sph_jh512_init(&ctx_jh);
     sph_jh512 (&ctx_jh, static_cast<const void*>(&hash(6)), 64);
     sph_jh512_close(&ctx_jh, static_cast<void*>(&hash(8)));
    
     sph_keccak512_init(&ctx_keccak);
     sph_keccak512 (&ctx_keccak, static_cast<const void*>(&hash(8)), 64);
     sph_keccak512_close(&ctx_keccak, static_cast<void*>(&hash(10)));
    
     sph_luffa512_init(&ctx_luffa);
     sph_luffa512 (&ctx_luffa, static_cast<void*>(&hash(10)), 64);
     sph_luffa512_close(&ctx_luffa, static_cast<void*>(&hash(12)));
    
     sph_cubehash512_init(&ctx_cubehash);
     sph_cubehash512 (&ctx_cubehash, static_cast<const void*>(&hash(12)), 64);
     sph_cubehash512_close(&ctx_cubehash, static_cast<void*>(&hash(14)));
    
     sph_shavite512_init(&ctx_shavite);
     sph_shavite512(&ctx_shavite, static_cast<const void*>(&hash(14)), 64);
     sph_shavite512_close(&ctx_shavite, static_cast<void*>(&hash(16)));
    
     sph_simd512_init(&ctx_simd);
     sph_simd512 (&ctx_simd, static_cast<const void*>(&hash(16)), 64);
     sph_simd512_close(&ctx_simd, static_cast<void*>(&hash(18)));
    
     sph_echo512_init(&ctx_echo);
     sph_echo512 (&ctx_echo, static_cast<const void*>(&hash(18)), 64);
     sph_echo512_close(&ctx_echo, static_cast<void*>(&hash(20)));
    
     sph_hamsi512_init(&ctx_hamsi);
     sph_hamsi512 (&ctx_hamsi, static_cast<const void*>(&hash(20)), 64);
     sph_hamsi512_close(&ctx_hamsi, static_cast<void*>(&hash(22)));
    
     sph_fugue512_init(&ctx_fugue);
     sph_fugue512 (&ctx_fugue, static_cast<const void*>(&hash(22)), 64);
     sph_fugue512_close(&ctx_fugue, static_cast<void*>(&hash(24)));
    
    
     return hash(24);
    

    }

template
inline uint256 HashX13sm3(const T1 pbegin, const T1 pend)
{
sph_blake512_context ctx_blake;
sph_bmw512_context ctx_bmw;
sph_groestl512_context ctx_groestl;
sph_jh512_context ctx_jh;
sph_keccak512_context ctx_keccak;
sph_skein512_context ctx_skein;
sm3_ctx_t ctx_sm3;
sph_cubehash512_context ctx_cubehash;
sph_shavite512_context ctx_shavite;
sph_simd512_context ctx_simd;
sph_echo512_context ctx_echo;
sph_hamsi512_context ctx_hamsi;
sph_fugue512_context ctx_fugue;
static unsigned char pblank(1);

#ifndef QT_NO_DEBUG
//std::string strhash;
//strhash = “”;
#endif

uint256 hash(34);

sph_blake512_init(&ctx_blake);
sph_blake512 (&ctx_blake, (pbegin == pend ? pblank : static_cast<const void*>(&pbegin(0))), (pend - pbegin) * sizeof(pbegin(0)));
sph_blake512_close(&ctx_blake, static_cast<void*>(&hash(0)));

sph_bmw512_init(&ctx_bmw);
sph_bmw512 (&ctx_bmw, static_cast<const void*>(&hash(0)), 64);
sph_bmw512_close(&ctx_bmw, static_cast<void*>(&hash(2)));

    sph_groestl512_init(&ctx_groestl);
    sph_groestl512 (&ctx_groestl, static_cast<const void*>(&hash(2)), 64);
    sph_groestl512_close(&ctx_groestl, static_cast<void*>(&hash(4)));

    sph_skein512_init(&ctx_skein);
    sph_skein512 (&ctx_skein, static_cast<const void*>(&hash(4)), 64);
    sph_skein512_close(&ctx_skein, static_cast<void*>(&hash(6)));

    sph_jh512_init(&ctx_jh);
    sph_jh512 (&ctx_jh, static_cast<const void*>(&hash(6)), 64);
    sph_jh512_close(&ctx_jh, static_cast<void*>(&hash(8)));

    sph_keccak512_init(&ctx_keccak);
    sph_keccak512 (&ctx_keccak, static_cast<const void*>(&hash(8)), 64);
    sph_keccak512_close(&ctx_keccak, static_cast<void*>(&hash(10)));

    hash(12).SetNull(); //sm3 is 256bit, just in case
    hash(13).SetNull();
    sm3_init(&ctx_sm3);
    sph_sm3(&ctx_sm3, static_cast<const void*>(&hash(10)), 64);
    sph_sm3_close(&ctx_sm3, static_cast<void*>(&hash(12)));

    sph_cubehash512_init(&ctx_cubehash);
    sph_cubehash512 (&ctx_cubehash, static_cast<const void*>(&hash(12)), 64);
    sph_cubehash512_close(&ctx_cubehash, static_cast<void*>(&hash(14)));

    sph_shavite512_init(&ctx_shavite);
    sph_shavite512(&ctx_shavite, static_cast<const void*>(&hash(14)), 64);
    sph_shavite512_close(&ctx_shavite, static_cast<void*>(&hash(16)));

    sph_simd512_init(&ctx_simd);
    sph_simd512 (&ctx_simd, static_cast<const void*>(&hash(16)), 64);
    sph_simd512_close(&ctx_simd, static_cast<void*>(&hash(18)));

    sph_echo512_init(&ctx_echo);
    sph_echo512 (&ctx_echo, static_cast<const void*>(&hash(18)), 64);
    sph_echo512_close(&ctx_echo, static_cast<void*>(&hash(20)));

    sph_hamsi512_init(&ctx_hamsi);
    sph_hamsi512 (&ctx_hamsi, static_cast<const void*>(&hash(20)), 64);
    sph_hamsi512_close(&ctx_hamsi, static_cast<void*>(&hash(22)));

    sph_fugue512_init(&ctx_fugue);
    sph_fugue512 (&ctx_fugue, static_cast<const void*>(&hash(22)), 64);
    sph_fugue512_close(&ctx_fugue, static_cast<void*>(&hash(24)));


    return hash(24);
} /* added new above */
typedef uint256 ChainCode;  

Finally then I make again ,it shows error below:

CXX      script/libbitcoin_common_a-descriptor.o
  CXX      script/libbitcoin_common_a-sign.o
  CXX      script/libbitcoin_common_a-signingprovider.o
  CXX      script/libbitcoin_common_a-standard.o
  AR       libbitcoin_util.a
  AR       libbitcoin_consensus.a
  AR       libbitcoin_wallet_tool.a
  AR       libtest_util.a
  CXXLD    libbitcoinconsensus.la
  AR       libbitcoin_server.a
  AR       libbitcoin_wallet.a
  AR       libbitcoin_common.a
  CXXLD    bitcoin-cli
  CXXLD    bitcoin-tx
  CXXLD    bitcoin-wallet
  CXXLD    bitcoind
  CXXLD    test/test_bitcoin
/usr/bin/ld: libbitcoin_consensus.a(libbitcoin_consensus_a-block.o): in function `uint256 HashX13sm3<char*>(char*, char*)':
/home/gilsun91/bitcoin-0.20/src/./hash.h:178: undefined reference to `sph_blake512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:179: undefined reference to `sph_blake512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:180: undefined reference to `sph_blake512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:182: undefined reference to `sph_bmw512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:183: undefined reference to `sph_bmw512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:184: undefined reference to `sph_bmw512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:186: undefined reference to `sph_groestl512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:187: undefined reference to `sph_groestl512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:188: undefined reference to `sph_groestl512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:190: undefined reference to `sph_skein512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:191: undefined reference to `sph_skein512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:192: undefined reference to `sph_skein512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:194: undefined reference to `sph_jh512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:195: undefined reference to `sph_jh512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:196: undefined reference to `sph_jh512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:198: undefined reference to `sph_keccak512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:199: undefined reference to `sph_keccak512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:200: undefined reference to `sph_keccak512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:204: undefined reference to `sm3_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:205: undefined reference to `sph_sm3'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:206: undefined reference to `sph_sm3_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:208: undefined reference to `sph_cubehash512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:209: undefined reference to `sph_cubehash512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:210: undefined reference to `sph_cubehash512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:212: undefined reference to `sph_shavite512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:213: undefined reference to `sph_shavite512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:214: undefined reference to `sph_shavite512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:216: undefined reference to `sph_simd512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:217: undefined reference to `sph_simd512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:218: undefined reference to `sph_simd512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:220: undefined reference to `sph_echo512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:221: undefined reference to `sph_echo512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:222: undefined reference to `sph_echo512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:224: undefined reference to `sph_hamsi512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:225: undefined reference to `sph_hamsi512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:226: undefined reference to `sph_hamsi512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:228: undefined reference to `sph_fugue512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:229: undefined reference to `sph_fugue512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:230: undefined reference to `sph_fugue512_close'
collect2: error: ld returned 1 exit status
make(2): *** (Makefile:7370: bitcoin-tx) Error 1
make(2): *** Waiting for unfinished jobs....
/usr/bin/ld: libbitcoin_consensus.a(libbitcoin_consensus_a-block.o): in function `uint256 HashX13sm3<char*>(char*, char*)':
/home/gilsun91/bitcoin-0.20/src/./hash.h:178: undefined reference to `sph_blake512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:179: undefined reference to `sph_blake512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:180: undefined reference to `sph_blake512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:182: undefined reference to `sph_bmw512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:183: undefined reference to `sph_bmw512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:184: undefined reference to `sph_bmw512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:186: undefined reference to `sph_groestl512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:187: undefined reference to `sph_groestl512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:188: undefined reference to `sph_groestl512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:190: undefined reference to `sph_skein512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:191: undefined reference to `sph_skein512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:192: undefined reference to `sph_skein512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:194: undefined reference to `sph_jh512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:195: undefined reference to `sph_jh512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:196: undefined reference to `sph_jh512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:198: undefined reference to `sph_keccak512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:199: undefined reference to `sph_keccak512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:200: undefined reference to `sph_keccak512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:204: undefined reference to `sm3_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:205: undefined reference to `sph_sm3'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:206: undefined reference to `sph_sm3_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:208: undefined reference to `sph_cubehash512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:209: undefined reference to `sph_cubehash512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:210: undefined reference to `sph_cubehash512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:212: undefined reference to `sph_shavite512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:213: undefined reference to `sph_shavite512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:214: undefined reference to `sph_shavite512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:216: undefined reference to `sph_simd512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:217: undefined reference to `sph_simd512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:218: undefined reference to `sph_simd512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:220: undefined reference to `sph_echo512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:221: undefined reference to `sph_echo512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:222: undefined reference to `sph_echo512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:224: undefined reference to `sph_hamsi512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:225: undefined reference to `sph_hamsi512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:226: undefined reference to `sph_hamsi512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:228: undefined reference to `sph_fugue512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:229: undefined reference to `sph_fugue512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:230: undefined reference to `sph_fugue512_close'
collect2: error: ld returned 1 exit status
make(2): *** (Makefile:7374: bitcoin-wallet) Error 1
/usr/bin/ld: libbitcoin_consensus.a(libbitcoin_consensus_a-block.o): in function `uint256 HashX13sm3<char*>(char*, char*)':
/home/gilsun91/bitcoin-0.20/src/./hash.h:178: undefined reference to `sph_blake512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:179: undefined reference to `sph_blake512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:180: undefined reference to `sph_blake512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:182: undefined reference to `sph_bmw512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:183: undefined reference to `sph_bmw512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:184: undefined reference to `sph_bmw512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:186: undefined reference to `sph_groestl512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:187: undefined reference to `sph_groestl512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:188: undefined reference to `sph_groestl512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:190: undefined reference to `sph_skein512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:191: undefined reference to `sph_skein512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:192: undefined reference to `sph_skein512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:194: undefined reference to `sph_jh512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:195: undefined reference to `sph_jh512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:196: undefined reference to `sph_jh512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:198: undefined reference to `sph_keccak512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:199: undefined reference to `sph_keccak512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:200: undefined reference to `sph_keccak512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:204: undefined reference to `sm3_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:205: undefined reference to `sph_sm3'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:206: undefined reference to `sph_sm3_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:208: undefined reference to `sph_cubehash512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:209: undefined reference to `sph_cubehash512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:210: undefined reference to `sph_cubehash512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:212: undefined reference to `sph_shavite512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:213: undefined reference to `sph_shavite512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:214: undefined reference to `sph_shavite512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:216: undefined reference to `sph_simd512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:217: undefined reference to `sph_simd512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:218: undefined reference to `sph_simd512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:220: undefined reference to `sph_echo512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:221: undefined reference to `sph_echo512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:222: undefined reference to `sph_echo512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:224: undefined reference to `sph_hamsi512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:225: undefined reference to `sph_hamsi512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:226: undefined reference to `sph_hamsi512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:228: undefined reference to `sph_fugue512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:229: undefined reference to `sph_fugue512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:230: undefined reference to `sph_fugue512_close'
collect2: error: ld returned 1 exit status
make(2): *** (Makefile:7378: bitcoind) Error 1
/usr/bin/ld: libbitcoin_consensus.a(libbitcoin_consensus_a-block.o): in function `uint256 HashX13sm3<char*>(char*, char*)':
/home/gilsun91/bitcoin-0.20/src/./hash.h:178: undefined reference to `sph_blake512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:179: undefined reference to `sph_blake512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:180: undefined reference to `sph_blake512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:182: undefined reference to `sph_bmw512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:183: undefined reference to `sph_bmw512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:184: undefined reference to `sph_bmw512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:186: undefined reference to `sph_groestl512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:187: undefined reference to `sph_groestl512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:188: undefined reference to `sph_groestl512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:190: undefined reference to `sph_skein512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:191: undefined reference to `sph_skein512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:192: undefined reference to `sph_skein512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:194: undefined reference to `sph_jh512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:195: undefined reference to `sph_jh512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:196: undefined reference to `sph_jh512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:198: undefined reference to `sph_keccak512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:199: undefined reference to `sph_keccak512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:200: undefined reference to `sph_keccak512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:204: undefined reference to `sm3_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:205: undefined reference to `sph_sm3'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:206: undefined reference to `sph_sm3_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:208: undefined reference to `sph_cubehash512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:209: undefined reference to `sph_cubehash512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:210: undefined reference to `sph_cubehash512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:212: undefined reference to `sph_shavite512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:213: undefined reference to `sph_shavite512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:214: undefined reference to `sph_shavite512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:216: undefined reference to `sph_simd512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:217: undefined reference to `sph_simd512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:218: undefined reference to `sph_simd512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:220: undefined reference to `sph_echo512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:221: undefined reference to `sph_echo512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:222: undefined reference to `sph_echo512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:224: undefined reference to `sph_hamsi512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:225: undefined reference to `sph_hamsi512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:226: undefined reference to `sph_hamsi512_close'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:228: undefined reference to `sph_fugue512_init'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:229: undefined reference to `sph_fugue512'
/usr/bin/ld: /home/gilsun91/bitcoin-0.20/src/./hash.h:230: undefined reference to `sph_fugue512_close'

Do You Know The Best Mobile App Development Service?

The best mobile app development service is the one who assure you the best user interface and user experience at affordable price, that’s exactly what Qdexi Technology offers you the top notch app development with proper customer support. contact Qdexi for exiting deals and quality services.

campaign development – How to design a maze without it being a time sink maze and unfun?

I was planning a 1e The One Ring game where the party gets trapped in the mines of Moria and have to get out. I had asked a question about the roles here. After discussing it with others, my idea of wandering an actual maze with multiple levels and various puzzles has been pointed out that its likely to be dull and boring for the players.

I am at a loss of how to run a maze, without it being an actual maze.

It was suggested I could use a position scale which would determine how the party was doing within the maze. Various challenges and checks would adjust the score as needed. It holds some merit, but one of my big surprises is the 3rd (and secret to the PC’s) exit which is the endless stairs is going to be really hard to work in if I did it in such a way. Plus, how would the PC’s really guide their route to one of the potential exits if their not actually wandering a maze that was designed? Granted, not having to create a 40 mile by 10 mile by 4 mile maze sounds rather nice at this point.

world design – Castlevania development process after mechanics are written

So I’ve been working on a game idea for the last several months. I’m a professional programmer so reworking my physics/game controller/mechanics from this jam demo went rather smoothly. It’s a Metroidvania game where you play as this little goblin. The issue is after writing the movement mechanics I have no idea how to start the actual development. Should I work on the overall story? It feels hard to start designing environments for an interconnected, large world but I need to start somewhere. I have lots of ideas, but no foothold. Any advice?

architecture – What is the difference between Kruchten’s Logical and Development view?

I want to understand the difference between Kruchten’s Logical and Development view when using a microservice architecture.

Krutchen describes the software architecture model 4+1 model with four different views.

Logical

The logical architecture primarily supports the functional
requirements — what the system should provide in terms of services to
its users.

Development

The development architecture focuses on the actual software module
organization on the software development environment. The software is
packaged in small chunks — program libraries or subsystems — that can
be developed by one or a small number of developers.

As I understand, the logical view uses class diagrams and state diagrams to illustrate the components. And the Development view uses a Package diagram. However, I have also found a source that says that the development view uses class diagrams.

The question then is how do they differ, and what is the correct definition of the views? What diagram form would I use to illustrate a microservice architecture?

web development – What is the recommended way of working with separate databases for each client?

We are building a software, which is deployed on multiple servers, one for each client. Each one has an own db and .env configuration. It is a PHP project.

The backend code is the same, and we would like to deploy it only once, then use the appropriate db for each request, based on the domain name or user. Currently client1.example.com and client2.example.com points to different servers, but we would like to serve all from a single server under *.example.com. Unfortunately some of the clients databases have to remain separated.

It is a large monolithic software, so it may be also beneficial to split it up into microservices. This may make the solution easier.