[SERVER-6690] Relative path to pch.h not set Created: 02/Aug/12  Updated: 11/Jul/16  Resolved: 06/Aug/12

Status: Closed
Project: Core Server
Component/s: Internal Client
Affects Version/s: 2.2.0-rc0
Fix Version/s: 2.2.0-rc1

Type: Bug Priority: Major - P3
Reporter: David Schneider Assignee: siddharth.singh@10gen.com
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Operating System: ALL
Participants:

 Description   

I can't compile my user code with the new cxx-driver (downloaded from http://downloads.mongodb.org/cxx-driver/mongodb-linux-x86_64-2.2.0-rc0.tgz) because of include "pch.h".
There should be a relative path to pch.h in all cxx-driver header file. Otherwise I would have to add /usr/local/include/mongo to the include search path. Which is a bad option in my option.

/usr/local/include/mongo$ grep -r "#include \".*pch.h\"" .
./client/dbclient.h:#include "pch.h"
./client/dbclientinterface.h:#include "pch.h"
./client/dbclientcursor.h:#include "pch.h"
./client/dbclient_rs.h:#include "pch.h"
./client/distlock.h:#include "../pch.h"
./s/cursors.h:#include "../pch.h"
./s/chunk.h:#include "../pch.h"
./s/d_logic.h:#include "../pch.h"
./s/client_info.h:#include "mongo/pch.h"
./s/balance.h:#include "../pch.h"
./s/d_writeback.h:#include "../pch.h"
./s/interrupt_status_mongos.h:#include "pch.h"
./s/util.h:#include "mongo/pch.h"
./s/writeback_listener.h:#include "../pch.h"
./s/shard.h:#include "pch.h"
./s/request.h:#include "../pch.h"
./s/stats.h:#include "../pch.h"
./s/strategy.h:#include "../pch.h"
./s/d_chunk_manager.h:#include "../pch.h"
./db/db.h:#include "../pch.h"
./db/client.h:#include "../pch.h"
./db/cursor.h:#include "../pch.h"
./db/cmdline.h:#include "../pch.h"
./db/interrupt_status_mongod.h:#include "pch.h"
./db/client_common.h://#include "../pch.h"
./db/indexkey.h:#include "../pch.h"
./db/ops/query.h:#include "../../pch.h"
./db/ops/update.h:#include "pch.h"
./db/ops/update_internal.h:#include "pch.h"
./db/ops/delete.h:#include "../../pch.h"
./db/btree.h:#include "pch.h"
./db/jsobj.h:#include "../pch.h"
./db/repl_block.h:#include "../pch.h"
./db/module.h:#include "../pch.h"
./db/extsort.h:#include "pch.h"
./db/interrupt_status.h:#include "pch.h"
./db/index.h:#include "pch.h"
./db/stats/counters.h:#include "../../pch.h"
./db/stats/snapshots.h:#include "../../pch.h"
./db/dbhelpers.h:#include "../pch.h"
./db/introspect.h:#include "../pch.h"
./db/namespace_details.h:#include "pch.h"
./db/clientcursor.h:#include "pch.h"
./db/hasher.h:#include "pch.h"
./db/projection.h:#include "pch.h"
./db/namespace.h:#include "pch.h"
./util/trace.h:#include "pch.h"
./util/net/sock.h:#include "../../pch.h"
./util/net/message_server.h:#include "../../pch.h"
./util/net/miniwebserver.h:#include "../../pch.h"
./util/net/httpclient.h:#include "../../pch.h"
./util/file_allocator.h:#include "pch.h"
./util/hashtab.h:#include "../pch.h"
./util/queue.h:#include "pch.h"
./util/winutil.h:// #include "pch.h"
./util/checksum.h:#include "../pch.h"
./util/bson_util.h:#include "../pch.h"
./util/iterator.h:#include "pch.h"
./util/lruishmap.h:#include "../pch.h"
./util/string_writer.h:#include "pch.h"



 Comments   
Comment by siddharth.singh@10gen.com [ 06/Aug/12 ]

https://github.com/mongodb/mongo/commit/dddeb8a48880d941237388f313779893ae460a8b

Comment by Andy Schwerin [ 02/Aug/12 ]

Our preferred solution in the code base is to include "mongo/pch.h", rather than "pch.h".

Generated at Thu Feb 08 03:12:25 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.