From: Igor Kozhukhov Subject: Re: conflict in public header for values definitions Date: Fri, 3 Jan 2014 23:49:32 +0400 Message-ID: References: <167FDCF3-92DC-4CF9-97F8-A636122FB8B2@gmail.com> <52C704CE.5080003@citrix.com> Mime-Version: 1.0 (Apple Message framework v1283) Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <52C704CE.5080003@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Andrew Cooper Cc: xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org Hi Andrew, it is impossible to do outside public headers, because we have trace.h included to another public readers - for example: xen/public/hvm/hvm_op.h will be better to have committed changes in public headers for next ports without additional changes in sources. is it possible to add '#ifdef __sun' to public headers ? I can try to do it and provide review ? or i need update public headers in illumos tree every time ? -- Best regards, Igor Kozhukhov On Jan 3, 2014, at 10:43 PM, Andrew Cooper wrote: > On 03/01/14 18:38, Igor Kozhukhov wrote: >> Hello All, >> >> I'm working on port xen-4.2 to illumos based platform - DilOS - and have problems with conflicts for: >> >> xen/include/public/trace.h : >> >> struct t_buf {} >> struct t_info {} >> >> I have a questions - can we rename structures to: >> struct t_buf_xen {} >> struct t_info_xen {} >> >> Will it be applicable for Xen sources ? > > You would break the compilation for every other user of trace.h, so no. > > If it conflicts with something locally, you could do something like: > (completely untested) > > #define t_buf t_buf_xen > #include > #undef t_buf > > And use t_buf_xen in your own code. > > ~Andrew >