1 #include "vers.h" 2 3 int bar()4bar () 5 { 6 return 3; 7 } 8 9 #pragma weak hide_original_foo 10 11 int hide_original_foo()12hide_original_foo () 13 { 14 return 1 + bar (); 15 } 16 17 #pragma weak hide_old_foo 18 19 int hide_old_foo()20hide_old_foo () 21 { 22 return 10 + bar(); 23 } 24 25 #pragma weak hide_old_foo1 26 27 int hide_old_foo1()28hide_old_foo1 () 29 { 30 return 100 + bar (); 31 } 32 33 #pragma weak hide_new_foo 34 35 int hide_new_foo()36hide_new_foo () 37 { 38 return 1000 + bar (); 39 } 40 41 SYMVER(hide_original_foo, show_foo@); 42 SYMVER(hide_old_foo, show_foo@VERS_1.1); 43 SYMVER(hide_old_foo1, show_foo@VERS_1.2); 44 SYMVER(hide_new_foo, show_foo@@VERS_2.0); 45