This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Play.mod

Discussion of Eggdrop's code and module programming in C.
Post Reply
B
BoaR
Halfop
Posts: 48
Joined: Fri Jul 20, 2007 1:36 am

Play.mod

Post by BoaR »

please help me install it and use it, i have moved play.mod folder on the modules folder in the eggdrop source folder and did a clean installation.

make clean..
./configuer ..etc.

i can see the play.o file inside the modules after the eggdrop compilation but the perpleXa script doesnt find it or something ..

http://perplexa.ugug.org/web/uploads/files/play.mod.zip
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

Sure it was play.o and not play.so?
Would seem it was'nt properly linked then...

Or were you talking of the source-tree? In that case, the play.so should be found in the base of the sourcetree, while the play.o file would be found where you unpacked the mod-source.

In either case, .o files will not load as module, as they're just compiled and not linked. You'll need the .so version to be able to load it.
NML_375
B
BoaR
Halfop
Posts: 48
Joined: Fri Jul 20, 2007 1:36 am

Post by BoaR »

i will recompile my bots, i dont see a module folder in the compiled eggdrop folder so i guess i have a linking problem, other modules compiled fine because i am able to use them..
B
BoaR
Halfop
Posts: 48
Joined: Fri Jul 20, 2007 1:36 am

Post by BoaR »

In file included from .././play.mod/play.c:16:
/usr/include/malloc.h:3:2: #error "<malloc.h> has been replaced by <stdlib.h>"
.././play.mod/play.c:18:50: pcre.h: No such file or directory
.././play.mod/play.c: In function `tcl_mallinfo':
.././play.mod/play.c:38: error: storage size of 'mi' isn't known
.././play.mod/play.c:39: warning: implicit declaration of function `mallinfo'
.././play.mod/play.c:38: warning: unused variable `mi'
.././play.mod/play.c: In function `tcl_pcre':
.././play.mod/play.c:56: error: `pcre' undeclared (first use in this function)
.././play.mod/play.c:56: error: (Each undeclared identifier is reported only once
.././play.mod/play.c:56: error: for each function it appears in.)
.././play.mod/play.c:56: error: `curpat' undeclared (first use in this function)
.././play.mod/play.c:77: error: `PCRE_CASELESS' undeclared (first use in this function)
.././play.mod/play.c:100: warning: implicit declaration of function `pcre_compile'
.././play.mod/play.c:106: warning: implicit declaration of function `pcre_exec'
.././play.mod/play.c:115: warning: implicit declaration of function `pcre_copy_substring'
*** Error code 1

Stop in /home/boar/eggdrop1.6.18/src/mod/play.mod.
*** Error code 1

Stop in /home/boar/eggdrop1.6.18/src/mod.
*** Error code 1

Stop in /home/boar/eggdrop1.6.18.
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

It would seem you're lacking the Perl Compatible Regular Expression library on your system, which is required for this module to compile successfully.
NML_375
B
BoaR
Halfop
Posts: 48
Joined: Fri Jul 20, 2007 1:36 am

Post by BoaR »

i edited play.c:

#include </usr/src/include/stdlib.h> /* tcl_mallinfo */
#include </usr/include/sys/resource.h> /* tcl_cputime */
#include </usr/local/include/pcre.h> /* tcl_pcre */

but i still get errors:

.././play.mod/play.c: In function `tcl_mallinfo':
.././play.mod/play.c:38: error: storage size of 'mi' isn't known
.././play.mod/play.c:39: warning: implicit declaration of function `mallinfo'
.././play.mod/play.c:38: warning: unused variable `mi'
*** Error code 1

Stop in /home/boar/eggdrop1.6.18/src/mod/play.mod.
*** Error code 1

Stop in /home/boar/eggdrop1.6.18/src/mod.
*** Error code 1

Stop in /home/boar/eggdrop1.6.18.
n
nml375
Revered One
Posts: 2860
Joined: Fri Aug 04, 2006 2:09 pm

Post by nml375 »

It would seem malloc.h is included from an incorrect location

Code: Select all

#include "malloc.h"
Should rather be:

Code: Select all

#include <malloc.h>
Or, on second thought, you did get an error earlier 'bout malloc.h being replaced with stdlib.h. It would seem it does not declare the mallinfo struct properly.
NML_375
B
BoaR
Halfop
Posts: 48
Joined: Fri Jul 20, 2007 1:36 am

Post by BoaR »

i guess that mod needs some tweaking..

i found malloc.h in /usr/include/malloc.h so i will try that today maybe..

thanks
Post Reply