Hi Kumar,

Creating the windows installer from Linux SO is easy, I have been doing 
that for months, try to take a look into this 
documentation: 
http://documentation.wazuh.com/en/latest/ossec_installation_win.html 
in *"Compiling from sources"* section.

You will need:

CentOS:
$ yum install gcc-c++ gcc scons mingw32-gcc mingw64-gcc zlib-devel bzip2 
unzip 

Debian:
$ apt-get install gcc-mingw-w64 $ apt-get install nsis $ apt-get install 
make

Regards,

Pedro S.



On Thursday, April 14, 2016 at 3:06:16 PM UTC+2, Kumar Mg wrote:
>
> Thank you Victor.
>
>
> We tried with both 2.8.2 as well as the 2.8.3 version. But both were 
> throwing error for make.
>
> The changes were made as suggested, however there were some errors and not 
> sure if all the executables were created. 
>
> These are the only exe files under src\win-pkg
>  
>
> 04/14/2016  05:30 AM           139,059 add-localfile.exe
>
> 04/14/2016  05:30 AM           376,910 manage_agents.exe
>
> 04/14/2016  05:26 AM            17,920 ossec-lua.exe
>
> 04/14/2016  05:26 AM           333,565 ossec-luac.exe
>
> 04/14/2016  05:30 AM           141,048 os_win32ui.exe
>
> 04/14/2016  05:30 AM           142,606 setup-iis.exe
>
> 04/14/2016  05:30 AM           159,043 setup-syscheck.exe
>
>                7 File(s)      1,310,151 bytes
>
>
> These were the error we got while make.
>
> C:\Users\Administrator\Desktop\ossec_compile\ossec-hids-2.8.3\ossec-hids-2.8.3\s
>
> rc\win-pkg>"C:\MinGW\bin\gcc.exe" -o "ossec-agent" -Wall 
>  -DARGV0=\"ossec-agent\
>
> " -DCLIENT -DWIN32 -DOSSECHIDS icon.o os_regex/*.c os_net/*.c os_xml/*.c 
> zlib-1.
>
> 2.8/*.c config/*.c shared/*.c os_execd/*.c os_crypto/blowfish/*.c 
> os_crypto/md5/
>
> *.c os_crypto/sha1/*.c os_crypto/md5_sha1/*.c os_crypto/shared/*.c 
> rootcheck/*.c
>
> *.c -I. -Iheaders/ -lwsock32
>
> rootcheck/win-common.c: In function '__os_winreg_querykey':
>
> rootcheck/win-common.c:212:11: warning: variable 'sub_key_name_b' set but 
> not us
>
> ed [-Wunused-but-set-variable]
>
>      TCHAR sub_key_name_b[MAX_KEY_LENGTH +1];
>
>            ^
>
> In file included from run_realtime.c:45:0:
>
> headers/shared.h:181:0: warning: "os_calloc" redefined
>
> #define os_calloc(x,y,z) ((z = calloc(x,y)))?(void)1:ErrorExit(MEM_ERROR, 
> ARGV0
>
> )
>
> ^
>
> run_realtime.c:29:0: note: this is the location of the previous definition
>
> #define os_calloc(x,y,z) (z = calloc(x,y))?(void)1:ErrorExit(MEM_ERROR, 
> ARGV0)
>
> ^
>
> In file included from run_realtime.c:45:0:
>
> headers/shared.h:183:0: warning: "os_strdup" redefined
>
> #define os_strdup(x,y) ((y = strdup(x)))?(void)1:ErrorExit(MEM_ERROR, 
> ARGV0)
>
> ^
>
> run_realtime.c:30:0: note: this is the location of the previous definition
>
> #define os_strdup(x,y) (y = strdup(x))?(void)1:ErrorExit(MEM_ERROR, ARGV0)
>
> ^
>
> C:\Users\ADMINI~1\AppData\Local\Temp\cccRUZbH.o:file_op.c:(.text+0x9e6): 
> undefin
>
> ed reference to `_imp__PathFindFileNameA@4'
>
> collect2.exe: error: ld returned 1 exit status
>
>  
>
>
> C:\Users\Administrator\Desktop\ossec_compile\ossec-hids-2.8.3\ossec-hids-2.8.3\s
>
> rc\win-pkg>"C:\MinGW\bin\gcc.exe" -o "ossec-rootcheck" -Wall 
>  -DARGV0=\"ossec-ro
>
> otcheck\" -DCLIENT -DWIN32 icon.o os_regex/*.c os_net/*.c os_xml/*.c 
> config/*.c
>
> shared/*.c win_service.c rootcheck/*.c -Iheaders/ -I. -lwsock32
>
> rootcheck/rootcheck-config.c: In function 'Read_Rootcheck_Config':
>
> rootcheck/rootcheck-config.c:69:18: warning: variable 'xml_time' set but 
> not use
>
> d [-Wunused-but-set-variable]
>
>      const char *(xml_time[])={xml_rootcheck, "frequency", NULL};
>
>                   ^
>
> rootcheck/win-common.c: In function '__os_winreg_querykey':
>
> rootcheck/win-common.c:212:11: warning: variable 'sub_key_name_b' set but 
> not us
>
> ed [-Wunused-but-set-variable]
>
>      TCHAR sub_key_name_b[MAX_KEY_LENGTH +1];
>
>            ^
>
> C:\Users\ADMINI~1\AppData\Local\Temp\ccFt34en.o:file_op.c:(.text+0x9e6): 
> undefin
>
> ed reference to `_imp__PathFindFileNameA@4'
>
> collect2.exe: error: ld returned 1 exit status
>
> The lua file compilation has fixed the error at the time of creating 
> executable, but failing now with it not finding 
> ossec-agent-eventchannel.exe at line 149 in ossec-installer.nsi.
>
> We also tried out making the package from Linux server, seems like its not 
> able to find out the required mingw gcc compilers on them. Checking going 
> on.
>
> Regards
> Kumar
>
>

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"ossec-list" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to