DBD-DBMaker
view release on metacpan or search on metacpan
Makefile.PL view on Meta::CPAN
$opts{DEFINE} = "-DMSWin32";
$opts{LIBS} = ["$libdir/DMAPI$VERNO.LIB"];
$opts{INC} = "-I$incdir $opts{INC}";
$opts{INC} = "$opts{INC} $Config{incpath}\\mfc" if ($Config{cc} eq 'bcc32');
}
else {
$opts{INC} = "-I. -I$incdir $opts{INC}";
$libname =~ s/^lib//;
$libname =~ s/\.a|\.so&//;
$opts{LIBS} = " -L$libdir -l$libname -lm";
# Because unable to resolve stat()
if ($^O eq "linux") {
$opts{LIBS} = $opts{LIBS}." -lc";
}
}
WriteMakefile(%opts);
local($^W)=0;
print qq{
The DBD::DBMaker tests will use these values for the database connection:
if (fbh->ftype == SQL_C_FILE)
{
char buf[MAX_FILE_NAME_LEN];
struct stat fbuf;
do {
fbh->file_idxno++;
if (fbh->file_ext)
sprintf(fbh->data, "%s%d%s", fbh->file_prefix, fbh->file_idxno,fbh->file_ext);
else
sprintf(fbh->data, "%s%d", fbh->file_prefix, fbh->file_idxno);
} while(!fbh->fgOverwrite && !stat(fbh->data, &fbuf)); /* #008 */
if (dbis->debug >= 2)
fprintf(DBILOGFP,
"\tRebind/BindColToFile: col#%d to file:[%s]\n", i+1, fbh->data);
}
}
}
#endif
return av;
{
Newz(42, fbh->file_prefix, len1+1, UCHAR);
strcpy(fbh->file_prefix, file_prefix);
fbh->file_ext = NULL;
}
sprintf(fbh->data, file_prefix);
if (!fgOverwrite) /* #008 */
{
while (!stat(fbh->data, &fbuf))
{
fbh->file_idxno++;
if (fbh->file_ext)
sprintf(fbh->data, "%s%d%s", fbh->file_prefix, fbh->file_idxno,fbh->file_ext);
else
sprintf(fbh->data, "%s%d", fbh->file_prefix, fbh->file_idxno);
} while(!stat(fbh->data, &fbuf));
}
fbh->fgOverwrite = fgOverwrite; /* #008 */
rc = SQLBindCol(imp_sth->hstmt,
colno,
fbh->ftype,
fbh->data,
fbh->ColDisplaySize,
&fbh->datalen);
( run in 0.534 second using v1.01-cache-2.11-cpan-49f99fa48dc )