~ubuntu-branches/ubuntu/maverick/openssl/maverick

« back to all changes in this revision

Viewing changes to crypto/dso/dso_win32.c

  • Committer: Bazaar Package Importer
  • Author(s): Kurt Roeckx
  • Date: 2006-05-15 16:00:58 UTC
  • mfrom: (1.1.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20060515160058-pn9osix02x46r0iy
Tags: 0.9.8b-2
* Don't call gcc with -mcpu on i386, we already use -march, so no need for
  -mtune either.
* Always make all directories when building something:
  - The engines directory didn't get build for the static directory, so
    where missing in libcrypo.a
  - The apps directory didn't always get build, so we didn't have an openssl
    and a small part of the regression tests failed.
* Make the package fail to build if the regression tests fail.

Show diffs side-by-side

added added

removed removed

Lines of Context:
307
307
        struct file_st *result = NULL;
308
308
        enum { IN_NODE, IN_DEVICE, IN_FILE } position;
309
309
        const char *start = filename;
 
310
        char last;
310
311
 
311
312
        if (!filename)
312
313
                {
337
338
 
338
339
        do
339
340
                {
340
 
                switch(filename[0])
 
341
                last = filename[0];
 
342
                switch(last)
341
343
                        {
342
344
                case ':':
343
345
                        if(position != IN_DEVICE)
362
364
                                start = ++filename;
363
365
                                result->dir = start;
364
366
                                }
 
367
                        else if(position == IN_DEVICE)
 
368
                                {
 
369
                                position = IN_FILE;
 
370
                                filename++;
 
371
                                result->dir = start;
 
372
                                result->dirlen = filename - start;
 
373
                                start = filename;
 
374
                                }
365
375
                        else
366
376
                                {
367
377
                                filename++;
368
378
                                result->dirlen += filename - start;
 
379
                                start = filename;
369
380
                                }
370
381
                        break;
371
382
                case '\0':
379
390
                                        {
380
391
                                        if (assume_last_is_dir)
381
392
                                                {
382
 
                                                result->devicelen += filename - start;
 
393
                                                if (position == IN_DEVICE)
 
394
                                                        {
 
395
                                                        result->dir = start;
 
396
                                                        result->dirlen = 0;
 
397
                                                        }
 
398
                                                result->dirlen +=
 
399
                                                        filename - start;
383
400
                                                }
384
401
                                        else
385
402
                                                {
386
403
                                                result->file = start;
387
 
                                                result->filelen = filename - start;
 
404
                                                result->filelen =
 
405
                                                        filename - start;
388
406
                                                }
389
407
                                        }
390
408
                                }
394
412
                        break;
395
413
                        }
396
414
                }
397
 
        while(*filename);
 
415
        while(last);
398
416
 
399
417
        if(!result->nodelen) result->node = NULL;
400
418
        if(!result->devicelen) result->device = NULL;
482
500
                result[offset] = '\\'; offset++;
483
501
                start = end + 1;
484
502
                }
 
503
#if 0 /* Not needed, since the directory converter above already appeneded
 
504
         a backslash */
485
505
        if(file_split->predir && (file_split->dir || file_split->file))
486
506
                {
487
507
                result[offset] = '\\'; offset++;
488
508
                }
 
509
#endif
489
510
        start = file_split->dir;
490
511
        while(file_split->dirlen > (start - file_split->dir))
491
512
                {
500
521
                result[offset] = '\\'; offset++;
501
522
                start = end + 1;
502
523
                }
 
524
#if 0 /* Not needed, since the directory converter above already appeneded
 
525
         a backslash */
503
526
        if(file_split->dir && file_split->file)
504
527
                {
505
528
                result[offset] = '\\'; offset++;
506
529
                }
 
530
#endif
507
531
        strncpy(&result[offset], file_split->file,
508
532
                file_split->filelen); offset += file_split->filelen;
509
533
        result[offset] = '\0';
546
570
                }
547
571
        else
548
572
                {
549
 
                filespec1_split = win32_splitter(dso, filespec1, 1);
 
573
                filespec1_split = win32_splitter(dso, filespec1, 0);
550
574
                if (!filespec1_split)
551
575
                        {
552
576
                        DSOerr(DSO_F_WIN32_MERGER,
553
577
                                ERR_R_MALLOC_FAILURE);
554
578
                        return(NULL);
555
579
                        }
556
 
                filespec2_split = win32_splitter(dso, filespec2, 0);
557
 
                if (!filespec1_split)
 
580
                filespec2_split = win32_splitter(dso, filespec2, 1);
 
581
                if (!filespec2_split)
558
582
                        {
559
583
                        DSOerr(DSO_F_WIN32_MERGER,
560
584
                                ERR_R_MALLOC_FAILURE);