Subj : Re: A really stupid Question - how to build a library To : borland.public.cpp.borlandcpp From : D Kat Date : Wed Oct 06 2004 05:15 pm "Ed Mulroy [TeamB]" wrote in message news:41631665@newsgroups.borland.com... > From the command line > > tlib /C libname.lib -+file1.obj -+file2.obj +-file3.obj {etc} > > where -+ means replace so when you first create the library it will give > you a warning that the files did not already exist in the library. > > From a response file > > tlib /C libname.lib @respfile.txt > > where respfile.txt contains > > -+file1.obj & > -+file2.obj & > -+file3.obj > > Note that the & line continuation character must be preceeded by a space. > > From the IDE I do not remember the location of the library selection, but > could not tell you even if I did because it varies among versions and you > have not mentioned what version you are using. Look at the target types > that you can create. Use the help. > > . Ed > >> D Kat wrote in message >> news:4162f33b$1@newsgroups.borland.com... >> >> Nope. I don't want to do this in builder. This is for a DOS program. I >> meant Borland not Builder. Sorry. OK, this all looks familiar.... Thank you. Now on to a question about ..... what can and cannot go in the lib file.. Where to begin. The programs written by the students opens a binary file that is then output to a D/A. I would like the Library to have in it the function that initializes the board, resets the computer vectors after the board is done with, etc. Ideally I would like to have the interrupt function in the library itself but this is going to be using the file being opened by the program which the student writes that uses the library... In addition I'm using double buffering so using a pointer in a simple sense won't work... Should I declare the double array FileBuffer that is used to be an external in the Library? I'm currently using a pointer that is assigned the active buffer each time an end of buffer is reached..... Then of course there are the counters (ticks for each call to the interrupt) and other variables that are needed by the main program. I seem to be going around in circles on this. I think I have just convinced myself that this routine cannot go into the library. Thoughts or advice would be appreciated. //========================================================================== //interrupt routine with play and button catch //======================================================================= void __interrupt i_service(...)// Daq801 interrupt service routine { disable(); // disable the interrupts int button,i; // button iterator unsigned char PA_buttons,PC_buttons; // temp holding register for current buttons inp(I_STATUS); // read the interrupt status register and clear interrupt for (i=0;i fill buffer } outpw(DA_0,*da_point); outpw(DA_1,*da_point++); } if (BUTTONFLAG) { PA_buttons=(inp(PA)); // freeze data if (PA_buttons != MASK)// process following path only if one or more { // buttons were pressed! for (button=0;button