From acc3b348665cac7fe330a378787790414bf5509b Mon Sep 17 00:00:00 2001 From: erickson Date: Wed, 20 Feb 2008 00:27:37 +0000 Subject: [PATCH] mergin in some trunk changes svn merge -r8460:8461 svn://svn.open-ils.org/ILS/trunk/ svn merge -r8458:8459 svn://svn.open-ils.org/ILS/trunk/ git-svn-id: svn://svn.open-ils.org/ILS/branches/acq-experiment@8792 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- .../c-apps => include}/openils/idl_fieldmapper.h | 0 .../c-apps => include}/openils/oils_constants.h | 0 .../{src/c-apps => include}/openils/oils_event.h | 0 .../{src/c-apps => include}/openils/oils_idl.h | 0 .../{src/c-apps => include}/openils/oils_utils.h | 0 Open-ILS/src/Makefile | 2 +- Open-ILS/src/c-apps/Makefile | 18 ++++------------ Open-ILS/src/extras/Makefile | 3 ++- Open-ILS/src/extras/Makefile.install | 10 ++++----- .../src/support-scripts/test-scripts/acq_fund.py | 24 +++++++++++----------- Open-ILS/web/oilsweb/oilsweb/lib/user.py | 2 +- 11 files changed, 25 insertions(+), 34 deletions(-) rename Open-ILS/{src/c-apps => include}/openils/idl_fieldmapper.h (100%) rename Open-ILS/{src/c-apps => include}/openils/oils_constants.h (100%) rename Open-ILS/{src/c-apps => include}/openils/oils_event.h (100%) rename Open-ILS/{src/c-apps => include}/openils/oils_idl.h (100%) rename Open-ILS/{src/c-apps => include}/openils/oils_utils.h (100%) diff --git a/Open-ILS/src/c-apps/openils/idl_fieldmapper.h b/Open-ILS/include/openils/idl_fieldmapper.h similarity index 100% rename from Open-ILS/src/c-apps/openils/idl_fieldmapper.h rename to Open-ILS/include/openils/idl_fieldmapper.h diff --git a/Open-ILS/src/c-apps/openils/oils_constants.h b/Open-ILS/include/openils/oils_constants.h similarity index 100% rename from Open-ILS/src/c-apps/openils/oils_constants.h rename to Open-ILS/include/openils/oils_constants.h diff --git a/Open-ILS/src/c-apps/openils/oils_event.h b/Open-ILS/include/openils/oils_event.h similarity index 100% rename from Open-ILS/src/c-apps/openils/oils_event.h rename to Open-ILS/include/openils/oils_event.h diff --git a/Open-ILS/src/c-apps/openils/oils_idl.h b/Open-ILS/include/openils/oils_idl.h similarity index 100% rename from Open-ILS/src/c-apps/openils/oils_idl.h rename to Open-ILS/include/openils/oils_idl.h diff --git a/Open-ILS/src/c-apps/openils/oils_utils.h b/Open-ILS/include/openils/oils_utils.h similarity index 100% rename from Open-ILS/src/c-apps/openils/oils_utils.h rename to Open-ILS/include/openils/oils_utils.h diff --git a/Open-ILS/src/Makefile b/Open-ILS/src/Makefile index fff0bad178..ec7082cc69 100644 --- a/Open-ILS/src/Makefile +++ b/Open-ILS/src/Makefile @@ -2,7 +2,7 @@ export LDFLAGS += -L . -L$(TMP) -L $(OPENSRF_LIBS) export CFLAGS += -pipe -g -Wall -O2 -fPIC -I$(LIBXML2_HEADERS) -I$(APACHE2_HEADERS) -I$(APR_HEADERS) \ - -D_LARGEFILE64_SOURCE -I$(LIBXML2_HEADERS)/libxml -I$(TMP) -I$(OPENSRF_HEADERS) + -D_LARGEFILE64_SOURCE -I$(LIBXML2_HEADERS)/libxml -I$(TMP) -I$(OPENSRF_HEADERS) export INCDIR = "$(INCLUDEDIR)/openils/" diff --git a/Open-ILS/src/c-apps/Makefile b/Open-ILS/src/c-apps/Makefile index c39465cd56..0ac65fca4b 100644 --- a/Open-ILS/src/c-apps/Makefile +++ b/Open-ILS/src/c-apps/Makefile @@ -1,6 +1,6 @@ LDLIBS += -lobjson -lopensrf #-lfieldmapper LDFLAGS += -Wl,-rpath=$(LIBDIR) -L$(DBI_LIBS) -CFLAGS += -DOSRF_LOG_PARAMS +CFLAGS += -DOSRF_LOG_PARAMS -I../../include #all: oils_auth.so oils_fetch.so oils_cstore.so all: liboils_idl.so oils_auth.so oils_cstore.so oils_rstore.so oils_dataloader @@ -22,7 +22,7 @@ oils_cstore.so: oils_cstore.o liboils_utils.so liboils_idl.so $(CC) -shared -W1 $(LDLIBS) $(LDFLAGS) -loils_idl -ldbi -loils_utils -ldbdpgsql oils_cstore.o -o $@ oils_rstore.o: oils_cstore.c - $(CC) $(CFLAGS) -I$(TMP) -DRSTORE -c -o $@ oils_cstore.c + $(CC) $(CFLAGS) -DRSTORE -c -o $@ oils_cstore.c oils_rstore.so: oils_rstore.o liboils_utils.so liboils_idl.so @echo $@ @@ -36,11 +36,7 @@ oils_idl-core.o: oils_idl-core.c liboils_idl.so: oils_idl-core.o @echo $@ - $(CC) -shared -W1 $(LDLIBS) $(LDFLAGS) oils_idl-core.o -o $@ -# cp $@ $(TMP)/ -# mkdir -p $(TMP)/openils/ -# cp oils_idl.h $(TMP)/openils/ -# cp idl_fieldmapper.h $(TMP)/openils/ + $(CC) $(CFLAGS) -shared -W1 $(LDLIBS) $(LDFLAGS) oils_idl-core.o -o $@ oils_auth.so: oils_auth.o liboils_utils.so @echo $@ @@ -49,23 +45,17 @@ oils_auth.so: oils_auth.o liboils_utils.so liboils_utils.so: oils_utils.o oils_event.o @echo $@ $(CC) -shared -W1 $(LDLIBS) $(LDFLAGS) oils_utils.o oils_event.o -o $@ -# cp $@ $(TMP)/ -# mkdir -p $(TMP)/openils/ -# cp oils_event.h $(TMP)/openils/ -# cp oils_utils.h $(TMP)/openils/ -# cp oils_constants.h $(TMP)/openils/ install: @echo $@; cp oils_auth.so $(LIBDIR)/ - #cp $(TMP)/oils_fetch.so $(LIBDIR)/ cp oils_cstore.so $(LIBDIR)/ cp oils_rstore.so $(LIBDIR)/ cp liboils_utils.so $(LIBDIR)/ cp liboils_idl.so $(LIBDIR)/ cp oils_dataloader $(BINDIR)/ mkdir -p $(INCDIR)/ - cp openils/*.h $(INCDIR)/ + cp ../../include/openils/*.h $(INCDIR)/ clean: @echo $@; diff --git a/Open-ILS/src/extras/Makefile b/Open-ILS/src/extras/Makefile index aa4d3c791c..40ae124324 100644 --- a/Open-ILS/src/extras/Makefile +++ b/Open-ILS/src/extras/Makefile @@ -1,4 +1,5 @@ -LDLIBS += -lreadline -loils_utils -lopensrf -lobjson -lxml2 -loils_idl +LDLIBS += -lreadline -loils_utils -lopensrf -lobjson -lxml2 -loils_idl -L../c-apps +CFLAGS += -I../../include all: oils_requestor oils_requestor: oils_requestor.o diff --git a/Open-ILS/src/extras/Makefile.install b/Open-ILS/src/extras/Makefile.install index 365be27a47..bfc3b48a0a 100644 --- a/Open-ILS/src/extras/Makefile.install +++ b/Open-ILS/src/extras/Makefile.install @@ -28,8 +28,8 @@ # not require fetching the sources externally ... needs testing/updating in here -LIBJS=js-1.60 -LIBJS_PERL=JavaScript-SpiderMonkey-0.17 +LIBJS=js-1.7.0 +LIBJS_PERL=JavaScript-SpiderMonkey-0.19 LIBJS_URL=ftp://ftp.mozilla.org/pub/mozilla.org/js/$(LIBJS).tar.gz LIBJS_PERL_URL=ftp://mirror.datapipe.net/pub/CPAN/authors/id/T/TB/TBUSCH/$(LIBJS_PERL).tar.gz # used for installing libjs lib and header files @@ -95,8 +95,8 @@ DEBS = \ libreadline5-dev\ libtext-csv-perl\ libspreadsheet-writeexcel-perl\ - libtie-ixhash-perl - + libtie-ixhash-perl\ + python-setuptools GENTOOS = \ @@ -204,7 +204,7 @@ install_js_sm: cp js/src/*.tbl $(JS_INSTALL_PREFIX)/include/js/ cp js/src/Linux_All_DBG.OBJ/*.so $(JS_INSTALL_PREFIX)/lib/ cp js/src/Linux_All_DBG.OBJ/*.a $(JS_INSTALL_PREFIX)/lib/ - cd JavaScript-SpiderMonkey-0.17 && perl Makefile.PL -E4X && make && make test && make install + cd $(LIBJS_PERL) && perl Makefile.PL -E4X && make && make test && make install # Install libdbi and the postgres drivers diff --git a/Open-ILS/src/support-scripts/test-scripts/acq_fund.py b/Open-ILS/src/support-scripts/test-scripts/acq_fund.py index 698be95837..17f16b5a59 100644 --- a/Open-ILS/src/support-scripts/test-scripts/acq_fund.py +++ b/Open-ILS/src/support-scripts/test-scripts/acq_fund.py @@ -4,10 +4,10 @@ import oils.system, oils.utils.utils import osrf.net_obj, osrf.ses # --------------------------------------------------------------- -# Usage: python acq_fund.py +# Usage: python acq_fund_source.py # --------------------------------------------------------------- -oils.system.oilsConnect('/openils/conf/opensrf_core.xml', 'config.opensrf') +oils.system.System.connect(config_file='/openils/conf/opensrf_core.xml', config_context='config.opensrf') auth_info = oils.utils.utils.login(sys.argv[1], sys.argv[2], 'staff', sys.argv[3]) authtoken = auth_info['payload']['authtoken'] @@ -17,22 +17,22 @@ ses.connect() # not required, but faster for batches of request # XXX This loop assumes the existence of orgs with IDs 1-6 and a USD currency ids = [] for i in range(0,5): - fund = osrf.net_obj.NetworkObject.acqfund() - fund.name("test-fund-%d" % i) - fund.owner(i+1) - fund.currency_type('USD') - req = ses.request('open-ils.acq.fund.create', authtoken, fund) + fund_source = osrf.net_obj.NetworkObject.acqfs() + fund_source.name("test-fund_source-%d" % i) + fund_source.owner(i+1) + fund_source.currency_type('USD') + req = ses.request('open-ils.acq.funding_source.create', authtoken, fund_source) id = req.recv().content() - print 'created fund ' + str(id) + print 'created fund_source ' + str(id) ids.append(id) -req = ses.request('open-ils.acq.fund.org.retrieve', authtoken, 1, {"children":1}) +req = ses.request('open-ils.acq.funding_source.org.retrieve', authtoken, 1, {"children":1}) resp = req.recv().content() -for fund in resp: - print 'fetched fund ' + str(fund.name()) +for fund_source in resp: + print 'fetched fund_source ' + str(fund_source.name()) for i in ids: - req = ses.request('open-ils.acq.fund.delete', authtoken, i) + req = ses.request('open-ils.acq.funding_source.delete', authtoken, i) print 'delete returned ' + str(req.recv().content()) diff --git a/Open-ILS/web/oilsweb/oilsweb/lib/user.py b/Open-ILS/web/oilsweb/oilsweb/lib/user.py index 420131f0c4..a67093fb04 100644 --- a/Open-ILS/web/oilsweb/oilsweb/lib/user.py +++ b/Open-ILS/web/oilsweb/oilsweb/lib/user.py @@ -38,7 +38,7 @@ class User(object): evt = oils.event.Event.parse_event(self.ctx.user.value) if evt and evt.text_code == 'NO_SESSION': - # our authtoken.value has timed out. See if we can autologin + # our authtoken has timed out. See if we can autologin self.try_auto_login() if not self.ctx.authtoken.value: raise AuthException(_('No authentication token provided')) -- 2.11.0