If you are using Arduino Mega 2560, follow these steps.
[1] How to switch between Arduino Mega and Arduino Uno?
Open GSM.h and comment-decomment the appropriate lines like below
e.g. for Arduino Mega
//#define UNO
#define MEGA
If you use Arduino Uno comment the line in HWSerial.h or decomment if
you are using Arduino Mega
e.g. for Arduino Mega
#define MEGA
Save and compile
[2] How to switch between the old shield (that uses 4 and 5 pins for
SoftwareSerial and the new (that used 2 and 3 pins)?
Open GSM.cpp and comment-decomment the appropriate lines like below
e.g. for the new one
//#define GSM_TXPIN 4
//#define GSM_RXPIN 5
#define GSM_TXPIN 2
#define GSM_RXPIN 3
Save and compile
Connect the RX pin of your sim module to pin 18 of your arduino mega and the TX pin to pin 19 of the arduino mega. This is because the library uses Hardware serial for mega. Connect VIO pin of your sim module to IOREF pin of your arduino mega and the connect the GND of your sim module to GND of your arduino mega. That's all.