Index: LMDZ6/trunk/libf/phylmd/rrtm/lwu.F90
===================================================================
--- LMDZ6/trunk/libf/phylmd/rrtm/lwu.F90	(revision 5084)
+++ LMDZ6/trunk/libf/phylmd/rrtm/lwu.F90	(revision 5252)
@@ -6,5 +6,5 @@
  & PAER , PCCO2, PDP , PPMB, PQOF , PTAVE, PVIEW, PWV,&
  & PABCU &
- & )  
+ & )
 
 !**** *LWU* - LONGWAVE EFFECTIVE ABSORBER AMOUNTS
@@ -71,28 +71,26 @@
 USE YOELW    , ONLY : NSIL     ,NUA      ,NG1      ,NG1P1    ,&
  & ALWT     ,BLWT     ,RO3T     ,RT1      ,TREF     ,&
- & RVGCO2   ,RVGH2O   ,RVGO3  
+ & RVGCO2   ,RVGH2O   ,RVGO3
 !USE YOERDI   , ONLY : RCH4     ,RN2O     ,RCFC11   ,RCFC12
 USE YOERDU   , ONLY : R10E     ,REPSCO   ,REPSCQ
-#ifdef REPROBUS
-USE chem_rep, ONLY: rch42d, rn2o2d, rcfc112d, rcfc122d, ok_rtime2d
+USE lmdz_reprobus_wrappers, ONLY: rch42d, rn2o2d, rcfc112d, rcfc122d, ok_rtime2d
 USE infotrac_phy, ONLY : type_trac
-#endif
-
+USE lmdz_cppkeys_wrapper, ONLY: CPPKEY_REPROBUS
 
 IMPLICIT NONE
 
-INTEGER(KIND=JPIM),INTENT(IN)    :: KLON 
-INTEGER(KIND=JPIM),INTENT(IN)    :: KLEV 
-INTEGER(KIND=JPIM),INTENT(IN)    :: KIDIA 
-INTEGER(KIND=JPIM),INTENT(IN)    :: KFDIA 
-REAL(KIND=JPRB)   ,INTENT(IN)    :: PAER(KLON,6,KLEV) 
-REAL(KIND=JPRB)   ,INTENT(IN)    :: PCCO2 
-REAL(KIND=JPRB)   ,INTENT(IN)    :: PDP(KLON,KLEV) 
-REAL(KIND=JPRB)   ,INTENT(IN)    :: PPMB(KLON,KLEV+1) 
-REAL(KIND=JPRB)   ,INTENT(IN)    :: PQOF(KLON,KLEV) 
-REAL(KIND=JPRB)   ,INTENT(IN)    :: PTAVE(KLON,KLEV) 
-REAL(KIND=JPRB)   ,INTENT(IN)    :: PVIEW(KLON) 
-REAL(KIND=JPRB)   ,INTENT(IN)    :: PWV(KLON,KLEV) 
-REAL(KIND=JPRB)   ,INTENT(OUT)   :: PABCU(KLON,NUA,3*KLEV+1) 
+INTEGER(KIND=JPIM),INTENT(IN)    :: KLON
+INTEGER(KIND=JPIM),INTENT(IN)    :: KLEV
+INTEGER(KIND=JPIM),INTENT(IN)    :: KIDIA
+INTEGER(KIND=JPIM),INTENT(IN)    :: KFDIA
+REAL(KIND=JPRB)   ,INTENT(IN)    :: PAER(KLON,6,KLEV)
+REAL(KIND=JPRB)   ,INTENT(IN)    :: PCCO2
+REAL(KIND=JPRB)   ,INTENT(IN)    :: PDP(KLON,KLEV)
+REAL(KIND=JPRB)   ,INTENT(IN)    :: PPMB(KLON,KLEV+1)
+REAL(KIND=JPRB)   ,INTENT(IN)    :: PQOF(KLON,KLEV)
+REAL(KIND=JPRB)   ,INTENT(IN)    :: PTAVE(KLON,KLEV)
+REAL(KIND=JPRB)   ,INTENT(IN)    :: PVIEW(KLON)
+REAL(KIND=JPRB)   ,INTENT(IN)    :: PWV(KLON,KLEV)
+REAL(KIND=JPRB)   ,INTENT(OUT)   :: PABCU(KLON,NUA,3*KLEV+1)
 
 #include "clesphys.h"
@@ -107,15 +105,15 @@
 REAL(KIND=JPRB) :: ZABLY(KLON,7,3*KLEV+1)  , ZDPM(KLON,3*KLEV)&
  & ,  ZDUC(KLON, 3*KLEV+1)    , ZFACT(KLON)&
- & ,  ZUPM(KLON,3*KLEV)  
+ & ,  ZUPM(KLON,3*KLEV)
 REAL(KIND=JPRB) :: ZPHIO(KLON),ZPSC2(KLON) , ZPSC3(KLON), ZPSH1(KLON)&
  & ,  ZPSH2(KLON),ZPSH3(KLON) , ZPSH4(KLON), ZPSH5(KLON)&
  & ,  ZPSH6(KLON),ZPSIO(KLON) , ZTCON(KLON)&
- & ,  ZPHM6(KLON),ZPSM6(KLON) , ZPHN6(KLON), ZPSN6(KLON)  
+ & ,  ZPHM6(KLON),ZPSM6(KLON) , ZPHN6(KLON), ZPSN6(KLON)
 REAL(KIND=JPRB) :: ZSSIG(KLON,3*KLEV+1)    , ZTAVI(KLON)&
