docsis on debian | docsis.org

You are here

docsis on debian

22 posts / 0 new
Last post
emkowale
docsis on debian

Hello,

Has anyone been successful in compiling docsis-0.9.5.tar.gz on Debian?

Thanks,
emkowale

emkowale
<bump>

Hello,

Still stuck on this one. Here is the out put of the ./configure (which seems to work fine) and the make (which fails):

teletran02:/usr/src# cd docsis-0.9.5

teletran02:/usr/src/docsis-0.9.5# ./configure

checking for a BSD-compatible install... /usr/bin/install -c

checking whether build environment is sane... yes

checking for gawk... no

checking for mawk... mawk

checking whether make sets $(MAKE)... yes

checking for gcc... gcc

checking for C compiler default output file name... a.out

checking whether the C compiler works... yes

checking whether we are cross compiling... no

checking for suffix of executables...

checking for suffix of object files... o

checking whether we are using the GNU C compiler... yes

checking whether gcc accepts -g... yes

checking for gcc option to accept ANSI C... none needed

checking for style of include used by make... GNU

checking dependency style of gcc... gcc3

checking build system type... i686-pc-linux

checking host system type... i686-pc-linux

checking for a sed that does not truncate output... /bin/sed

checking for egrep... grep -E

checking for ld used by gcc... /usr/bin/ld

checking if the linker (/usr/bin/ld) is GNU ld... yes

checking for /usr/bin/ld option to reload object files... -r

checking for BSD-compatible nm... /usr/bin/nm -B

checking whether ln -s works... yes

checking how to recognise dependent libraries... pass_all

checking how to run the C preprocessor... gcc -E

checking for ANSI C header files... yes

checking for sys/types.h... yes

checking for sys/stat.h... yes

checking for stdlib.h... yes

checking for string.h... yes

checking for memory.h... yes

checking for strings.h... yes

checking for inttypes.h... yes

checking for stdint.h... yes

checking for unistd.h... yes

checking dlfcn.h usability... yes

checking dlfcn.h presence... yes

checking for dlfcn.h... yes

checking for g++... g++

checking whether we are using the GNU C++ compiler... yes

checking whether g++ accepts -g... yes

checking dependency style of g++... gcc3

checking how to run the C++ preprocessor... g++ -E

checking for g77... no

checking for f77... no

checking for xlf... no

checking for frt... no

checking for pgf77... no

checking for fort77... no

checking for fl32... no

checking for af77... no

checking for f90... no

checking for xlf90... no

checking for pgf90... no

checking for epcf90... no

checking for f95... f95

checking whether we are using the GNU Fortran 77 compiler... yes

checking whether f95 accepts -g... yes

checking the maximum length of command line arguments... 32768

checking command to parse /usr/bin/nm -B output from gcc object... ok

checking for objdir... .libs

checking for ar... ar

checking for ranlib... ranlib

checking for strip... strip

checking if gcc static flag works... yes

checking if gcc supports -fno-rtti -fno-exceptions... no

checking for gcc option to produce PIC... -fPIC

checking if gcc PIC flag -fPIC works... yes

checking if gcc supports -c -o file.o... yes

checking whether the gcc linker (/usr/bin/ld) supports shared libraries...
yes

checking whether -lc should be explicitly linked in... no

checking dynamic linker characteristics... GNU/Linux ld.so

checking how to hardcode library paths into programs... immediate

checking whether stripping libraries is possible... yes

checking if libtool supports shared libraries... yes

checking whether to build shared libraries... yes

checking whether to build static libraries... yes

configure: creating libtool

appending configuration tag "CXX" to libtool

checking for ld used by g++... /usr/bin/ld

checking if the linker (/usr/bin/ld) is GNU ld... yes

checking whether the g++ linker (/usr/bin/ld) supports shared libraries...
yes

checking for g++ option to produce PIC... -fPIC

checking if g++ PIC flag -fPIC works... yes

checking if g++ supports -c -o file.o... yes

