- 
                Notifications
    You must be signed in to change notification settings 
- Fork 27
Add DragonFly bootstrap support (ltsmaster) #109
Add DragonFly bootstrap support (ltsmaster) #109
Conversation
| No point reviewing your ltsmaster druntime pulls yet, since you're still updating your upstream pulls. If and when those are merged, I'll port them back to this branch, then you can limit these pulls to changes you had to make to just this older branch. | 
| @joakim-noah Thanks for the heads up. | 
| Created an example CI for DragonFly, reusing most of the CI scripting i used to build the dmd version. | 
| Update to the upstream merged changes and I'll pull. | 
96ba97c    to
    405722d      
    Compare
  
    | 
 | 
| Ready to Merge | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some tweaks and questions.
        
          
                src/core/stdc/math.d
              
                Outdated
          
        
      | /// | ||
| enum int FP_ILOGBNAN = int.max; | ||
| } | ||
| version (DragonFlyBSD) | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Forgot an else here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
        
          
                src/core/stdc/stdio.d
              
                Outdated
          
        
      | { | ||
| import core.sys.posix.sys.types; | ||
| } | ||
| version (DragonFlyBSD) | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
An else would be good here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
        
          
                src/core/stdc/stdio.d
              
                Outdated
          
        
      | int getc(FILE* stream) { return fgetc(stream); } | ||
| /// | ||
| int putc(int c, FILE* stream) { return fputc(c,stream); } | ||
| int putc(int c, FILE* stream) { return fputc(c, stream); } | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see the point of these two spacing tweaks.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reverted
        
          
                src/rt/dmain2.d
              
                Outdated
          
        
      | fldcw fpucw; | ||
| } | ||
| } | ||
| version (DragonFlyBSD) version (D_InlineAsm_X86) | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought you're not supporting 32-bit? Take this out.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Correct 👍
| * Authors: Martin Nowak,Diederik de Groot(port:DragonFlyBSD) | ||
| * Copied: From core/sys/freebsd/sys | ||
| */ | ||
| module core.sys.dragonflybsd.pthread; | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why remove this file if it's there upstream?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can add it back in (but it is not used in the ltsmaster for now.
I would have to change the either the filename or the modulename. Which one do you prefer ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The name doesn't have to match, just leave it alone without a revert. If you want to fix it, fix it upstream.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok...
Note: I did get an error when running the (ninja) unittests (which this file does not even contain), about pthread_np not existing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ninja warning or error? It can spit a warning for a file that's not in the CMake file, not a big deal.
Are you saying this file is used upstream in master but not in this branch? A grep turned up no use in master either.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually an error (if i remember correctly, would have to rerun to check).
Link: dlang#2107
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nope doesn't seem to be used in master yet either (copied over from the freebsd implementation, but does not seem to be required. Maybe we should remove it altogetehr (in retrospect)).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dlang#2107 got merged upstream.
62d08c0    to
    86b75bc      
    Compare
  
            
          
                src/core/stdc/stdio.d
              
                Outdated
          
        
      | int getchar() { return getc(stdin); } | ||
| /// | ||
| int putchar(int c) { return putc(c,stdout); } | ||
| int putchar(int c) { return putc(c, stdout); } | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I mentioned two spacing tweaks, this is the other one I don't see a need for.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
:-)
bed7f9a    to
    7dd054d      
    Compare
  
    | Builds cleanly and all unittests passed | 
| Been busy with other stuff, will get to this this weekend. | 
        
          
                src/core/stdc/stdio.d
              
                Outdated
          
        
      | int getchar() { return getc(stdin); } | ||
| /// | ||
| int putchar(int c) { return putc(c,stdout); } | ||
|  | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Take this out too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done :-)
90e5da3    to
    c4294dc      
    Compare
  
    | @joakim-noah Thanks a lot ! | 
All druntime files except for:
They will be posted in a separate PR
Related PR's:
ldc
dlang: