# Package export does not work like I expect

**URL:** <https://verificationacademy.com/forums/t/package-export-does-not-work-like-i-expect/31199>\
**Category:** SystemVerilog\
**Tags:** SystemVerilog\
**Created:** [November 6, 2015, 8:05pm UTC](https://verificationacademy.com/forums/t/package-export-does-not-work-like-i-expect/31199 "2015-11-06T20:05:03Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![dnguyen82us](https://verificationacademy.com/forums/letter_avatar_proxy/v4/letter/d/ce73a5/32.png) [@dnguyen82us](https://verificationacademy.com/forums/u/dnguyen82us)\
**Post date:** [November 10, 2016, 7:55pm UTC](https://verificationacademy.com/forums/t/package-export-does-not-work-like-i-expect/31199/7 "2016-11-10T19:55:14Z")

</div>

I follow this coding style putting all the files in a pkg.sv file but there is this compilation error. Not sure what caused this.

Error-[SE] Syntax error  
Following verilog source has syntax error :  
“project/verif/vkits/glbk/lbk\_pkg.sv”, 66: token is ‘endpackage’  
endpackage:lbk\_pkg  
^  
System verilog keyword ‘endpackage’ is not expected to be used in this  
context.

1 error

The file content is below.  
package lbk\_pkg;

//---------------------------------------------------------------------  
// Group: Imports  
import uvm\_pkg::\*;

// Forward class declarations to work around compile errors

typedef class config\_vseq\_c;  
typedef class reg\_comp\_rst\_vseq\_c;  
typedef class lbk\_sec\_reg\_walk\_seq\_c;  
typedef class lbk\_non\_sec\_reg\_walk\_seq\_c;  
typedef class lbk\_reg\_walk\_seq\_c;  
typedef class no\_op\_seq\_c;  
typedef class csr\_background\_read\_vseq\_c;  
typedef class env\_c;  
typedef class lbk\_p2x\_cfg\_c;  
typedef class lbk\_x2p\_cfg\_c;

//---------------------------------------------------------------------  
// Group: Includes  
// (`include package member files here, alphabetically.) `include “cvm\_pcc\_defs.vh”

`include "lbk_ecam_cfg_function.sv" `include “lbk\_types.sv”  
`include "lbk_cfg.sv" `include “lbk\_pkt\_cfg.sv”  
`include "lbk_pkt.sv" `include “lbk\_trans\_sb.sv”  
`include "lbk_chan_cred_sb.sv" `include “lbk\_perf\_sb.sv”  
`include "lbk_ebp_sb.sv" `include “lbk\_exer\_seq\_cfg.sv”  
`include "lbk_test_vseq_lib.sv" `include “lbk\_vsqr.sv”  
`include "lbk_config_vseq_lib.sv" `include “lbk\_env.sv”  
`include "lbk_p2x_cfg.sv" `include “lbk\_x2p\_cfg.sv”

endpackage : lbk\_pkg

---

_[View the full topic](https://verificationacademy.com/forums/t/package-export-does-not-work-like-i-expect/31199)._