checking whether the g++ linker (/usr/bin/ld) supports shared libraries...
yes

checking dynamic linker characteristics... GNU/Linux ld.so

checking how to hardcode library paths into programs... immediate

checking whether stripping libraries is possible... yes

appending configuration tag "F77" to libtool

checking if libtool supports shared libraries... yes

checking whether to build shared libraries... yes

checking whether to build static libraries... yes

checking for f95 option to produce PIC... -fPIC

checking if f95 PIC flag -fPIC works... yes

checking if f95 supports -c -o file.o... yes

checking whether the f95 linker (/usr/bin/ld) supports shared libraries...
yes

checking dynamic linker characteristics... GNU/Linux ld.so

checking how to hardcode library paths into programs... immediate

checking whether stripping libraries is possible... yes

checking for flex... no

checking for lex... no

checking for yywrap in -lfl... no

checking for yywrap in -ll... no

checking for inet_aton in -lresolv... yes

checking for gm4... no

checking for gnum4... no

checking for m4... /usr/bin/m4

found GNU M4 1.4.8 at /usr/bin/m4

checking for bison... /usr/bin/bison

found bison version 2003000, using /usr/bin/bison -t -d -y

checking for net-snmp-config... /usr/bin/net-snmp-config

found net-snmp version 5002003

checking for Cygwin... no

configure: creating ./config.status

config.status: creating Makefile

config.status: creating src/Makefile

config.status: creating doc/Makefile

config.status: creating examples/Makefile

config.status: creating mibs/Makefile

config.status: creating config.h

config.status: executing depfiles commands

teletran02:/usr/src/docsis-0.9.5# make

make all-recursive

make[1]: Entering directory `/usr/src/docsis-0.9.5'

Making all in src

make[2]: Entering directory `/usr/src/docsis-0.9.5/src'

if gcc -DHAVE_CONFIG_H -I. -I. -I.. -DINET6 -O2 -D_REENTRANT
-DNETSNMP_USE_INLINE -Wall -Dlinux -I. -I/usr/include -g -O2 -MT docsis.o
-MD -MP -MF ".deps/docsis.Tpo" -c -o docsis.o docsis.c; \

then mv -f ".deps/docsis.Tpo" ".deps/docsis.Po"; else rm -f ".deps/docsis.Tpo"; exit 1; fi

if gcc -DHAVE_CONFIG_H -I. -I. -I.. -DINET6 -O2 -D_REENTRANT
-DNETSNMP_USE_INLINE -Wall -Dlinux -I. -I/usr/include -g -O2 -MT
ethermac.o -MD -MP -MF ".deps/ethermac.Tpo" -c -o ethermac.o ethermac.c; \

then mv -f ".deps/ethermac.Tpo" ".deps/ethermac.Po"; else rm -f ".deps/ethermac.Tpo"; exit 1; fi

if gcc -DHAVE_CONFIG_H -I. -I. -I.. -DINET6 -O2 -D_REENTRANT
-DNETSNMP_USE_INLINE -Wall -Dlinux -I. -I/usr/include -g -O2 -MT md5.o
-MD -MP -MF ".deps/md5.Tpo" -c -o md5.o md5.c; \

then mv -f ".deps/md5.Tpo" ".deps/md5.Po"; else rm -f ".deps/md5.Tpo"; exit 1; fi

if gcc -DHAVE_CONFIG_H -I. -I. -I.. -DINET6 -O2 -D_REENTRANT
-DNETSNMP_USE_INLINE -Wall -Dlinux -I. -I/usr/include -g -O2 -MT
docsis_encode.o -MD -MP -MF ".deps/docsis_encode.Tpo" -c -o docsis_encode.o docsis_encode.c; \

then mv -f ".deps/docsis_encode.Tpo" ".deps/docsis_encode.Po"; else rm -f ".deps/docsis_encode.Tpo"; exit 1; fi

