Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
gmsh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Larry Price
gmsh
Commits
e035d269
Commit
e035d269
authored
11 years ago
by
Maxime Graulich
Browse files
Options
Downloads
Patches
Plain Diff
Mobile port
parent
4942a341
No related branches found
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
CMakeLists.txt
+39
-0
39 additions, 0 deletions
CMakeLists.txt
Common/GmshMessage.cpp
+5
-1
5 additions, 1 deletion
Common/GmshMessage.cpp
Common/GmshMessage.h
+1
-0
1 addition, 0 deletions
Common/GmshMessage.h
Common/OpenFile.cpp
+1
-1
1 addition, 1 deletion
Common/OpenFile.cpp
with
46 additions
and
2 deletions
CMakeLists.txt
+
39
−
0
View file @
e035d269
...
...
@@ -30,6 +30,8 @@ option(ENABLE_BLAS_LAPACK "Use BLAS and Lapack for linear algebra" ON)
option
(
ENABLE_BLOSSOM
"Enable Blossom algo (based on MATCH and concorde97)"
${
DEFAULT
}
)
option
(
ENABLE_BUILD_LIB
"Build static Gmsh library"
OFF
)
option
(
ENABLE_BUILD_SHARED
"Build shared Gmsh library"
OFF
)
option
(
ENABLE_BUILD_ANDROID
"Build Gmsh library for Android NDK"
OFF
)
option
(
ENABLE_BUILD_IOS
"Build Gmsh library for iOS"
OFF
)
option
(
ENABLE_CGNS
"Enable CGNS mesh export"
OFF
)
option
(
ENABLE_CHACO
"Enable Chaco mesh partitioner"
${
DEFAULT
}
)
option
(
ENABLE_DINTEGRATION
"Enable discrete integration and levelsets"
${
DEFAULT
}
)
...
...
@@ -285,6 +287,10 @@ if(ENABLE_BLAS_LAPACK)
set_config_option
(
HAVE_BLAS
"Blas(VecLib)"
)
set_config_option
(
HAVE_LAPACK
"Lapack(VecLib)"
)
endif
(
MSVC
)
if
(
BUILD_ANDROID
)
set_config_option
(
HAVE_BLAS
"Blas"
)
set_config_option
(
HAVE_LAPACK
"Lapack"
)
endif
(
BUILD_ANDROID
)
if
(
NOT HAVE_BLAS OR NOT HAVE_LAPACK
)
# if we haven't found blas and lapack without using the standard
# cmake tests, do it (this requires a working Fortran compiler)
...
...
@@ -427,6 +433,35 @@ if(ENABLE_ONELAB)
endif
(
ENABLE_ONELAB_METAMODEL
)
endif
(
ENABLE_ONELAB
)
if
(
ENABLE_BUILD_IOS
)
#TODO
endif
(
ENABLE_BUILD_IOS
)
if
(
ENABLE_BUILD_ANDROID
)
# we need getdp lib
#find_library(GETDP_LIB Gmsh PATH_SUFFIXES lib)
#find_path(GETDP_INC "GetDP.h" PATH_SUFFIXES include getdp include/getdp)
#if(GETDP_LIB AND GETDP_INC)
# list(APPEND EXTERNAL_LIBRARIES ${GETDP_LIB})
# list(APPEND EXTERNAL_INCLUDES ${GETDP_INC})
# set_config_option(HAVE_GETDP "GetDP")
#else(GETDP_LIB AND GETDP_INC)
# message(SEND_ERROR "Cannot compile Gmsh for Android without GetDP")
#endif(GETDP_LIB AND GETDP_INC)
# then we can make gmsh lib
set
(
CMAKE_BUILD_TYPE Release
)
add_definitions
(
-DBUILD_ANDROID
)
set
(
LIBRARY_OUTPUT_PATH_ROOT
${
CMAKE_CURRENT_BINARY_DIR
}
)
set
(
LIBRARY_OUTPUT_PATH
${
CMAKE_CURRENT_BINARY_DIR
}
/libs/
)
#add_subdirectory(Mobile/Android/)
#add_library(androidGmsh SHARED Mobile/Android/drawGModel.cpp Mobile/Android/androidGModel.cpp ${GMSH_SRC})
add_library
(
androidGmsh SHARED
${
GMSH_SRC
}
)
#set( LIBRARY_DEPS GLESv1_CM log)
set_target_properties
(
androidGmsh PROPERTIES OUTPUT_NAME Gmsh
)
target_link_libraries
(
androidGmsh
${
LINK_LIBRARIES
}
)
endif
(
ENABLE_BUILD_ANDROID
)
if
(
HAVE_FLTK OR HAVE_QT OR ENABLE_GRAPHICS
)
if
(
NOT HAVE_MESH OR NOT HAVE_POST OR NOT HAVE_PLUGINS OR NOT HAVE_ONELAB
)
message
(
SEND_ERROR
"Cannot compile GUI without Mesh, Post, Plugin or OneLab"
)
...
...
@@ -1205,6 +1240,10 @@ endif(ENABLE_BUILD_LIB)
if
(
ENABLE_BUILD_SHARED
)
install
(
TARGETS shared DESTINATION lib OPTIONAL
)
endif
(
ENABLE_BUILD_SHARED
)
if
(
ENABLE_BUILD_ANDROID
)
install
(
TARGETS androidGmsh DESTINATION lib OPTIONAL
)
endif
(
ENABLE_BUILD_ANDROID
)
install
(
FILES
${
GMSH_API
}
DESTINATION include/gmsh
)
install
(
FILES
${
WELCOME_FILE
}
DESTINATION
${
GMSH_DOC
}
RENAME README.txt
)
install
(
FILES
${
LICENSE_FILE
}
DESTINATION
${
GMSH_DOC
}
)
...
...
This diff is collapsed.
Click to expand it.
Common/GmshMessage.cpp
+
5
−
1
View file @
e035d269
...
...
@@ -352,6 +352,10 @@ void Msg::Info(const char *fmt, ...)
fflush
(
stdout
);
}
}
void
Msg
::
RequestRender
()
{
if
(
_callback
)
(
*
_callback
)(
"RequestRender"
,
""
);
}
void
Msg
::
Direct
(
const
char
*
fmt
,
...)
{
...
...
@@ -487,7 +491,7 @@ void Msg::ProgressMeter(int n, int N, bool log, const char *fmt, ...)
FlGui
::
instance
()
->
setProgress
(
str
,
(
n
>
N
-
1
)
?
0
:
n
,
0
,
N
);
}
#endif
if
(
_callback
)
(
*
_callback
)(
"Progress"
,
str
);
if
(
!
streamIsFile
(
stdout
)
&&
log
&&
CTX
::
instance
()
->
terminal
){
fprintf
(
stdout
,
"%s
\r
"
,
(
n
>
N
-
1
)
?
""
:
str2
);
...
...
This diff is collapsed.
Click to expand it.
Common/GmshMessage.h
+
1
−
0
View file @
e035d269
...
...
@@ -68,6 +68,7 @@ class Msg {
static
void
Error
(
const
char
*
fmt
,
...);
static
void
Warning
(
const
char
*
fmt
,
...);
static
void
Info
(
const
char
*
fmt
,
...);
static
void
RequestRender
();
static
void
Direct
(
const
char
*
fmt
,
...);
static
void
StatusBar
(
bool
log
,
const
char
*
fmt
,
...);
static
void
StatusGl
(
const
char
*
fmt
,
...);
...
...
This diff is collapsed.
Click to expand it.
Common/OpenFile.cpp
+
1
−
1
View file @
e035d269
...
...
@@ -402,7 +402,7 @@ int MergeFile(const std::string &fileName, bool warnIfMissing)
status
=
readFile3M
(
fileName
);
}
#endif
#if defined(HAVE_ONELAB)
&& defined(HAVE_FLTK)
#if defined(HAVE_ONELAB)
else
if
(
ext
==
".pro"
&&
opt_solver_name
(
0
,
GMSH_GET
,
""
)
==
"GetDP"
){
std
::
vector
<
std
::
string
>
split
=
SplitFileName
(
fileName
);
GModel
::
current
()
->
setName
(
split
[
1
]
+
".geo"
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment