cancel
Showing results for 
Search instead for 
Did you mean: 

Build failed: package com.sap.security.api does not exist

jpenninkhof
Product and Topic Expert
Product and Topic Expert
0 Kudos

I have included package com.sap.security.api in my Web Dynpro project and during design/develop-time everything works fine. There are no exclamation marks etc visible. However, when I try to build it the build fails.

I have added com.sap.security.api by:

1. Open the properties window of my project

2. Select 'Java Build Path' - 'Libraries'

3. Click 'Add Variable', selecting 'WD_RUNTIME', click 'Extend'

4. Select 'com.sap.security_2.0.0' - 'lib' - 'com.sap.security.api.jar'

Details of the error message are as follows:

      [echo] Starting Java compiler
      [echo] Settings:
      [echo]   debug:       on
      [echo]   optimize:    off
      [echo]   deprecation: default
      [echo]   verbose:     default
      [echo]   encoding:    UTF8
      [echo]   source:      default
      [echo]   target:      default
      [echo]   source paths: 
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\phoqus.nl\is-h\pa\_comp\src\packages
      [echo]     C:\Documents and Settings\developer\.dtc\3\t\04C296E8636C2FD19673C57C879886E6\gen_ddic\datatypes
      [echo]     C:\Documents and Settings\developer\.dtc\3\t\04C296E8636C2FD19673C57C879886E6\gen_wdp\packages
      [echo]   class path:
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\cmi\_comp\gen\default\public\default\lib\java\_cmi_api.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\ddic\ddicruntime\_comp\gen\default\public\default\lib\java\SapDictionaryTypeServices.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\ddic\ddicruntime\_comp\gen\default\public\default\lib\java\SapDictionaryTypesRuntime.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\ddic\metamodel\content\_comp\gen\default\public\default\lib\java\SapMetamodelDictionaryContent.zip
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_admin.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_basesrvc.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_clientserver.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_model_dynamicrfc.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_modelimpl.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_pdfobject.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_portal.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_progmodel.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_runtime_designtime_coupling.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_runtime_designtime_coupling_api.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_runtime_repository.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_runtime_repository_pmr.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wd\webdynpro\_comp\gen\default\public\default\lib\java\_webdynpro_services.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\logging\_comp\gen\default\public\default\lib\java\logging.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\logging\_comp\gen\default\public\default\lib\java\logging.perf.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\tc\wdp\metamodel\content\_comp\gen\default\public\default\lib\java\SapMetamodelWebdynproContent.zip
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\com.sap.aii.proxy.framework\_comp\gen\default\public\default\lib\java\aii_proxy_rt.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\com.sap.aii.util.misc\_comp\gen\default\public\default\lib\java\aii_util_misc.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\com.sap.exception\_comp\gen\default\public\default\lib\java\exception.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\sap.com\com.sap.mw.jco\_comp\gen\default\public\default\lib\java\jrfc.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\phoqus.nl\is-h\pa-model\_comp\gen\default\public\PAModel\lib\java\phoqus.nl~is-h~pa-model~PAModel.jar
      [echo]     C:\Documents and Settings\developer\.dtc\3\DCs\phoqus.nl\is-h\pa-util\_comp\gen\default\public\UtilsPP\lib\java\phoqus.nl~is-h~pa-util~UtilsPP.jar
      [echo]   output dir:  C:\Documents and Settings\developer\.dtc\3\t\04C296E8636C2FD19673C57C879886E6\classes
     [javac] Compiling 28 source files to C:\Documents and Settings\developer\.dtc\3\t\04C296E8636C2FD19673C57C879886E6\classes
     [javac] ERROR: C:\Documents and Settings\developer\.dtc\3\t\04C296E8636C2FD19673C57C879886E6\gen_wdp\packages\nl\phoqus\pataut\Main.java:20: package com.sap.security.api does not exist

Obviously the com.sap.security.api is not included in the class path, as it isn't listed in de trace. But shouldn't the Webdynpro IDE put the com.sap.security.api in the class path automatically when I add it to my build path? And what is the best way to add this jar to my class path then, so that I can succesfully build my DC?

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

When you are using Dc's its better to use the DC dependency

Add the the following DC dependency to your project

ENGINEAPI->security_api

Regards

Ayyapparaj

Answers (2)

Answers (2)

jpenninkhof
Product and Topic Expert
Product and Topic Expert
0 Kudos

Thanks for your help. When I was browsing SDN, in almost every post it was mentioned that is should be added to the Java Build Path. I guess that got me on the wrong foot... Points to both of you!

Former Member
0 Kudos

Hi,

Dont trust the answers blindly, they are not always correct or the right way to do it

Regards

Ayyapparaj

Former Member
0 Kudos

Of course there is no runtime reference, when you just add some jars to your project classpath.

Never edit the project build path when working with DCs. You manage this by using DC Usages (and sometimes some other settings for actual runtime references).

How this is done depends on your release and is well documented on help.sap.com or in your Studio help.

Cheers, Karsten