[Bug 40269] New: #ifdef isn't recognized in GLSL preprocessor

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Sun Aug 21 06:38:40 PDT 2011


https://bugs.freedesktop.org/show_bug.cgi?id=40269

           Summary: #ifdef isn't recognized in GLSL preprocessor
           Product: xorg
           Version: unspecified
          Platform: x86 (IA32)
        OS/Version: Linux (All)
            Status: NEW
          Severity: major
          Priority: medium
         Component: Driver/Radeon
        AssignedTo: xorg-driver-ati at lists.x.org
        ReportedBy: snake5creator at gmail.com
         QAContact: xorg-team at lists.x.org


When I compile a shader that contains #ifdef, the compiler seems to be
misinterpreting it as #if - I get two errors - unexpected $end and unterminated
#if (which points to the line that contains #ifdef.

It's possible to work around the bug by using #if defined( .. ) instead of
#ifdef .., however this is a very useful directive that is expected to work.

The full construct I had there was like this:

#ifdef VSHADER
..code
#elif defined( PSHADER )
..code
#endif

Works great on fglrx and Catalyst Win32 drivers.

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the xorg-driver-ati mailing list