if gcc -DHAVE_CONFIG_H -I. -I. -I.. -DINET6 -O2 -D_REENTRANT
-DNETSNMP_USE_INLINE -Wall -Dlinux -I. -I/usr/include -g -O2 -MT
docsis_decode.o -MD -MP -MF ".deps/docsis_decode.Tpo" -c -o docsis_decode.o docsis_decode.c; \

then mv -f ".deps/docsis_decode.Tpo" ".deps/docsis_decode.Po"; else rm -f ".deps/docsis_decode.Tpo"; exit 1; fi

docsis_decode.c: In function âdecode_unknownâ:

docsis_decode.c:248: warning: pointer targets in passing argument 1 of âsnprint_hexadecimalâ differ in signedness

docsis_decode.c: In function âsnprint_hexadecimalâ:

docsis_decode.c:479: warning: pointer targets in passing argument 1 of âsprintfâ differ in signedness

docsis_decode.c:483: warning: pointer targets in passing argument 1 of âsprintfâ differ in signedness

if gcc -DHAVE_CONFIG_H -I. -I. -I.. -DINET6 -O2 -D_REENTRANT
-DNETSNMP_USE_INLINE -Wall -Dlinux -I. -I/usr/include -g -O2 -MT
docsis_snmp.o -MD -MP -MF ".deps/docsis_snmp.Tpo" -c -o docsis_snmp.o docsis_snmp.c; \

then mv -f ".deps/docsis_snmp.Tpo" ".deps/docsis_snmp.Po"; else rm -f ".deps/docsis_snmp.Tpo"; exit 1; fi

docsis_snmp.c: In function âencode_vbindâ:

docsis_snmp.c:248: warning: pointer targets in passing argument 1 of âread_objidâ differ in signedness

docsis_snmp.c: In function âdecode_vbindâ:

docsis_snmp.c:566: warning: pointer targets in passing argument 1 of âstr_isprintâ differ in signedness

docsis_snmp.c:570: warning: pointer targets in passing argument 1 of âsnprint_hexadecimalâ differ in signedness

docsis_snmp.c:570: warning: pointer targets in passing argument 3 of âsnprint_hexadecimalâ differ in signedness

docsis_snmp.c:577: warning: pointer targets in passing argument 1 of âsnprint_hexadecimalâ differ in signedness

docsis_snmp.c:577: warning: pointer targets in passing argument 3 of âsnprint_hexadecimalâ differ in signedness

docsis_snmp.c: In function âdecode_snmp_oidâ:

docsis_snmp.c:655: warning: pointer targets in passing argument 2 of âasn_parse_objidâ differ in signedness

if gcc -DHAVE_CONFIG_H -I. -I. -I.. -DINET6 -O2 -D_REENTRANT
-DNETSNMP_USE_INLINE -Wall -Dlinux -I. -I/usr/include -g -O2 -MT
docsis_yy.o -MD -MP -MF ".deps/docsis_yy.Tpo" -c -o docsis_yy.o docsis_yy.c; \

then mv -f ".deps/docsis_yy.Tpo" ".deps/docsis_yy.Po"; else rm -f ".deps/docsis_yy.Tpo"; exit 1; fi

if gcc -DHAVE_CONFIG_H -I. -I. -I.. -DINET6 -O2 -D_REENTRANT
-DNETSNMP_USE_INLINE -Wall -Dlinux -I. -I/usr/include -g -O2 -MT
docsis_lex.o -MD -MP -MF ".deps/docsis_lex.Tpo" -c -o docsis_lex.o docsis_lex.c; \

then mv -f ".deps/docsis_lex.Tpo" ".deps/docsis_lex.Po"; else rm -f ".deps/docsis_lex.Tpo"; exit 1; fi

docsis_lex.c:1861: warning: âyyunputâ defined but not used

if gcc -DHAVE_CONFIG_H -I. -I. -I.. -DINET6 -O2 -D_REENTRANT
-DNETSNMP_USE_INLINE -Wall -Dlinux -I. -I/usr/include -g -O2 -MT
hmac_md5.o -MD -MP -MF ".deps/hmac_md5.Tpo" -c -o hmac_md5.o hmac_md5.c; \

then mv -f ".deps/hmac_md5.Tpo" ".deps/hmac_md5.Po"; else rm -f ".deps/hmac_md5.Tpo"; exit 1; fi

/bin/sh ../libtool --mode=link --tag=CC gcc -g -O2 -o docsis -L/usr/lib
-lnetsnmp -lm -lwrap -lwrap docsis.o ethermac.o md5.o docsis_encode.o
docsis_decode.o docsis_snmp.o docsis_yy.o docsis_lex.o hmac_md5.o -lresolv

mkdir .libs

gcc -g -O2 -o docsis docsis.o ethermac.o md5.o docsis_encode.o docsis_decode.o docsis_snmp.o docsis_yy.o docsis_lex.o hmac_md5.o -L/usr/lib /usr/lib/libnetsnmp.so -lcrypto -lm -lwrap -lresolv

docsis_lex.o: In function `yylex':

/usr/src/docsis-0.9.5/src/docsis_lex.c:1594: undefined reference to `yywrap'

collect2: ld returned 1 exit status

make[2]: *** [docsis] Error 1

make[2]: Leaving directory `/usr/src/docsis-0.9.5/src'

make[1]: *** [all-recursive] Error 1

make[1]: Leaving directory `/usr/src/docsis-0.9.5'

make: *** [all] Error 2

teletran02:/usr/src/docsis-0.9.5#

Thanks,

Eric

DocsisAdmin
common error?

"undefined reference to `yywrap'" seems to be a fairly common compilation error - lots of google results. Seems to happen when "configure" is not looking in the right location for that library.

http://cygwin.com/ml/cygwin/2003-05/msg00785.html

I'd contact the project's author; he might have an idea about how to change the compilation options so that it works a bit more universally.

sonny
guys do you have installed

guys
do you have installed snmp libary ?

emkowale
AWSOME!!!!!!!!!

Hi,

Hey thanks for the tip! After some googling, I found that I needed to install flex. A simple 'apt-get install flex' solved the whole issue. Now I can programatically collect all data for a subscriber through my web interface, build the necessary config files and programatically send them to the servers located at each of my properties. Home brew provisioning 7 years in the making!!!!!

Thanks,
emkowale

rbTechLLC
I apologize for missing this

I apologize for missing this thread; I ran into exactly the same issue trying to compile it on both Mandriva 2007.1, 2008.0 and CentOS5.1. Same issue, same fix on all (install flex and, IIRC, bison-devel).

Rubin

light (not verified)
which "m4" ?

I have ubuntu-server 7.10 with installed from official repository flex, bison, any other developer tools (build-essentials, libc6-dev), even m4, but ./configure result follows:
...
checking for strstr... yes
checking for strtoull... yes
checking for gm4... no
checking for gnum4... no
checking for m4... /usr/bin/m4
configure: error: GNU M4 is needed

I have tried install m4 from source - with same result

I have the same in mandriva 2008 and FreeBSD, too

google have sayed none important about "GNU M4"

how to defeat this one?

kwesibrunee
you can run the following

you can run the following command on your ubuntu server

sudo apt-get install m4

it will prompt you for roots password and you should be good to go no need to build it from source.

light (not verified)
already installed

sorry, but m4 is already installed from repository, as I wrote above

kwesibrunee
Sorry I missed the part

Sorry I missed the part where you said you had installed m4

is the binary located at /usr/bin/m4? According to ubuntu.org it should be, if not then you have to tell configure where it is usually something like --with-m4=/path/to/m4, run ./configure --help to find out the proper command.

is it executable? if not fix it.

are you running configure as root or using sudo? if not the user you are using to run configure with likely does not have permissions to use that file.

if you are still having trouble, please post the whole ./configure output as well as the original command used to invoke it.

