The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > OS Specific Forums > Linux
Google UNIX.COM



View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #6 (permalink)  
Old 05-12-2008
borzh62 borzh62 is offline
Registered User
 

Join Date: May 2008
Posts: 6
wildcards

Its okay when we're talking about small program, but we're talking about lines and lines of code. If you would see something ugly as:

#ifdef MOTOROLA_Z6
// 3000 lines of code
#else
#ifdef SONYERICSSON_K790
//other 3000 lines of code
#else
//other 3000 lines of code
#endif
#endif

i'm sure you would understand this. It's better sometimes to "fork" a new file that use one file for 10-20 phones. But we are out of subject . I just wanted to know if there is a way to copy only necessarily files using make.
I have GNU make, and it understand wildcards: but appearently when using rule:
tmp/*.c: master_source/*.c platform_source/*.c
it only looks for files with same name in both master_source and platform_source. Is there some way to workaround this feature?, so it can copy all needed files not only ones with same name.
Reply With Quote