INSTALLING OPENLOGOS UNDER SLACKWARE LINUX Instructions for installing Openlogos under Slackware Linux are given below. This procedure was performed under Slackware Linux 13.0 and 12.2; differences between the two are noted. Lists of the files installed by this procedure may be found below. The "openlogos" script runs under either 12.2 or 13.0. However some processors, in particular LogosGateway, do not run under 13.0. Under 12.2, LogosGateway runs and LogosTransCenter creates a job. The attempt to exeucte it by invoking "logos_batch" fails, however. --- 1. OPENLOGOS FILES openlogos-1.0.3.tar.gz library openlogos-1.0.3-for-gcc-4.3.patch patches to eliminate compile errors (Openlogos user's group posting, 11/05/09) OpenLogosTools-1.0.2.zip tools pg_esense.dump database sql dump postgres8.4_patch.tar.gz database patch --- 2. LIBRARY PREREQUISITES postgresql-8.4.2.tar.bz2 PostgreSQL unixODBC-2.2.14-p2.tar.gz ODBC psqlodbc-08.04.0200.tar.gz PostgreSQL driver for ODBC --- 3. TOOLS PREREQUISITES apache-ant-1.8.0-bin.tar.gz java builder --- 4. INSTALLING LIBRARY PREREQUISITES These prerequisites are installed as usual, namely with the following commands: tar -xzf PKG.tar.gz (or tar -xjf PKG.tar.bz2) cd PKG ./configure make su make install exit unixODBC-2.2.14-p2 compiles under Linux 12.2, but not linux 13.0. The command "make" aborts with a message that the header file is incompatible with the MOC file. The files can be compiled under Linux 12.2 and installed manually (don't forget to run "ldconfig"). Alternatively, the Slackware binary package "unixodbc-2.2.14-i486-1gds.tgz" can be downloaded from "http://setirov-bg.net/slackpack". This installs under "/usr"; extracting it and installing manually would avoid any changes to the remaining instructions. Some processors (for example odbctest) don't run if the 12.2 version of unixODBC-2.2.14-p2 is used under 13.0. Before issuing "./configure" for psqlodbc-08.04.0200, issue "export LD_LIBRARY_PATH=/usr/local/pgsql/lib" Use the configure command "./configure --with-libpq=/usr/local/pgsql" For unixODBC-2.2.14-p2 and psqlodbc-08.04.0200, the documentation is not installed by "make install"; it can be found in the "doc" subdirectory of the directory created by extracting, and installed manually if desired. --- 5. CONFIGURING POSTGRESQL To configurate postgresql, issue the following: su adduser postgres all defaults; (weak) password xxx mkdir /usr/local/pgsql/data chown postgres /usr/local/pgsql/data exit su - postgres /usr/local/pgsql/bin/initdb --locale=C -D /usr/local/pgsql/data exit A password was specified, since a blank password doesn't work with some processors. --- 6. INSTALLING OPENLOGOS LIBRARY openlogos-1.0.3 is installed as usual, except under 13.0, after extracting openlogos-1.0.3.tar.gz but before descending into the extracted directory, issue "patch -p0 help > quit --- 9. RUNNING OPENLOGOS WITHOUT TOOLS There is a script "openlogos" for running the library from a console. The documentation on the use of "LGS_ROOT" is confusing. The library is installed below "/usr/local" by default, and "LGS_ROOT" is not used. The "openlogos" script sets "LGS_ROOT" to an internal value, so the setting in the invoking shell is ignored. For the tools, the installation uses "LGS_ROOT", so the tools are installed below it (/usr/local/logos in the example below). If necessary: start postgres export LD_LIBRARY_PATH=/usr/local/pgsql/lib create a working directory DIR. cp openlogos-1.0.3/apitest_settings.txt DIR cd DIR using an editor, create a file of German text named "apitest.input". openlogos apitest_settings.txt . ./apitest.log The output includes messages which can be ignored, such as "rm: cannot remove `/tmp/openlogos/PID.*': No such file or directory" --- 10. TOOLS PREREQUISITES INSTALLATION tar -xzf apache-ant-1.8.0-bin.tar.gz cd apache-ant-1.8.0 rm lib/README su cp bin/* /usr/local/bin cp lib/* /usr/local/lib exit The documentation can be found in "apache-ant-1.8.0/docs", and installed manually if desired. --- 11. OPENLOGOS TOOLS INSTALLATION unzip OpenLogosTools-1.0.2.zip (if not done already) cd openlogos-1.0.2 export ANT_HOME=/usr/local export LGS_ROOT=/usr/local/logos Under 12.2 some patches to the java files below openlogos-1.0.2/logos_java are needed; these are not needed under 13.0. A list which worked is given below; these should doubtless be improved. Edit "build.xml", and change "ISO8859_1" to "ISO-8859-1". ant -Dbuild.compiler=gcj -v >ant.log The above will successfully compile the ".java" files into ".class" files. There are some warnings; but it seems conventional wisdom is that they can be ignored. The build will abort in the "rmic" step. Examining ant.log shows that the rmic step can be performed as follows. grmic -d build -classpath $RMICCP -vcompat $RMICCL The lists RMICCP and RMICCL are given below. An attempt to use GNUClasspathRmic.class to allow specifying Gnu "grmic" as the rmic compiler failed; see below for further remarks. To finish building the ".jar" file: edit "build.xml"; remove the "rmic" target and the dependency in the "logos_jar" target. ant -Dbuild.compiler=gcj -v >ant.log The Openlogos tools may be installed as follows. su export ANT_HOME=/usr/local export LGS_ROOT=/usr/local/logos ant install-main exit ant install-workdir The last step creates a "working directory" $HOME/OpenLogos for running the tools. --- 12. CONFIGURING THE TOOLS In $LGS_ROOT/conf/gateway/server.properties: Change two lines to the following: Database_UserId=postgres Database_Password=xxx In /usr/lib/java/lib/security/java.policy insert: grant codeBase "file:/usr/local/logos/lib/java/-" { permission java.security.AllPermission; }; These editing operations can be performed with vi in superuser mode. Make sure postgres is running. Let USER denote the user whose HOME directory contains the "OpenLogos" tools working directory. Make sure this is the logon user. Make sure that the directories "joba"s and "submit" in "/tmp/openlogos" are owned by USER. In an xterm window: cd OpenLogos export LGS_ROOT=/usr/local/logos export LD_LIBRARY_PATH=/usr/local/pgsql/lib LogosGateway & This step works under 12.2, but under 13.0 it reports: Exporting the server object... Exception in thread "main" java.lang.ClassFormatError: Invalid superclass index 0 in class file logos_java/LogosGateway/LogosGateway_Skel Create a user: LogosAdmin. Type "administrator" as the password. Select localhost as the server. Create "USER" with some password (say xxx). Set Developer flag. su cd /usr/local/share/openlogos mkdir jre cd jre mkdir bin cd bin ls -s /usr/lib/java/bin/java java --- 13. RUNNING THE TOOLS Make sure postgres is running. Start LogosGateway as above. Issue "LogosTransCenter", and type into the login panel: Username: USER Password: xxx Server: localhost Port: 2135 Example job: Create a profile "diplom" so sysdef is left as is. Add Mathematics as a subject code. Put the file in Openlogos, as an html file (there doesn't seem to be a plain text type). File, submit, select file, set source and target, set Job Type to Translation, set Profile to diplom, submit. Shows as enqueued; note the JOBID. Exit LogosTransCenter export LGS_ROOT="/usr/local/share/openlogos" logos_batch jobid=JOBID userid=USER This first aborted with: sh: /usr/local/share/openlogos/jre/bin/java: No such file or directory Error: Unable to open Return Code File /tmp/openlogos/3054.retcode This was kludged by creating a symbolic link, as describd above. Re-doing the test, it then aborted with: Exception in thread "main" java.lang.NoClassDefFoundError: FileEncoding Possibly the class path must be set. --- 14. WISH LIST Fix the unixODBC-2.2.14-p2 build so it runs under Slackware Linux 13.0 (presumably this is a compiler version problem). Delete the unixODBC PostgreSQL drivers from unixODBC. Fix the error message printing in "transl". The message from an error that occurred using the faulty driver was not what the code seemed to indicate (logos_libs/semtabrule/semtabrulebuilder.cpp:423). Better documentation on the odcb.ini and odcbinst.ini files. Namely, what the items and their fields are; this is presumably a variant of the old Microsoft ODBC ".ini" files. Better documentation on odcb tools, in particular odcbtest. Add "grmic" to the ant build rmic compiler list. Correct the instructions for installing ESENSE. Fix the problem in LogosGateway under 13.0. Documentation on the processors and files involved in job submission, to increase usability and facilitate troubleshooting; in particular, documentation on apitest_settings, LogosGateway, and logos_batch. Configuration instructions for logos_batch. --- 15. LISTS USED FOR GRMIC RMICCL="\ logos_java.AlexReport.ReportBuilderImpl \ logos_java.AutoCode.AutoCodeBuilderImpl \ logos_java.LogosAdmin.TransServer \ logos_java.LogosGateway.ByteStream \ logos_java.LogosGateway.CharacterStream \ logos_java.LogosGateway.FileSetImpl \ logos_java.LogosGateway.LogosGateway$ByteArrayFileSet \ logos_java.LogosGateway.LogosGateway \ logos_java.LogosGateway.LogosGateway2 \ logos_java.LogosGateway.SessionImpl \ logos_java.LogosTransCenter.FileSetImpl \ logos_java.LogosTransCenter.JobListEventListener \ logos_java.LogosTransCenter.StringFileSetImpl \ logos_java.LogosTransCenter.TransServer \ logos_java.PatStem.PatStemBuilderImpl \ logos_java.PatStem.PatStemGeneratorImpl \ logos_java.Reporting.ReportQueryBuilderImpl \ logos_java.Reporting.ReportTreeBuilderImpl \ logos_java.Reporting.SavedReportBuilderImpl \ logos_java.ccdata.CCDataTransferImpl \ logos_java.ccdata.ImportCCDataImpl \ logos_java.database.AdjectiveCombiningFormCodeDescriptionBuilderImpl \ logos_java.database.AdjectivePhraseDescriptionBuilderImpl \ logos_java.database.AdjectivePlacementCodeDescriptionBuilderImpl \ logos_java.database.AdjunctSequenceBuilderImpl \ logos_java.database.AdverbPhraseDescriptionBuilderImpl \ logos_java.database.AdverbPlacementCodeDescriptionBuilderImpl \ logos_java.database.AdverbialCompCodeDescriptionBuilderImpl \ logos_java.database.AlexFactoryRemoteImpl \ logos_java.database.AlexPromptDescriptionBuilderImpl \ logos_java.database.AlexServerImpl \ logos_java.database.AuxiliaryCodeDescriptionBuilderImpl \ logos_java.database.BaseTermAttributeDescriptionBuilderImpl \ logos_java.database.BaseTermBuilderImpl \ logos_java.database.BriefConstantEntryBuilderImpl \ logos_java.database.BriefDictionaryEntryBuilderImpl \ logos_java.database.CaseGovernanceCodeDescriptionBuilderImpl \ logos_java.database.CausativeCodeDescriptionBuilderImpl \ logos_java.database.CombiningFormCodeDescriptionBuilderImpl \ logos_java.database.CompanyDescriptionBuilderImpl \ logos_java.database.ComplimentNumberDescriptionBuilderImpl \ logos_java.database.ConstantPointerBuilderImpl \ logos_java.database.CountryCodeDescriptionBuilderImpl \ logos_java.database.DegreeDescriptionBuilderImpl \ logos_java.database.DetailedBaseTermBuilderImpl \ logos_java.database.DetailedConstantEntryBuilderImpl \ logos_java.database.DetailedDictionaryEntryBuilderImpl \ logos_java.database.DictionaryTermBuilderImpl \ logos_java.database.EndingsCodeDescriptionBuilderImpl \ logos_java.database.FISPListBuilderImpl \ logos_java.database.FactoryRemoteImpl \ logos_java.database.FormCodeDescriptionBuilderImpl \ logos_java.database.GenderDescriptionBuilderImpl \ logos_java.database.HalfNounTempBuilderImpl \ logos_java.database.ImportBuilderImpl \ logos_java.database.IndividualizationDescriptionBuilderImpl \ logos_java.database.IrregularStemBuilderImpl \ logos_java.database.LanguageDescriptionBuilderImpl \ logos_java.database.LanguagePairDescriptionBuilderImpl \ logos_java.database.LogosOteloConvertBuilderImpl \ logos_java.database.MeaningBuilderImpl \ logos_java.database.MoodCodeDescriptionBuilderImpl \ logos_java.database.MorphologyBuilderImpl \ logos_java.database.NounPhraseDescriptionBuilderImpl \ logos_java.database.NumericConstraintDescriptionBuilderImpl \ logos_java.database.OteloLogosConvertBuilderImpl \ logos_java.database.OverflowBuilderImpl \ logos_java.database.PMEntryBuilderImpl \ logos_java.database.PatDescriptionBuilderImpl \ logos_java.database.PhaseDescriptionBuilderImpl \ logos_java.database.PrepTypeDescriptionBuilderImpl \ logos_java.database.PreverbalPrepCodeDescriptionBuilderImpl \ logos_java.database.ProfileBuilderImpl \ logos_java.database.ReflexCodeDescriptionBuilderImpl \ logos_java.database.SemtabPromptDescriptionBuilderImpl \ logos_java.database.SemtabRuleBuilderImpl \ logos_java.database.SetIDDescriptionBuilderImpl \ logos_java.database.SetsInSupersetBuilderImpl \ logos_java.database.SmcTreeBuilderImpl \ logos_java.database.SourceAnalysisCodeDescriptionBuilderImpl \ logos_java.database.StemDescriptionBuilderImpl \ logos_java.database.SubsetIDDescriptionBuilderImpl \ logos_java.database.SupersetIDDescriptionBuilderImpl \ logos_java.database.TimeDescriptionBuilderImpl \ logos_java.database.TransferBuilderImpl \ logos_java.database.TransitivityDescriptionBuilderImpl \ logos_java.database.TypeOfSituationDescriptionBuilderImpl \ logos_java.database.UniqueTypeDescriptionBuilderImpl \ logos_java.database.UserBuilderImpl \ logos_java.database.VerbParticleBuilderImpl \ logos_java.database.VerbPhraseDescriptionBuilderImpl \ logos_java.database.VerbSubsetBuilderImpl \ logos_java.database.WordClassDescriptionBuilderImpl \ logos_java.database.WordClassDescriptionForAddConstantBuilderImpl \ logos_java.database.WordClassSubtypeBuilderImpl \ logos_java.database.WordInPhraseBuilderImpl \ logos_java.database.WordPhraseBuilderImpl \ logos_java.database.WordTypeDescriptionBuilderImpl \ logos_java.devsem.DevSemtabImpl \ logos_java.lde.admin.JobAdminImpl \ logos_java.lde.admin.UserAdminImpl \ logos_java.lde.report.Dictionary1Impl \ logos_java.lde.report.DictionaryReport" In the following, "/home/martin/trans" should be replaced by the user's WRKDIR. RMICCP=/home/martin/trans/openlogos-1.0.2/build:\ /home/martin/trans/openlogos-1.0.2:\ /home/martin/trans/openlogos-1.0.2/lib/java/MDateSelector.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/activation.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/commons-logging.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/icebrowserlitebean.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/jakarta-regexp-1.1.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/jaxp.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/jbcl3.1.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/jcbwt300.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/jctable360.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/jh.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/mail_1_2.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/mailet.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/postgresql-8.0-311.jdbc3.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/pvDatePl.jar:\ /home/martin/trans/openlogos-1.0.2/lib/java/sort.jar:\ /usr/local/lib/ant-launcher.jar:\ /usr/local/lib/ant-antlr.jar:\ /usr/local/lib/ant-apache-bcel.jar:\ /usr/local/lib/ant-apache-bsf.jar:\ /usr/local/lib/ant-apache-log4j.jar:\ /usr/local/lib/ant-apache-oro.jar:\ /usr/local/lib/ant-apache-regexp.jar:\ /usr/local/lib/ant-apache-resolver.jar:\ /usr/local/lib/ant-apache-xalan2.jar:\ /usr/local/lib/ant-commons-logging.jar:\ /usr/local/lib/ant-jai.jar:\ /usr/local/lib/ant-commons-net.jar:\ /usr/local/lib/ant-javamail.jar:\ /usr/local/lib/ant-jdepend.jar:\ /usr/local/lib/ant-jmf.jar:\ /usr/local/lib/ant-jsch.jar:\ /usr/local/lib/ant-junit.jar:\ /usr/local/lib/ant-netrexx.jar:\ /usr/local/lib/ant-nodeps.jar:\ /usr/local/lib/ant-stylebook.jar:\ /usr/local/lib/ant-swing.jar:\ /usr/local/lib/ant-testutil.jar:\ /usr/local/lib/ant-trax.jar:\ /usr/local/lib/ant.jar:\ /usr/local/lib/xercesImpl.jar:\ /usr/local/lib/xml-apis.jar --- 16. LIST OF FILES INSTALLED: postgresql-8.4.2: /usr/local/pgsql/ unixODBC-2.2.14-p2: /usr/local/bin odbcinst, isql, dltest, odbc_config, iusql, ODBCConfig, odbctest, DataManagerII, DataManager /usr/local/lib libodbcinst.*, libodbc.*, libodbcinstQ.*, libodbcpsqlS.*, libodbcdrvcfg2S.*, libodbcdrvcfg1S.*, libodbccr.*, libtdsS.*, liboplodbcS.*, libodbcnnS.*, libodbcmyS.*, libodbcminiS.*, libesoobS.*, libsapdbS.*, liboraodbcS.*, libodbctxtS.*, libodbcpsql.*, libmimerS.*, libtemplate.*, libnn.*, libgtrtst.*, libboundparam.* /usr/local/include autotest.h, odbcinst.h, odbcinstext.h, sql.h, sqlext.h, sqltypes.h, sqlucode.h, unixodbc_conf.h, uodbc_extras.h, uodbc_stats.h, /usr/local/etc ODBCDataSources/, odbc.ini, odbcinst.ini psqlodbc-08.04.0200 /usr/local/lib psqlodbcw.* openlogos-1.0.3: /usr/local/bin APITest, ConvertMini, patstemgenerator, logos_batch, openlogos /usr/local/lib lib.*, libgrammarrules.*, libhalfnoun.*, libhalfnounjava.*, liblgs_base.*, liblgs_db_io.*, liblgs_parsetran1dll.*, liblgs_parsetran2dll.*, liblgs_parsetran3dll.*, liblgs_parsetran4dll.*, liblgs_res.*, liblgs_tran1dll.*, liblgs_tran2dll.*, liblgs_tran3dll.*, liblgs_tran4dll.*, liblgs_tran_rule_io.*, liblinguistic.*, libtransl.*, libxlationinterface.* /usr/local/share openlogos/ apache-ant-1.8.0-bin: /usr/local/bin ant, ant.bat ant.cmd antRun, antRun.bat antRun.pl, antenv.cmd complete-ant-cmd.pl, envset.cmd lcp.bat runant.pl, runant.py, runrc.cm /usr/local/lib ant-*, ant.jar, libraries.properties, xercesImpl.jar, xml-apis.jar OpenLogosTools-1.0.2: /usr/local/bin LogosTransCenter LogosTermBuilder LogosGateway LogosAdmin /usr/local/logos /tmp/openlogos fastjar-0.98: /usr/local/share/man/man1 grepjar.1 fastjar.1 /usr/local/share/info fastjar.info dir /usr/local/bin grepjar fastjar --- 17. PATCHES TO OPENLOGOS-1.0.2/LOGOS_JAVA FILES FOR 12.2: -AlexReport/AlexReport.java 153,154c153 < // throws SQLException, RemoteException < throws SQLException, RemoteException, Exception //FIX --- > throws SQLException, RemoteException -alex/UpdateCompanyDialog.java 197,199c197 < // super(vector, UpdateCompanyDialog.this.getBackground()); < super(vector, null); //FIX < --- > super(vector, UpdateCompanyDialog.this.getBackground()); -import_export/ImportFrame.java 1848c1848 < //if(((String)importTableModel.getValueAt(r,c)).indexOf(findString ) != -1 ) --- > //if(((String)importTableModel.getValueAt(r,c)).indexOf(findString ) != -1 ){ 2254c2254 < //outer: while (r< importTableModel.getRowCount() && r >= 0) --- > //outer: while (r< importTableModel.getRowCount() && r >= 0){ 2382c2382 < {Exception ex1 = new Exception("deferred exception"); //FIX --- > { 2385,2386c2385 < // ErrorHandler.handleException(importFrame, ex,"Import"); < ErrorHandler.handleException(importFrame, ex1,"Import"); //FIX --- > ErrorHandler.handleException(importFrame, ex,"Import"); 2696c2695 < } --- > } \ No newline at end of file -pm/PMEditPanel.java 128,129c128 < // throws SQLException, RemoteException < throws SQLException, RemoteException, Exception //FIX --- > throws SQLException, RemoteException 608c607 < } --- > } \ No newline at end of file These have been given as simple diff output. Some "{"'s in disabled code were removed, to facilitate editing. --- 18. ATTEMPT TO USE GNUCLASSPATHRMIC There's no "jar" processor in standard Slackware Linux. The file fastjar-0.98.tar.gz was downloaded and installed as usual. GNUClasspathRmic can be installed as follows. gcj --classpath=$CPANT -C GNUClasspathRmic.java fastjar -c -f GNUClasspathRmic.jar GNUClasspathRmic.class su cp GNUClasspathRmic.jar /usr/local/lib exit CPANT may be found below. Editing "build.xml" and adding compiler="ant.taskdefs.rmic.GNUClasspathRmic" to the rmic attributes resulted in a message that an incompatibility was encountered. CPANT=\ /usr/local/lib/ant-launcher.jar:\ /usr/local/lib/ant-antlr.jar:\ /usr/local/lib/ant-apache-bcel.jar:\ /usr/local/lib/ant-apache-bsf.jar:\ /usr/local/lib/ant-apache-log4j.jar:\ /usr/local/lib/ant-apache-oro.jar:\ /usr/local/lib/ant-apache-regexp.jar:\ /usr/local/lib/ant-apache-resolver.jar:\ /usr/local/lib/ant-apache-xalan2.jar:\ /usr/local/lib/ant-commons-logging.jar:\ /usr/local/lib/ant-jai.jar:\ /usr/local/lib/ant-commons-net.jar:\ /usr/local/lib/ant-javamail.jar:\ /usr/local/lib/ant-jdepend.jar:\ /usr/local/lib/ant-jmf.jar:\ /usr/local/lib/ant-jsch.jar:\ /usr/local/lib/ant-junit.jar:\ /usr/local/lib/ant-netrexx.jar:\ /usr/local/lib/ant-nodeps.jar:\ /usr/local/lib/ant-stylebook.jar:\ /usr/local/lib/ant-swing.jar:\ /usr/local/lib/ant-testutil.jar:\ /usr/local/lib/ant-trax.jar:\ /usr/local/lib/ant.jar:\ /usr/local/lib/xercesImpl.jar:\ /usr/local/lib/xml-apis.jar --- 19. TYPING GERMAN As a neophyte, I had to find out how to type German; I've included a short description for other neophytes. The 8 bit character code "ISO-8859-1 (Latin 1)" is well supported by Linux, and includes extra symbols used in the main west European languages. Those used by German are as follows: umlaut-a 0344 228 0xe4 umlaut-o 0366 246 0xf6 umlaut-u 0374 252 0xfc umlaut-A 0304 196 0xc4 umlaut-O 0326 214 0xd6 umlaut-U 0334 220 0xdc scharfes-s 0337 223 0xdf To type a special character using vi (elvis under Slackware Linux), type "Ctrl-x", and then the two hex digits of the code. The characters display properly in an xterm window, with the "7x14" font.