user32611: I currently trying to develop a simple Bitcoin miner in c++ for a project on my university. For parsing the 'getblocktemplate'-data I'm using libblkmaker.
Now I have to build the coinbase transaction for the 'blktmpl', but I don't really know how. 
Anyone knows how to add a coinbase transaction to the block-template with 'libblkmaker'?
And how do I add my bitcoin address to this?
Thanks for your help,
Sebastian

user4334: To set a generating address, use set_generate_addr. blkmk_init_generation3 may also be what you're looking for.
The author of that library also wrote a miner, BFGMiner, that uses his library. Look at how he calls these libblkmaker function to add a coinbase transaction to the block header in miner.c.

32611: <p>I currently trying to develop a simple Bitcoin miner in c++ for a project on my university. For parsing the 'getblocktemplate'-data I'm using <a href="https://github.com/bitcoin/libblkmaker" rel="nofollow">libblkmaker</a>.
Now I have to build the coinbase transaction for the 'blktmpl', but I don't really know how. </p>

<p><strong>Anyone knows how to add a coinbase transaction to the block-template with 'libblkmaker'?</strong></p>

<p><strong>And how do I add my bitcoin address to this?</strong></p>

<p>Thanks for your help,
Sebastian</p>
 4334: <p>To set a generating address, use <a href="https://github.com/luke-jr/bfgminer/blob/bfgminer/miner.c#L1343" rel="nofollow"><code>set_generate_addr</code></a>. <a href="https://github.com/bitcoin/libblkmaker/blob/master/blkmaker.c#L50" rel="nofollow"><code>blkmk_init_generation3</code></a> may also be what you're looking for.</p>

<p>The author of that library also wrote a miner, <a href="https://github.com/luke-jr/bfgminer/" rel="nofollow">BFGMiner</a>, that uses his library. Look at how he calls these <code>libblkmaker</code> function to add a coinbase transaction to the block header in <a href="https://github.com/luke-jr/bfgminer/blob/bfgminer/miner.c" rel="nofollow"><code>miner.c</code></a>.</p>
