>>117
ムリス、

つか次のように死ぬほど腐った書き方をしたらとりあえずできるた、
/// 間接ソート版lower_bound
int custom_lower_bound(const std::vector<SomeBigObj>& arr, std::vector<int>& indices, const SomeBigObj& x)
{
 // SomeBigObjの間接ソート用比較関数
 // xのコピーを避けるため[&](a, b)とする。
 auto cmpFunc = [&](const int a, const int b)->bool {
  // 有り得ないindex値が渡ってきたらxとみなす。
  const SomeBigObj& obj1 = (a < 0) ? x : arr[a];
  const SomeBigObj& obj2 = (b < 0) ? x : arr[b];
  return (obj1 < obj2);
 };
 // lower_bound()の第3引数(検索キー)を有り得ないindex値にしておく。
 auto found_it = std::lower_bound(indices.begin(), indices.end(), -1, cmpFunc);
 // Indexに変換
 return (int)std::distance(indices.begin(), found_it);
}

動作するサンプル例:
https://ideone.com/xbSHmi