site logo  UniAud2

HomePage | Categories |* BLOG *| RecentChanges | RecentlyCommented | Login/Register

NewConfig.cmd


/* */

parse arg sAlsaRoot sAlsaBase sIncFile

say "Using:"
say " Alsa Root "sAlsaRoot
say " Alsa Base "sAlsaBase
say " Inc File  "sIncFile

/* open target file */
if (stream(sIncFile, 'c', 'open write' ) <> '') then
do
	call lineout sIncFile, '################################################################################'
	call lineout sIncFile, '# Generated by 'sAlsaBase'\configure.cmd'
	call lineout sIncFile, '################################################################################'
	call lineout sIncFile, ''
	call lineout sIncFile, '################################################################################'
	call lineout sIncFile, '# ALSA basedirectories'
	call lineout sIncFile, '# Note! These should be absolute paths!'
	call lineout sIncFile, '################################################################################'
	sAlsaBase = directory();
	call lineout sIncFile, 'ALSA_BASE      =' sAlsaBase;
	call lineout sIncFile, 'ALSA_SRC       =' sAlsaBase'\src';
	call lineout sIncFile, 'ALSA_LIB_      =' sAlsaBase'\lib';
	call lineout sIncFile, 'ALSA_BIN_      =' sAlsaBase'\bin';
	call lineout sIncFile, '!ifdef 32BIT'
	call lineout sIncFile, 'ALSA_INCLUDE   =' sAlsaBase'\include';
	call lineout sIncFile, 'ALSA_TOOLS     =' sAlsaBase'\tools';
	call lineout sIncFile, '!else'
	call lineout sIncFile, 'ALSA_INCLUDE   =' sAlsaBase'\OCO\include';
	call lineout sIncFile, 'ALSA_TOOLS     =' sAlsaBase'\OCO\tools';
	call lineout sIncFile, '!endif'
	call lineout sIncFile, ''
	say 'Enter DDK base directory (e.g. c:\ddk\base)';
	sDDKPath = linein();
	call lineout sIncFile, 'DDK_BASE       =' sDDKPath;

	say 'Enter Watcom directory (e.g. c:\watcom)';
	sWatcomPath = linein();
	call lineout sIncFile, 'WATCOM         =' sWatcomPath;

	call lineout sIncFile, '################################################################################'
	call lineout sIncFile, '# Include the right watcom makefile'
	call lineout sIncFile, '################################################################################'
	call lineout sIncFile, '!ifdef 32BIT'
	call lineout sIncFile, '!include 'sAlsaBase'\include\watcom32.mk'
	call lineout sIncFile, '!include 'sAlsaBase'\include\watcom32.mak'
	call lineout sIncFile, '!else'
	call lineout sIncFile, '!include 'sAlsaBase'\OCO\include\watcom16.mk'
	call lineout sIncFile, '!include 'sAlsaBase'\OCO\include\watcom16.mak'
	call lineout sIncFile, '!endif'
	call lineout sIncFile, ''

	call lineout sIncFile, ''

	call stream sIncFile, 'c', 'close';


	call directory(sOldDir);

end
else
do
	say 'oops, failed to open outputfile,' sIncFile;
	exit 1;
end

exit 0;

There are no comments on this page. [Add comment]

Valid XHTML 1.0 Transitional :: Valid CSS :: Powered by Wikka Wakka Wiki 1.1.6.7
Page was generated in 0.2982 seconds