change to Linux
This commit is contained in:
parent
ad5afe448d
commit
ed29db3699
|
@ -1,23 +1,22 @@
|
|||
{
|
||||
"configurations": [
|
||||
{
|
||||
"name": "Win32",
|
||||
"name": "Linux",
|
||||
"includePath": [
|
||||
"${default}",
|
||||
"${workspaceFolder}/include",
|
||||
"D:/Geant4/dist/include/Geant4",
|
||||
"D:/ROOT/include"
|
||||
"/home/fox/G4Kit/Geant4/include",
|
||||
"/home/fox/G4Kit/ROOT/include"
|
||||
],
|
||||
"defines": [
|
||||
"_DEBUG",
|
||||
"UNICODE",
|
||||
"_UNICODE"
|
||||
],
|
||||
"windowsSdkVersion": "10.0.19041.0",
|
||||
"compilerPath": "D:/Microsoft/VisualStudio/2022/Community/VC/Tools/MSVC/14.31.31103/bin/Hostx64/x64/cl.exe",
|
||||
"compilerPath": "/usr/bin/gcc",
|
||||
"cStandard": "c17",
|
||||
"cppStandard": "c++17",
|
||||
"intelliSenseMode": "windows-msvc-x64",
|
||||
"intelliSenseMode": "linux-gcc-x64",
|
||||
"configurationProvider": "ms-vscode.cmake-tools"
|
||||
}
|
||||
],
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
{
|
||||
"cmake.configureSettings": {
|
||||
"CMAKE_TOOLCHAIN_FILE": "D:/Microsoft/vcpkg/scripts/buildsystems/vcpkg.cmake"
|
||||
}
|
||||
}
|
|
@ -8,6 +8,7 @@ project(B1)
|
|||
# You can set WITH_GEANT4_UIVIS to OFF via the command line or ccmake/cmake-gui
|
||||
# to build a batch mode only executable
|
||||
#
|
||||
set(Geant4_DIR ${Geant4_DIR})
|
||||
option(WITH_GEANT4_UIVIS "Build example with Geant4 UI and Vis drivers" ON)
|
||||
if(WITH_GEANT4_UIVIS)
|
||||
find_package(Geant4 REQUIRED ui_all vis_all)
|
||||
|
@ -52,7 +53,7 @@ set(EXAMPLEB1_SCRIPTS
|
|||
foreach(_script ${EXAMPLEB1_SCRIPTS})
|
||||
configure_file(
|
||||
${PROJECT_SOURCE_DIR}/${_script}
|
||||
${PROJECT_BINARY_DIR}/Release/${_script}
|
||||
${PROJECT_BINARY_DIR}/${_script}
|
||||
COPYONLY
|
||||
)
|
||||
endforeach()
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include "ActionInitialization.hh" // 用户初始化
|
||||
#include "DetectorConstruction.hh" // 探测器构建文件
|
||||
#include "G4RunManagerFactory.hh" // 管理类
|
||||
#include "G4MTRunManager.hh" // 管理类
|
||||
#include "G4SteppingVerbose.hh" // step信息管理 verbose越大,输出越丰富
|
||||
#include "G4UIExecutive.hh" // UI操作
|
||||
#include "G4UImanager.hh" // UI管理
|
||||
|
@ -23,7 +23,7 @@ int main(int argc, char** argv) {
|
|||
G4SteppingVerbose::UseBestUnit(precision);
|
||||
|
||||
// 构建运行管理器
|
||||
auto* runManager = G4RunManagerFactory::CreateRunManager(G4RunManagerType::Default);
|
||||
G4MTRunManager* runManager = new G4MTRunManager;
|
||||
|
||||
// 进行强制类的初始化
|
||||
//
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
/run/verbose 2
|
||||
#
|
||||
# Change the default number of threads (in multi-threaded mode)
|
||||
#/run/numberOfThreads 4
|
||||
/run/numberOfThreads 4
|
||||
#
|
||||
# Initialize kernel
|
||||
/run/initialize
|
||||
|
|
Loading…
Reference in New Issue