VirtualBox

Changeset 58691 in vbox for trunk


Ignore:
Timestamp:
Nov 15, 2015 9:52:37 PM (9 years ago)
Author:
vboxsync
Message:

iprt/asmdefs.mac: NASM defines PASS=0 or =3 to indicate that we're only-preprocessing or generating dependencies, so we don't actually need kBuild to define KBUILD_GENERATING_MAKEFILE_DEPENDENCIES for us.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/include/iprt/asmdefs.mac

    r58608 r58691  
    895895
    896896;
     897; NASM sets __PASS__ to 0 in preprocess-only mode, and to 3 when only generating dependencies.
     898; YASM has no such setting which is why we must rely on kBuild to tell us what we're doing.
     899; For simplicity, we'll set the kBuild macro when using NASM.
     900;
     901%ifndef KBUILD_GENERATING_MAKEFILE_DEPENDENCIES
     902 %ifdef __NASM__
     903  %if __PASS__ == 0 || __PASS__ == 3
     904   %define KBUILD_GENERATING_MAKEFILE_DEPENDENCIES
     905  %endif
     906 %endif
     907%endif
     908
     909
     910;
    897911; Some simple compile time assertions.
    898912;
    899 ; Note! Requires new kBuild to work.
     913; Note! Requires new kBuild to work with YASM (see above).
    900914;
    901915
    902916;;
    903917; Structure size assertion macro.
    904 %ifdef __NASM__
    905  %define AssertCompileSize(a_Type, a_Size) ; Not possible?
    906 %else
    907  %define AssertCompileSize(a_Type, a_Size) AssertCompileSizeML a_Type, a_Size
    908 %endif
     918%define AssertCompileSize(a_Type, a_Size) AssertCompileSizeML a_Type, a_Size
    909919%macro AssertCompileSizeML 2
    910920 %ifndef KBUILD_GENERATING_MAKEFILE_DEPENDENCIES
     
    919929;;
    920930; Structure memember offset assertion macro.
    921 %ifdef __NASM__
    922  %define AssertCompileMemberOffset(a_Type, a_Member, a_off) ; Not possible?
    923 %else
    924  %define AssertCompileMemberOffset(a_Type, a_Member, a_off) AssertCompileMemberOffsetML a_Type, a_Member, a_off
    925 %endif
     931%define AssertCompileMemberOffset(a_Type, a_Member, a_off) AssertCompileMemberOffsetML a_Type, a_Member, a_off
    926932%macro AssertCompileMemberOffsetML 3
    927933 %ifndef KBUILD_GENERATING_MAKEFILE_DEPENDENCIES
     
    935941
    936942%endif
     943
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette