I use Tomcat 6.0.20 and JDK 1.6.0.13.
How can I load libraries from sub-folders of %TOMCAT_HOME%/lib/ without taking the .jars out of sub-folders and putting them straight into %TOMCAT_HOME%/lib/?
The reason I want to do this, is because many apps are going to be sharing lots of libraries.
So, for the sakes of organization I want to store them into folders as such:
%TOMCAT_HOME%/lib/novell/*.jar
%TOMCAT_HOME%/lib/mail/*.jar
%TOMCAT_HOME%/lib/upload/*.jar
etc.
How would I go about this? And please provide an example.
Do I use setclasspath.bat, catalina.properties or something completely different?
Thanks in advance.
Define those paths in shared.loader property of /conf/catalina.properties file.
E.g.
shared.loader = ${catalina.home}/lib/novell/*.jar, ${catalina.home}/lib/mail/*.jar, ${catalina.home}/lib/upload/*.jar
[Edit] optionally you can also use the common.loader property for this. See what has your preference.
Related
I have a WPF application built on top of PRISM.
When i tries to list module before loaded modules when find modules,I use dicitonary find module,but i dont look any module in modulecategory.
Any suggestions on how I can do this?
Thanks in advance
The easiest thing to do is to name your module assemblies in a special way, like MySomething.module.dll and then look for these when putting together the module catalog. There once was a module catalog implementation around on codeplex that allowed to pass a search pattern including subfolders... link
Basically my task is nearly a copy of [1], the only thing i want to achieve is, to put the generated codestyle.xml into a plugin to share this.
So i have my codeStyle.xml in my resources folder under codestyles like this:
ressources/codestyles/codeStyle.xml
The reason behind this is, that we started using an internal plugin repo for intellij, and in that way it is easier for us to distribute the settings internally.
Maybe my approach is not the best one, but i am glad for any input regarding this ticket.
[1] How can I create custom Live Templates with an Intellij plugin
Thank you
Simon
it looks like this is sadly not possible, as a solution we swapped to project based settings
We have multiple people working on php projects. Is there a way to have netbeans 7.2 call the folder with all the metadata something other than nbproject?
I want all projects I create from existing sources to have something like qwertymk and whenever I create projects or try to load them it will always go to folder named qwertymk instead of nbproject.
Obviously the folder name is hardcoded in several places within Netbeans, but you have options to work around that by placing the nbproject somewhere else, e.g. into a subfoler where it does not get on your nerves. Look at this old thread, specifically at this post. I cannot magically change hardcoded Netbeans stuff for you, but I would be happy if the solution I am pointing you to would satisfy your needs and answer the question.
I am trying to clean up some of my projects, and one of the things that are puzzling me is how to deal with header files in static libraries that I have added as "project dependencies" (by adding the project file itself). The basic structure is like this:
MyProject.xcodeproj
Contrib
thirdPartyLibrary.xcodeproj
Classes
MyClass1.h
MyClass1.m
...
Now, the dependencies are all set up and built correctly, but how can I specify the public headers for "thirdPartyLibrary.xcodeproj" so that they are on the search path when building MyProject.xcodeproj. Right now, I have hard-coded the include directory in the thirdPartyLibrary.xcodeproj, but obviously this is clumsy and non-portable. I assume that, since the headers are public and already built to some temporary location in ~/Library (where the .a file goes as well), there is a neat way to reference this directory. Only.. how? An hour of Googling turned up blank, so any help is greatly appreciated!
If I understand correctly, I believe you want to add a path containing $(BUILT_PRODUCTS_DIR) to the HEADER_SEARCH_PATHS in your projects build settings.
As an example, I took an existing iOS project which contains a static library, which is included just in the way you describe, and set the libraries header files to public. I also noted that the PUBLIC_HEADERS_FOLDER_PATH for this project was set to "/usr/local/include" and these files are copied to $(BUILT_PRODUCTS_DIR)/usr/local/include when the parent project builds the dependent project. So, the solution was to add $(BUILT_PRODUCTS_DIR)/usr/local/include to HEADER_SEARCH_PATHS in my project's build settings.
HEADER_SEARCH_PATHS = $(BUILT_PRODUCTS_DIR)/usr/local/include
Your situation may be slightly different but the exact path your looking for can probably be found in Xcode's build settings. Also you may find it helpful to add a Run Script build phase to your target and note the values of various settings at build time with something like:
echo "BUILT_PRODUCTS_DIR " $BUILT_PRODUCTS_DIR
echo "HEADER_SEARCH_PATHS " $HEADER_SEARCH_PATHS
echo "PUBLIC_HEADERS_FOLDER_PATH " $PUBLIC_HEADERS_FOLDER_PATH
.
.
.
etc.
I think that your solution is sufficient and a generally accepted one. One alternative would be to have all header files located under an umbrella directory that can describe the interface to using the depended-on libraries and put that in your include path. I see this as being similar to /usr/include. Another alternative that I have never personally tried, but I think would work would be to create references to all the headers of thirdPartyLibrary from MyProject so that they appear to be members of the MyProject. You would do this by dragging them from some location into MyProject, and then deselecting the checkbox that says to copy them into the project's top level directory. From one perspective this seems feasible to me because it is as if you are explicitly declaring that your project depends on those specific classes, but it is not directly responsible for compiling them.
One of the things to be wary of when addressing this issue is depending on implementation-specific details of Xcode for locating libraries automatically. Doing so may seem innocuous in the meantime but the workflows that it uses to build projects are subject to change with updates and could potentially break your project in subtle and confusing ways. If they are not well-defined in some documentation, I would take any effect as being coincidental and not worth leveraging in your project when you can enforce the desired behavior by some other means. In the end, you may have to define a convention that you follow or find one that you adopt from someone else. By doing so, you can rest assured that if your solution is documented and reproducible, any developer (including yourself in the future) can pick it up and proceed without tripping over it, and that it will stand the testament of time.
The way we do it is to go into build target settings for the main project and add:
User Header Search Path = "Contrib"
and check that it searches recursively. We don't see performance problems with searching recursively even with many (10-15 in some projects) dependencies.
Could you advise me what is the difference between Debug and Release folders?
Thanks
Furqan
The debug folder usually contains your program compiled for debugging, that is there is additional information included, such as variable names, that help you find errors in the program.
The release folder contains your program without any of that. Just what is necessary for the program to run.
Just to be clear, the name of the folders in your question are virtually unlimited (not simply limited to debug and release). Right click on your solution and select Configuration Manager and you can add as many configurations as you would like. The name of the configuration is the name of the folder.
As Joshua wrote, usually, people use their debug config to include things like the .pdb file (which includes debugging symbols needed to get line numbers from errors, etc.). Release is normally cleaner. However, you can easily setup folders for x86 vs. x64 vs. any cpu.
If you have a solution with 10 different projects (not uncommon if you work on something of decent size) you might want to build certain projects together and others together. In this case, you should create additional configurations to support this so you can build a group simply by changing your active configuration.
In the end, the folders you mentioned contain whatever you specify in the configuration manager that they should contain.