[asterisk-users] [asterisk-dev] trunk working under windows!

Drew Gibson drew at oanda.com
Tue Nov 20 13:10:48 CST 2007


but ....... why?????


Zoa wrote:
> Cool, i'll help out a bit with the windows port,  i will start right
> away with a new project on asteriskguru making nightly executable builds
> and installers - will post the links in -users when i'm done.
>
> Well done luigi, this will make it a lot easier for a lot of non linux
> guys to make their first steps in the asterisk world
>
> Crossposted to -users.
>
> Zoa
>
> Luigi Rizzo wrote:
>   
>> As a result of the commit below, now trunk can be built and run under
>> Windows/cygwin, including the building of modules.
>>
>> Haven't checked yet the functionality - some modules surely cause
>> ill side effects or deadlocks on exit, so you need to play a bit
>> with modules.conf .
>> If you want to play with a very minimal version the following does something:
>>
>> 	; -- modules.conf
>> 	[modules]
>> 	autoload=no
>> 	load => res_monitor.so
>> 	load => res_features.so
>> 	load => chan_sip.so
>>
>> Unfortunately, loading other modules is a bit critical and depending
>> on the order or the timing you get crashes etc.
>>
>> To build trunk under windows/cygwin you need at least the following pieces:
>>
>> 	bash
>> 	binutils
>> 	curl
>> 	gcc
>> 	libiconv
>> 	minires		(resolver library)
>> 	libdb4.3	(probably db4.2 too)
>>
>> and a bit of patience because the build takes around 15min or more.
>>
>> cheers
>> luigi
>>
>> On Tue, Nov 20, 2007 at 04:12:11PM -0000, SVN commits to the Asterisk project wrote:
>>   
>>     
>>> Author: rizzo
>>> Date: Tue Nov 20 10:12:10 2007
>>> New Revision: 89454
>>>
>>> URL: http://svn.digium.com/view/asterisk?view=rev&rev=89454
>>> Log:
>>> Fix building of modules under cygwin.
>>>
>>> After this commit we can actually load modules under windows,
>>> and we can start debugging more interesting problems related
>>> to the load order and functionality of modules.
>>>
>>>
>>> Modified:
>>>     trunk/Makefile.moddir_rules
>>>     trunk/apps/Makefile
>>>     trunk/channels/Makefile
>>>     trunk/pbx/Makefile
>>>     trunk/res/Makefile
>>>
>>> Modified: trunk/Makefile.moddir_rules
>>> URL: http://svn.digium.com/view/asterisk/trunk/Makefile.moddir_rules?view=diff&rev=89454&r1=89453&r2=89454
>>> ==============================================================================
>>> --- trunk/Makefile.moddir_rules (original)
>>> +++ trunk/Makefile.moddir_rules Tue Nov 20 10:12:10 2007
>>> @@ -66,9 +66,8 @@
>>>  ifneq ($(findstring $(OSARCH), mingw32 cygwin ),)
>>>    # linker options and extra libraries for cygwin
>>>    SOLINK=-Wl,--out-implib=lib$@.a -shared
>>> -  LIBS+=-L../main -lasterisk -L../res
>>> +  LIBS+=-L../main -lasterisk -L../res $($@_LIBS)
>>>    # additional libraries in res/
>>> -  LIBS_RES:= -lres_monitor -lres_adsi -lres_features
>>>  endif
>>>  endif
>>>  
>>>
>>> Modified: trunk/apps/Makefile
>>> URL: http://svn.digium.com/view/asterisk/trunk/apps/Makefile?view=diff&rev=89454&r1=89453&r2=89454
>>> ==============================================================================
>>> --- trunk/apps/Makefile (original)
>>> +++ trunk/apps/Makefile Tue Nov 20 10:12:10 2007
>>> @@ -39,3 +39,9 @@
>>>  all: _all
>>>  
>>>  include $(ASTTOPDIR)/Makefile.moddir_rules
>>> +
>>> +ifneq ($(findstring $(OSARCH), mingw32 cygwin ),)
>>> +  LIBS+= -lres_features.so -lres_ael_share.so -lres_monitor.so -lres_speech.so
>>> +  LIBS+= -lres_smdi.so
>>> +endif
>>> +
>>>
>>> Modified: trunk/channels/Makefile
>>> URL: http://svn.digium.com/view/asterisk/trunk/channels/Makefile?view=diff&rev=89454&r1=89453&r2=89454
>>> ==============================================================================
>>> --- trunk/channels/Makefile (original)
>>> +++ trunk/channels/Makefile Tue Nov 20 10:12:10 2007
>>> @@ -64,6 +64,10 @@
>>>  
>>>  include $(ASTTOPDIR)/Makefile.moddir_rules
>>>  
>>> +ifneq ($(findstring $(OSARCH), mingw32 cygwin ),)
>>> +  LIBS+= -lres_monitor.so -lres_features.so
>>> +endif
>>> +
>>>  clean::
>>>  	rm -f gentone
>>>  	$(MAKE) -C misdn clean
>>>
>>> Modified: trunk/pbx/Makefile
>>> URL: http://svn.digium.com/view/asterisk/trunk/pbx/Makefile?view=diff&rev=89454&r1=89453&r2=89454
>>> ==============================================================================
>>> --- trunk/pbx/Makefile (original)
>>> +++ trunk/pbx/Makefile Tue Nov 20 10:12:10 2007
>>> @@ -25,6 +25,10 @@
>>>  
>>>  include $(ASTTOPDIR)/Makefile.moddir_rules
>>>  
>>> +ifneq ($(findstring $(OSARCH), mingw32 cygwin ),)
>>> +  LIBS+= -lres_ael_share.so -lres_monitor.so
>>> +endif
>>> +
>>>  clean::
>>>  	rm -f ael/*.o
>>>  
>>>
>>> Modified: trunk/res/Makefile
>>> URL: http://svn.digium.com/view/asterisk/trunk/res/Makefile?view=diff&rev=89454&r1=89453&r2=89454
>>> ==============================================================================
>>> --- trunk/res/Makefile (original)
>>> +++ trunk/res/Makefile Tue Nov 20 10:12:10 2007
>>> @@ -25,6 +25,13 @@
>>>  
>>>  include $(ASTTOPDIR)/Makefile.moddir_rules
>>>  
>>> +ifneq ($(findstring $(OSARCH), mingw32 cygwin ),)
>>> +  # order-only dependency: build res_monitor before res_features
>>> +  res_features.so: | res_monitor.so
>>> +  # res_features uses some functions from res_monitor
>>> +  res_features.so_LIBS:= -lres_monitor.so
>>> +endif
>>> +
>>>  ael/ael_lex.o: ael/ael_lex.c ../include/asterisk/ael_structs.h ael/ael.tab.h
>>>  ael/ael_lex.o: ASTCFLAGS+=-I. -Iael 
>>>  
>>>       

-- 

Drew Gibson

Systems Administrator
OANDA Corporation
www.oanda.com




More information about the asterisk-users mailing list