DocsisAdmin
Where is your M4?

Where is your M4? After checking for m4 in various ways, your debug finally seems to go down to:
"checking for m4... /usr/bin/m4
configure: error: GNU M4 is needed"

I'd start by figuring out if the message is saying that you don't have a m4 binary at /usr/bin/m4, or if there is, if it's thinking that the binary isn't compatible.

I'm not at all familiar with Debian. My RHEL5 seems to have it at that location:
# ll /usr/bin/m4
-rwxr-xr-x 1 root root 64132 Mar 21 2007 /usr/bin/m4

# m4 --version
GNU M4 1.4.5
Written by Rene' Seindal.

If you have it compiled and installed in /usr/local/bin/m4 or something like that, create a symlink so that it appears under /usr/bin as well. Between this and kwesibrunee's suggestions, you'll probably be in business. Hope that helps-

light (not verified)
may be old version needed?

[root@localhost light]# ll /usr/bin/m4
-rwxr-xr-x 1 root root 109068 2008-01-15 21:49 /usr/bin/m4*
[root@localhost light]# m4 --version
m4 (GNU M4) 1.4.10
Copyright (C) 2007 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Written by Rene' Seindal.

this figure shows in ubuntu, mandriva and freebsd...

I want to use old version, but can't find it

DocsisAdmin
"configure" file

I'll make this quick - I just finished writing a long post about how to "fix" the broken M4 detect script so that docsis would compile for you, but as I was finishing my research I found that other people have already submitted patches:

http://www.google.com/search?q=docsis+gnu+m4+detect+patch

I went to browse the CVS at the sourceforge docsis site to see if it was already committed to a newer version, but I wasn't able to find any files in CVS at all. This means you'll need to apply the patch yourself. Are you familiar with applying patches to source code? The patch below modifies just a couple of lines in the "configure" file. Create a patchfile with the info below, and run "patch /path/to/docsis /patch/to/patchfile.patch"

--- /dev/null Sat Sep 22 01:35:07 2007
+++ SOURCES/docsis-gnu-m4-detect.patch Sat Sep 22 01:35:02 2007
@@ -0,0 +1,11 @@
+--- docsis-0.9.5/configure.in~ 2007-09-22 00:55:03.862858273 +0200
++++ docsis-0.9.5/configure.in 2007-09-22 00:58:30.177668639 +0200
+@@ -16,7 +16,7 @@
+ AC_MSG_ERROR([M4 is required])
+ else
+ ac_m4_vers=`$M4 --version 2>/dev/null | head -1` ;
+- ac_is_gnu_m4=`echo $ac_m4_vers | cut -d' ' -f1`;
++ ac_is_gnu_m4=`echo $ac_m4_vers | grep -q GNU && echo GNU` ;
+ if test "x$ac_is_gnu_m4" = "xGNU"; then
+ AC_MSG_RESULT([ found $ac_m4_vers at $M4 ])
+ else

DouganBrightaxe
Same issues

I am having the same issues as others on this thread. Hate to dig up an old thread, but would really appreciate some help. Essentially errors when it gets to:

checking for m4... /usr/bin/m4
configure: error: GNU M4 is needed

I have a copy of my config.log @ http://magnorock.googlepages.com/config.log

I am trying to install Docsis Server on Ubuntu 9.04 64 bit server.

$ m4 --version
m4 (GNU M4) 1.4.11

It is located where it should be - /usr/bin/m4

Installed flex, build-essentials, gawk...

I then tried the patch mentioned above, but didn't help. Advice, tips?

frnkblk
I've had success compiling

I've had success compiling it on Debian 2.6.18-6-amd64, but not without errors. I can decode binary files just fine, but not encode them. The gaps in the encode and errors suggest that they have to do with the warning I'm getting compilation:
docsis_decode.c: In function âsnprint_hexadecimalâ:
docsis_decode.c:479: warning: pointer targets in passing argument 1 of âsprintfâ differ in signedness
docsis_decode.c:483: warning: pointer targets in passing argument 1 of âsprintfâ differ in signedness
......
docsis_snmp.c: In function âencode_vbindâ:
docsis_snmp.c:107: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type
docsis_snmp.c:118: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type
docsis_snmp.c:129: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type
docsis_snmp.c:140: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type
docsis_snmp.c:151: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type
docsis_snmp.c:213: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type