- & ,  ZUAER(KLON,NSIL)        , ZXOZ(KLON) , ZXWV(KLON)  
+ & ,  ZUAER(KLON,NSIL)        , ZXOZ(KLON) , ZXWV(KLON)
 
 INTEGER(KIND=JPIM) :: IAE1, IAE2, IAE3, IC, ICP1, IG1, IJ, IJPN,&
  & IKIP1, IKJ, IKJP, IKJPN, IKJR, IKL, JA, JAE, &
- & JK, JKI, JKK, JL  
+ & JK, JKI, JKK, JL
 
 REAL(KIND=JPRB) :: ZALUP, ZCAC8, ZCAH1, ZCAH2, ZCAH3, ZCAH4,&
@@ -123,5 +121,5 @@
  & ZCBH4, ZCBH5, ZCBH6, ZDIFF, ZDPMG, ZDPMP0, &
  & ZFPPW, ZTX, ZTX2, ZU6, ZUP, ZUPMCO2, ZUPMG, &
- & ZUPMH2O, ZUPMO3, ZZABLY  
+ & ZUPMH2O, ZUPMO3, ZZABLY
 REAL(KIND=JPRB) :: ZHOOK_HANDLE
 
@@ -153,5 +151,5 @@
     DO JL = KIDIA,KFDIA
       ZSSIG(JL,IKJ)= (ZSSIG(JL,IKJR) + ZSSIG(JL,IKJP)) * 0.5_JPRB &
-       & + RT1(IG1) * (ZSSIG(JL,IKJP) - ZSSIG(JL,IKJR)) * 0.5_JPRB  
+       & + RT1(IG1) * (ZSSIG(JL,IKJP) - ZSSIG(JL,IKJR)) * 0.5_JPRB
     ENDDO
   ENDDO
@@ -237,5 +235,5 @@
        & +RAER(JAE,3)*PAER(JL,3,JK)+RAER(JAE,4)*PAER(JL,4,JK)&
        & +RAER(JAE,5)*PAER(JL,5,JK)+RAER(JAE,6)*PAER(JL,6,JK))&
-       & /(ZDUC(JL,IAE1)+ZDUC(JL,IAE2)+ZDUC(JL,IAE3))  
+       & /(ZDUC(JL,IAE1)+ZDUC(JL,IAE2)+ZDUC(JL,IAE3))
     ENDDO
   ENDDO
@@ -297,8 +295,8 @@
     DO JL = KIDIA,KFDIA
       ZDIFF = PVIEW(JL)
-!- H2O continuum      
+!- H2O continuum
       PABCU(JL,10,IC)=PABCU(JL,10,ICP1)+ ZABLY(JL,4,IC)          *ZDIFF
       PABCU(JL,11,IC)=PABCU(JL,11,ICP1)+ ZABLY(JL,5,IC)*ZTCON(JL)*ZDIFF
-!- O3      
+!- O3
       PABCU(JL,12,IC)=PABCU(JL,12,ICP1)+ ZABLY(JL,6,IC)*ZPHIO(JL)*ZDIFF
       PABCU(JL,13,IC)=PABCU(JL,13,ICP1)+ ZABLY(JL,7,IC)*ZPSIO(JL)*ZDIFF
@@ -320,6 +318,5 @@
       PABCU(JL,17,IC)=PABCU(JL,17,ICP1)+ ZUAER(JL,4)    *ZDUC(JL,IC)*ZDIFF
       PABCU(JL,18,IC)=PABCU(JL,18,ICP1)+ ZUAER(JL,5)    *ZDUC(JL,IC)*ZDIFF
-#ifdef REPROBUS
-        IF (type_trac=='repr'.and. ok_rtime2d) THEN
+        IF (CPPKEY_REPROBUS .AND. type_trac=='repr'.AND. ok_rtime2d) THEN
 !- CH4
       PABCU(JL,19,IC)=PABCU(JL,19,ICP1)&
@@ -340,24 +337,21 @@
 
          ELSE
-#endif
 !- CH4
       PABCU(JL,19,IC)=PABCU(JL,19,ICP1)&
-       & + ZABLY(JL,2,IC)*RCH4/PCCO2*ZPHM6(JL)*ZDIFF  
+       & + ZABLY(JL,2,IC)*RCH4/PCCO2*ZPHM6(JL)*ZDIFF
       PABCU(JL,20,IC)=PABCU(JL,20,ICP1)&
-       & + ZABLY(JL,3,IC)*RCH4/PCCO2*ZPSM6(JL)*ZDIFF  
+       & + ZABLY(JL,3,IC)*RCH4/PCCO2*ZPSM6(JL)*ZDIFF
 !- N2O
       PABCU(JL,21,IC)=PABCU(JL,21,ICP1)&
-       & + ZABLY(JL,2,IC)*RN2O/PCCO2*ZPHN6(JL)*ZDIFF  
+       & + ZABLY(JL,2,IC)*RN2O/PCCO2*ZPHN6(JL)*ZDIFF
       PABCU(JL,22,IC)=PABCU(JL,22,ICP1)&
-       & + ZABLY(JL,3,IC)*RN2O/PCCO2*ZPSN6(JL)*ZDIFF  
+       & + ZABLY(JL,3,IC)*RN2O/PCCO2*ZPSN6(JL)*ZDIFF
 !- CFC11
       PABCU(JL,23,IC)=PABCU(JL,23,ICP1)&
-       & + ZABLY(JL,2,IC)*RCFC11/PCCO2        *ZDIFF  
+       & + ZABLY(JL,2,IC)*RCFC11/PCCO2        *ZDIFF
 !- CFC12
       PABCU(JL,24,IC)=PABCU(JL,24,ICP1)&
-       & + ZABLY(JL,2,IC)*RCFC12/PCCO2        *ZDIFF  
-#ifdef REPROBUS
+       & + ZABLY(JL,2,IC)*RCFC12/PCCO2        *ZDIFF
         END IF
-#endif
     ENDDO
   ENDDO
