MoBlock install problems
ok I'm trying to install moblock so I follow the directions and run "make" and I get a big string of error messages ok so I open the make file....
# To use the old-soon-to-be-deprecated libipq interface # uncomment the following line and comment the NFQUEUE one, # then comment the gcc line with netfilter_queue and # uncomment the following one. #QUEUE_LIB=LIBIPQ QUEUE_LIB=NFQUEUE CFLAGS=-Wall -O2 -march=i586 -mtune=i686 -fomit-frame-pointer -ffast-math \ -D_GNU_SOURCE -D$(QUEUE_LIB) -L/usr/include/libipq CC=gcc all: moblock moblock: MoBlock.o rbt.o gcc -o $@ MoBlock.o rbt.o -lnetfilter_queue -lnfnetlink #gcc -o $@ MoBlock.o rbt.o -lipq strip $@ moblock-static: MoBlock.o rbt.o gcc -static -o $@ MoBlock.o rbt.o -lnetfilter_queue -lnfnetlink #gcc -static -o $@ MoBlock.o rbt.o -lipq strip $@ clean: rm -f *.o *~ *# moblock install: install -m 755 moblock $(DESTDIR)/usr/bin .PHONY: clean so what are the "following lines" and comment the "NFQUEUE" with what? (I'm assuming this is what I have to do because like I said when I run make I just get a big string of error messages) any suggestions |
and this is the error message I get when I run make....
gcc -Wall -O2 -march=i586 -mtune=i686 -fomit-frame-pointer -ffast-math -D_GNU_SOURCE -DNFQUEUE -L/usr/include/libipq -c -o MoBlock.o MoBlock.c In file included from /usr/include/linux/netfilter_ipv4.h:8, from MoBlock.c:35: /usr/include/linux/netfilter.h:40: error: expected specifier-qualifier-list before ‘__u32’ MoBlock.c:46:52: error: libnetfilter_queue/libnetfilter_queue.h: No such file or directory MoBlock.c:377: warning: ‘struct nfq_data’ declared inside parameter list MoBlock.c:377: warning: its scope is only this definition or declaration, which is probably not what you want MoBlock.c:377: warning: ‘struct nfgenmsg’ declared inside parameter list MoBlock.c:377: warning: ‘struct nfq_q_handle’ declared inside parameter list MoBlock.c: In function ‘nfqueue_cb’: MoBlock.c:384: warning: implicit declaration of function ‘nfq_get_msg_packet_hdr’ MoBlock.c:384: warning: assignment makes pointer from integer without a cast MoBlock.c:386: error: dereferencing pointer to incomplete type MoBlock.c:387: warning: implicit declaration of function ‘nfq_get_payload’ MoBlock.c:389: error: dereferencing pointer to incomplete type MoBlock.c:392: warning: implicit declaration of function ‘nfq_set_verdict’ MoBlock.c: In function ‘netlink_loop’: MoBlock.c:497: warning: implicit declaration of function ‘nfq_open’ MoBlock.c:497: warning: assignment makes pointer from integer without a cast MoBlock.c:503: warning: implicit declaration of function ‘nfq_unbind_pf’ MoBlock.c:508: warning: implicit declaration of function ‘nfq_bind_pf’ MoBlock.c:514: warning: implicit declaration of function ‘nfq_create_queue’ MoBlock.c:514: warning: assignment makes pointer from integer without a cast MoBlock.c:520: warning: implicit declaration of function ‘nfq_set_mode’ MoBlock.c:520: error: ‘NFQNL_COPY_PACKET’ undeclared (first use in this function) MoBlock.c:520: error: (Each undeclared identifier is reported only once MoBlock.c:520: error: for each function it appears in.) MoBlock.c:525: warning: implicit declaration of function ‘nfq_nfnlh’ MoBlock.c:525: warning: assignment makes pointer from integer without a cast MoBlock.c:526: warning: implicit declaration of function ‘nfnl_fd’ MoBlock.c:529: warning: implicit declaration of function ‘nfq_handle_packet’ MoBlock.c:533: warning: implicit declaration of function ‘nfq_destroy_queue’ MoBlock.c:534: warning: implicit declaration of function ‘nfq_close’ make: *** [MoBlock.o] Error 1 |
It means you shoult uncomment line with LIBIPQ, and comment one witn NFQUEUE
Code:
QUEUE_LIB=LIBIPQ |
The first error means you need to install libnetfilter-queue-dev or whatever the equivalent package is called in OpenSUSE.
cheers, jdk |
Quote:
but there is a Suse 11 package here http://rpm.pbone.net/index.php3/stat....i586.rpm.html > libnetfilter_queue-devel-0.0.17-jen0.i586.rpm Depends on libnetfilter_queue1 http://rpm.pbone.net/index.php3/stat....i586.rpm.html > libnetfilter_queue1-0.0.17-jen0.i586.rpm which depends on libnfnetlink0 http://rpm.pbone.net/index.php3/stat....i586.rpm.html > libnfnetlink0-0.0.41-jen0.i586.rpm ... All together 26 KB ! ( http://rpm.pbone.net > > Search > "Advanced Search" ) Please install with # rpm -Uvh <package> <package> <package> ... to get /usr/include/libnetfilter_queue/libnetfilter_queue.h There is a libnfnetlink-devel-0.0.41-jen0.i586.rpm ( also required ) here http://rpm.pbone.net/index.php3/stat....i586.rpm.html ..... Good luck ! ..... |
ok I did this and this is the message I get...
gcc -Wall -O2 -march=i586 -mtune=i686 -fomit-frame-pointer -ffast-math -D_GNU_SOURCE -DNFQUEUE -L/usr/include/libipq -c -o MoBlock.o MoBlock.c In file included from /usr/include/linux/netfilter_ipv4.h:8, from MoBlock.c:35: /usr/include/linux/netfilter.h:40: error: expected specifier-qualifier-list before ‘__u32’ make: *** [MoBlock.o] Error 1 |
Well, the test I made this morning, was on Suse 11.1,
kernel 2.6.27.5 . Suse 11, kernel 2.5.25.xx : the kernel headers in /usr/include/linux are 2.6.25.5, and three of the required headers are different from other versions or missing ( compiler.h ). MoBlock may compile on anything else but Suse11/2.6.25. Suggest : use the static package http://download.berlios.de/moblock/M...c-i586.tar.bz2 Quote:
linux-2.6.27.x/include/linux/netfilter_ipv4.h, netfilter.h, compiler.h, and changing some lines from #include </linux/file.h> to #include "file.h" .) ..... |
I did use the static version the only difference is the static version comes with a executable file named moblock-static
There is a work around, using 2.6.27.x headers in Moblock-0.8/, linux-2.6.27.x/include/linux/netfilter_ipv4.h, netfilter.h, compiler.h, and changing some lines from #include </linux/file.h> to #include "file.h and you'll have to be more specific on how to do this as I have only been using linux for about a month so alot of this is still new to me |
No need to compile MoBlock, the static 'moblock' is OK,
just rename it as quoted above. But here it is : Copy headers e.g. linux-2.6.27.2/include/linux/netfilter_ipv4.h, netfilter.h, compiler.h to your source code folder Moblock-0.8/ Edit MoBlock.c line 35, #include <linux/netfilter_ipv4.h> to #include "netfilter_ipv4.h" Edit netfilter_ipv4.h line??, #include <linux/netfilter.h> to #include "netfilter.h" Edit netfilter.h line??, #include <linux/compiler.h> to #include "compiler.h" ..... Line numbers will depend on header version. ..... P.S.: A Linux OS with 2.6.26.8 headers works too, pclos2009 was used. ..... |
Quote:
|
1 Attachment(s)
Sorry ... then no need to do complicated stuff.
Please use MoBlock-0.8-static-i586, no reason not to use a package (static). Is meant to be used .. ..... The modifying example: The idea is to use headers ( files.h ) from a different kernel source, which you probably haven't got in your archive. ( Linux source code : http://www.kernel.org/ ) ..... |
2 Attachment(s)
..... Please rename files to " .h "
..... |
Quote:
P.S according to the maker MoBlock wont work with kernels 2.6.23 or newer (http://www.ngohq.com/general-softwar...for-linux.html) you should email the developers and tell them of your work I think they'd love to hear from you |
No need to download any "-2.6.29.4", may be of no use.
Who says headers from 2.6.29.4 would work ? A patch most often is a text file, the whole linux-2.6.29 is a 54 MB file, 321 MB when unpacked. The 3 headers, you want ( 2 modified ) are attached, post # 12. Click them, and you have them. Origin : 2.6.27.2 . ..... And I can repeat : "No need to compile MoBlock, the static 'moblock' is OK, just rename it as quoted above." ( see post #7 ). ..... |
oh wait moblock doesn't have a graphical interface shit sorry for my absent mindedness
|
All times are GMT -5. The time now is 12:41 AM. |