It looks like gcc version 4 is a bit more strict. I can compile just fine on my *old* Fedora box, but that doesn't help me on Debian.

Any tips or hints? If someone has a compiled version they're willing to share me, I'll take that, too.

Frank

kwesibrunee
I have it compiled on Debian

I have it compiled on Debian kernel 2.6.18-6-686 SMP
I am able to decode and encode fine
the version of GCC used was 4.1.1-15

perhaps it is a 64 bit issue?

I do not have a 64 bit debian machine to compile it on,however I have a 64bit RPM built on Centos 5 kernel 2.6.18-92.1.22.el5 SMP which you could use alien with to see if you could get to work. it was compiled with gcc-4.1.2-42

email me offlist if your interested.... jasonp at cablemo dot c o m

frnkblk
Updating docsis

I contacted Jason offlist, so hopefully we can find a resolution for my compilation problem.

The sourceforge site hosts docsis code that's aging, despite patches that I've seen posted by twittner.

Does anyone have any skill or interest in patching the sourcecode contributions that twittner has made, and willing to test compiling and running docsis against different 32 and 64-bit platforms until it works?

Frank

r_asati (not verified)
docsis-0.9.5 not getting complied on GNU/Linux x86_64

It is not compiling for me either.

DouganBrightaxe
same issues

I am having the same issues as others on this thread. Hate to dig up an old thread, but would really appreciate some help. Essentially errors when it gets to:

checking for m4... /usr/bin/m4
configure: error: GNU M4 is needed

I have a copy of my config.log @ http://magnorock.googlepages.com/config.log

I am trying to install Docsis Server on Ubuntu 8.04 64 bit server.

$ m4 --version
m4 (GNU M4) 1.4.11

It is located where it should be - /usr/bin/m4

Installed flex, build-essentials, gawk...

I then tried the patch mentioned above, but didn't help. Advice, tips? It appears others have had these same issues, did you get resolution?

bobcat
GNU M4
DouganBrightaxe wrote: [quote]checking for m4... /usr/bin/m4 configure: error: GNU M4 is needed[/quote] This is because the configure script runs "m4 --version" and expect the first word on the first line to be GNU. M4 version 1.4.6 says: # m4 --version GNU M4 1.4.6 M4 version 1.4.12 says: # m4 --version m4 (GNU M4) 1.4.12 You need a hack to fix this. The easiest way is to check the first word on the first line of m4 --version and alter the configure script. Locate this line: if test "x$ac_is_gnu_m4" = "xGNU"; then It's around line number 19515 Replace xGNU with xm4 or whatever your m4 says on the fist line, first word. Don't delete the x -Bob-
barryQ1974
docsis_snmp.c: In function

docsis_snmp.c: In function âencode_vbindâ:
docsis_snmp.c:107: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type
docsis_snmp.c:118: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type
docsis_snmp.c:129: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type
docsis_snmp.c:140: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type
docsis_snmp.c:151: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type
docsis_snmp.c:213: warning: passing argument 7 of â_docsis_snmp_build_var_opâ from incompatible pointer type

BAHHHHH! Getting the same thing and can't figure it out grrrr

--------------------
\ Barry Q /
\ Naples Computer /

wittmann
After some years i must

After some years i must install the docsis-tool from Cornel again on an Debian Lenny (5.0).

This link helps me:

http://www.krakow.dk/dokuwiki/doku.php?id=docsis_m4_check_patch

i put it here for the future. maybe i and you need him later again ;)

regards,

wittmann

P.S. Sorry for my poor english ;)

Log in or register to post comments