Author

Topic: [SOLVED] Did pull, can't compile due to miniupnpc problems (Read 6232 times)

full member
Activity: 128
Merit: 100
Point. I missed the part where it says

miniupnpc
---------
tar -xzvf miniupnpc-1.5.tar.gz
cd miniupnpc-1.5
make
sudo su
make install

which is weird because it is just below the part that I DID read to install wxWidgets...

Thanks for your time and I want you to know I appreciate your work.
hero member
Activity: 755
Merit: 515
file is in /home/cdnbcguy/miniupnpc-1.5.20110314 so I go into sudo natulus and copy it to /usr/include/miniupnpc/

/usr/include/miniupnpc/upnpcommands.h:117: error: too few arguments to function ‘int UPNP_AddPortMapping(const char*, const char*, const char*, const char*, const char*, const char*, const char*, const char*, const char*)’
I thought I made it clear in the make file but I guess not as I've seen this too many times.
For the unix and osx makefiles, you need the 1.5 stable version of miniupnpc (ie miniupnpc-1.5 not miniupnpc-1.5.XXXXXXXX).  This was done due to build issues I and several others have seen on various new versions and because its always better to use the release versions. 
You'll notice in net.cpp that there is a different UPNP_AddPortMapping command for Windows due to other build issues there.  If you really need to use the latest versions of miniupnpc, you can simply use that command instead. 
full member
Activity: 128
Merit: 100
Worked. Thanks to you guys, you rule!
legendary
Activity: 1072
Merit: 1189
Remove your previous obj/*.o files.
full member
Activity: 128
Merit: 100
Thank you very much - it goes a lot further but kaks with this

obj/db.o: In function `CWalletDB::LoadWallet()':
/home/cdnbcguy/bitcoin from github/bitcoin/db.cpp:811: undefined reference to `fUseUPnP'
obj/db.o: In function `Unserialize':
/home/cdnbcguy/bitcoin from github/bitcoin/serialize.h:136: undefined reference to `fUseUPnP'
collect2: ld returned 1 exit status
make: *** [bitcoin] Error 1


legendary
Activity: 2576
Merit: 1186
For now, use this:
Code:
make -f makefile.unix USE_UPNP=
Yes, that's a null value, not a 0.
full member
Activity: 128
Merit: 100
I've been around computers since forever but due to stuff happening I am new to Unix.

Had 3.20 compiling and running fine.

Did git pull, tried make said can't find a miniupnpc file /usr/include/miniupnpc/portlistingparse.h

Re-read build-unix.txt - noticed new miniupnpc thingy.

got miniupnpc and ran make then make install.

tried make for Bitcoin - got can't find file again. The install didn't put it there.

file is in /home/cdnbcguy/miniupnpc-1.5.20110314 so I go into sudo natulus and copy it to /usr/include/miniupnpc/

I realize I am probably in a state of sin by this time.

I do this again for two other files.

NOW when I run make I don't get that error any more I get this one

cdnbcguy@beauty:~/bitcoin from github/bitcoin$ make -f makefile.unix
g++ -c -O2 -Wno-invalid-offsetof -Wformat -g -D__WXDEBUG__ -DNOPCH -DFOURWAYSSE2 -DUSE_SSL -DUSE_UPNP=0 -I/usr/local/lib/wx/include/gtk2-unicode-debug-static-2.9 -I/usr/local/include/wx-2.9 -D_FILE_OFFSET_BITS=64 -D__WXDEBUG__ -D__WXGTK__ -pthread -DGUI -o obj/net.o net.cpp
/usr/include/miniupnpc/miniupnpc.h: In function ‘void ThreadMapPort2(void*)’:
/usr/include/miniupnpc/miniupnpc.h:53: error: too few arguments to function ‘UPNPDev* upnpDiscover(int, const char*, const char*, int, int*)’
net.cpp:903: error: at this point in file
/usr/include/miniupnpc/upnpcommands.h:117: error: too few arguments to function ‘int UPNP_AddPortMapping(const char*, const char*, const char*, const char*, const char*, const char*, const char*, const char*, const char*)’
net.cpp:916: error: at this point in file
make: *** [obj/net.o] Error 1

Could someone please point out the obvious chickenshit error I have made, please?
Jump to: